Public Member Functions
Sundance::NLOp Class Reference

NLOp encapsulates a discrete nonlinear problem, and can be passed to a nonlinear solver such as NOX. More...

Inheritance diagram for Sundance::NLOp:
Sundance::ObjectWithClassVerbosity< NLOp > TSFExtended::NonlinearOperatorBase< double > Sundance::DefaultObjectWithVerbosity Sundance::Handleable< NonlinearOperatorBase< double > > Sundance::ObjectWithClassVerbosity< NonlinearOperatorBase< double > > Sundance::ObjectWithVerbosityBase Sundance::DefaultObjectWithVerbosity Sundance::ObjectWithVerbosityBase

List of all members.

Public Member Functions

 NLOp ()
 Empty ctor.
 NLOp (const Mesh &mesh, const Expr &eqn, const Expr &bc, const Expr &test, const Expr &unk, const Expr &u0, const TSFExtended::VectorType< double > &vecType, bool partitionBCs=false)
 Construct with a mesh, equation set, bcs, test and unknown funcs, and a vector type.
 NLOp (const Mesh &mesh, const Expr &eqn, const Expr &bc, const Expr &test, const Expr &unk, const Expr &u0, const Expr &params, const Expr &paramVals, const TSFExtended::VectorType< double > &vecType, bool partitionBCs=false)
 Construct with a mesh, equation set, bcs, test and unknown funcs, parameters, and a vector type.
 NLOp (const RCP< Assembler > &assembler, const Expr &u0)
LinearOperator< double > computeJacobianAndFunction (Vector< double > &functionValue) const
 Compute the residual and Jacobian at the current evaluation point.
void computeJacobianAndFunction (LinearOperator< double > &J, Vector< double > &resid) const
 Write the Jacobian and residual into the objects provided.
Expr computeSensitivities (const LinearSolver< double > &solver) const
 Compute direct sensitivities to parameters.
Expr getU0 () const
 Return the current evaluation point as a Sundance expression.
TSFExtended::Vector< double > computeFunctionValue () const
 Compute the residual at the current eval point.
void computeFunctionValue (Vector< double > &resid) const
 Write the residual into the object provided.
TSFExtended::Vector< double > getInitialGuess () const
 Get an initial guess.
LinearOperator< double > allocateJacobian () const
 Create the Jacobian object, but don't fill it in.
void setInitialGuess (const Expr &u0New)
 Set an initial guess.

Private Attributes

Handleable interface
RCP< Assemblerassembler_
TSFExtended::LinearOperator
< double > 
J_
Expr u0_
Expr params_
Expr paramVals_
DiscreteFunctiondiscreteU0_

Detailed Description

NLOp encapsulates a discrete nonlinear problem, and can be passed to a nonlinear solver such as NOX.

Definition at line 55 of file SundanceNLOp.hpp.


Constructor & Destructor Documentation

NLOp::NLOp ( )

Empty ctor.

Definition at line 66 of file SundanceNLOp.cpp.

References nlpCtorTimer().

NLOp::NLOp ( const Mesh mesh,
const Expr eqn,
const Expr bc,
const Expr test,
const Expr unk,
const Expr u0,
const TSFExtended::VectorType< double > &  vecType,
bool  partitionBCs = false 
)
NLOp::NLOp ( const Mesh mesh,
const Expr eqn,
const Expr bc,
const Expr test,
const Expr unk,
const Expr u0,
const Expr params,
const Expr paramVals,
const TSFExtended::VectorType< double > &  vecType,
bool  partitionBCs = false 
)
NLOp::NLOp ( const RCP< Assembler > &  assembler,
const Expr u0 
)

Member Function Documentation

LinearOperator< double > NLOp::allocateJacobian ( ) const

Create the Jacobian object, but don't fill it in.

Definition at line 210 of file SundanceNLOp.cpp.

References assembler_.

Vector< double > NLOp::computeFunctionValue ( ) const [virtual]
void NLOp::computeFunctionValue ( Vector< double > &  resid) const
LinearOperator< double > NLOp::computeJacobianAndFunction ( Vector< double > &  functionValue) const [virtual]
void NLOp::computeJacobianAndFunction ( LinearOperator< double > &  J,
Vector< double > &  resid 
) const
Expr NLOp::computeSensitivities ( const LinearSolver< double > &  solver) const
TSFExtended::Vector< double > NLOp::getInitialGuess ( ) const [virtual]

Get an initial guess.

Implements TSFExtended::NonlinearOperatorBase< double >.

Definition at line 190 of file SundanceNLOp.cpp.

References discreteU0_, and Sundance::DiscreteFunction::getVector().

Expr Sundance::NLOp::getU0 ( ) const [inline]

Return the current evaluation point as a Sundance expression.

Definition at line 95 of file SundanceNLOp.hpp.

References u0_.

void NLOp::setInitialGuess ( const Expr u0New)

Member Data Documentation

TSFExtended::LinearOperator<double> Sundance::NLOp::J_ [mutable, private]

Definition at line 122 of file SundanceNLOp.hpp.

Referenced by computeJacobianAndFunction(), and computeSensitivities().

Definition at line 128 of file SundanceNLOp.hpp.

Referenced by computeSensitivities().

Definition at line 131 of file SundanceNLOp.hpp.

Definition at line 125 of file SundanceNLOp.hpp.

Referenced by computeSensitivities(), getU0(), and NLOp().

Site Contact