46 #include <Xyce_config.h>
55 #include "N_LAS_Vector.h"
56 #include "N_LAS_System.h"
57 #include "N_LAS_Builder.h"
58 #include "N_ERH_ErrorMgr.h"
62 using namespace N_NLS_NOX;
63 using namespace Xyce::N_NLS_NOX;
78 lasSys_(source.lasSys_),
83 error(
"N_NLS_NOX::Vector Copy Constructor - unable to create vector");
86 if (type == NOX::DeepCopy)
96 #ifdef Xyce_TRILINOS_DEV
102 return vectorPtr_->globalLength();
111 NOX::Abstract::Vector&
Vector::abs(
const NOX::Abstract::Vector& source)
113 return abs(dynamic_cast<const Vector&>(source));
124 return operator=(dynamic_cast<const Vector&>(source));
137 return reciprocal(dynamic_cast<const Vector&>(source));
154 return scale(dynamic_cast<const Vector&>(y));
163 NOX::Abstract::Vector&
Vector::update(
double alpha,
const NOX::Abstract::Vector& a,
166 return update(alpha, dynamic_cast<const Vector&>(a), gamma);
177 NOX::Abstract::Vector&
Vector::update(
double alpha,
const NOX::Abstract::Vector& a,
178 double beta,
const NOX::Abstract::Vector& b,
181 return update(alpha, dynamic_cast<const Vector&>(a),
182 beta, dynamic_cast<const Vector&>(b),
189 double beta,
const Vector& b,
204 Teuchos::RCP<NOX::Abstract::Vector>
207 Teuchos::RCP<Vector> ptr = Teuchos::rcp(
new Vector(*
this, type));
216 case NOX::Abstract::Vector::TwoNorm:
219 case NOX::Abstract::Vector::OneNorm:
222 case NOX::Abstract::Vector::MaxNorm:
226 error(
"N_NLS_NOX::Vector::norm - invalid norm type");
233 return norm(dynamic_cast<const Vector&>(weights));
238 error(
"N_NLS::NOX::Vector::norm with weights is not supported");