46 #include <Xyce_config.h>
57 #include <N_LAS_Vector.h>
58 #include <N_ERH_ErrorMgr.h>
61 #include <NOX_Abstract_Vector.H>
76 xVecPtr_(Teuchos::rcp(dynamic_cast<N_NLS_NOX::
Vector*>(s.cloneSolutionVector()))),
78 fVecPtr_(Teuchos::rcp_dynamic_cast<N_NLS_NOX::
Vector>(xVec_.clone(NOX::ShapeCopy))),
81 haveSolverFactors_(false)
95 sharedSystemPtr_(source.sharedSystemPtr_),
96 xVecPtr_(Teuchos::rcp_dynamic_cast<N_NLS_NOX::
Vector>(source.getX().clone(type))),
98 fVecPtr_(Teuchos::rcp_dynamic_cast<N_NLS_NOX::
Vector>(xVec_.clone(NOX::ShapeCopy))),
101 haveSolverFactors_(false)
160 const std::string message =
"N_NLS::NOX::Group::Group() - Invalid ConstructorType for group copy constructor";
161 N_ERH_ErrorMgr::report(N_ERH_ErrorMgr::DEV_FATAL, message);
187 return operator=(dynamic_cast<const Group&>(source));
259 setX(dynamic_cast<const Vector&>(input));
286 const NOX::Abstract::Vector& d,
289 computeX(dynamic_cast<const Group&>(grp), dynamic_cast<const Vector&>(d),
317 if(
isF() )
return Ok;
327 return (
isF()?Ok:Failed);
362 throwError(
"computeGradient",
"F is not Valid!");
365 throwError(
"computeGradient",
"Jacobian is not Valid!");
371 NOX::Abstract::Group::ReturnType status =
396 throwError(
"computeNewton",
"F is not Valid!");
399 throwError(
"computeNewton",
"Jacobian is not Valid!");
422 NOX::Abstract::Group::ReturnType
Group::applyJacobian(
const NOX::Abstract::Vector& input, NOX::Abstract::Vector& result)
const
424 return applyJacobian(dynamic_cast<const Vector&>(input), dynamic_cast<Vector&>(result));
438 throwError(
"applyJacobian",
"Jacobian is not Valid!");
458 NOX::Abstract::Vector& result)
const
461 dynamic_cast<Vector&>(result));
475 throwError(
"applyJacobianTranspose",
"Jacobian is not Valid!");
488 NOX::Abstract::Group::ReturnType
490 const NOX::Abstract::Vector& input,
491 NOX::Abstract::Vector& result)
const
494 dynamic_cast<Vector&>(result));
505 NOX::Abstract::Group::ReturnType
510 throwError(
"applyJacobianInverse",
"Jacobian is not Valid!");
516 return (status ? Ok : Failed);
527 NOX::Abstract::Group::ReturnType
529 Teuchos::ParameterList& params,
530 const NOX::Abstract::Vector& input,
531 NOX::Abstract::Vector& result)
const
534 dynamic_cast<const Vector&>(input),
535 dynamic_cast<Vector&> (result));
546 NOX::Abstract::Group::ReturnType
548 Teuchos::ParameterList& params,
563 return NOX::Abstract::Group::Ok;
643 "F is not current with respect to the solution vector!");
680 throwError(
"getGradient",
"gradVecPtr_ is 0!");
697 throwError(
"getNewton",
"newtonVecPtr_ is 0!");
710 Teuchos::RefCountPtr<NOX::Abstract::Group>
713 Teuchos::RefCountPtr<Group> ptr = Teuchos::rcp(
new Group(*
this, type));
745 const std::string leader =
"N_NLS::NOX::Group::";
746 const std::string fcn =
"() - ";
748 std::string
error = leader + method + fcn + message;
750 N_ERH_ErrorMgr::report(N_ERH_ErrorMgr::DEV_FATAL, error);