Public Member Functions | Protected Member Functions | Protected Attributes | List of all members
SR1 Class Reference

The quasi-Newton Symmetric Rank One formula. More...

Inheritance diagram for SR1:
Inheritance graph
[legend]
Collaboration diagram for SR1:
Collaboration graph
[legend]

Public Member Functions

 TypeName ("SR1")
 
 SR1 (const fvMesh &mesh, const dictionary &dict)
 
virtual ~SR1 ()=default
 
void computeCorrection ()
 
virtual void updateOldCorrection (const scalarField &oldCorrection)
 
virtual void write ()
 
- Public Member Functions inherited from updateMethod
 TypeName ("updateMethod")
 
 declareRunTimeSelectionTable (autoPtr, updateMethod, dictionary,(const fvMesh &mesh, const dictionary &dict),(mesh, dict))
 
 updateMethod (const fvMesh &mesh, const dictionary &dict)
 
virtual ~updateMethod ()=default
 
void setObjectiveDeriv (const scalarField &derivs)
 
void setConstraintDeriv (const PtrList< scalarField > &derivs)
 
void setObjectiveValue (const scalar value)
 
void setConstraintValues (const scalarField &values)
 
void setStep (const scalar eta)
 
void setGlobalSum (const bool useGlobalSum)
 
scalarFieldreturnCorrection ()
 
void writeCorrection ()
 
virtual scalar computeMeritFunction ()
 
virtual scalar meritFunctionDirectionalDerivative ()
 
boolinitialEtaSet ()
 

Protected Member Functions

void allocateMatrices ()
 
void updateHessian ()
 
void update ()
 
void readFromDict ()
 
- Protected Member Functions inherited from updateMethod
const scalarField leftMult (const scalarField &, const SquareMatrix< scalar > &)
 
const scalarField rightMult (const SquareMatrix< scalar > &, const scalarField &)
 
SquareMatrix< scalar > outerProd (const scalarField &, const scalarField &)
 
SquareMatrix< scalar > inv (SquareMatrix< scalar > A)
 
scalar globalSum (const scalarField &field)
 
scalar globalSum (tmp< scalarField > &tfield)
 
dictionary coeffsDict ()
 

Protected Attributes

scalar etaHessian_
 
label nSteepestDescent_
 
scalar ratioThreshold_
 
labelList activeDesignVars_
 
SquareMatrix< scalar > HessianInv_
 
SquareMatrix< scalar > HessianInvOld_
 
scalarField derivativesOld_
 
scalarField correctionOld_
 
label counter_
 
- Protected Attributes inherited from updateMethod
const fvMeshmesh_
 
const dictionary dict_
 
IOdictionary optMethodIODict_
 
scalarField objectiveDerivatives_
 
PtrList< scalarFieldconstraintDerivatives_
 
scalar objectiveValue_
 
scalarField cValues_
 
scalarField correction_
 
scalarField cumulativeCorrection_
 
scalar eta_
 
bool initialEtaSet_
 
word correctionFolder_
 
bool globalSum_
 

Additional Inherited Members

- Static Public Member Functions inherited from updateMethod
static autoPtr< updateMethodNew (const fvMesh &mesh, const dictionary &dict)
 

Detailed Description

The quasi-Newton Symmetric Rank One formula.

Source files

Definition at line 50 of file SR1.H.

Constructor & Destructor Documentation

◆ SR1()

SR1 ( const fvMesh mesh,
const dictionary dict 
)

Definition at line 152 of file SR1.C.

References SR1::activeDesignVars_, updateMethod::coeffsDict(), Foam::endl(), Foam::Info, and SR1::readFromDict().

Here is the call graph for this function:

◆ ~SR1()

virtual ~SR1 ( )
virtualdefault

Member Function Documentation

◆ allocateMatrices()

void allocateMatrices ( )
protected

Definition at line 42 of file SR1.C.

References SR1::activeDesignVars_, forAll, SR1::HessianInv_, SR1::HessianInvOld_, Foam::identity(), updateMethod::objectiveDerivatives_, and Foam::Zero.

Here is the call graph for this function:

◆ updateHessian()

void updateHessian ( )
protected

Definition at line 64 of file SR1.C.

References Foam::endl(), s, Foam::sqr(), Foam::sqrt(), WarningInFunction, y, and Foam::Zero.

Here is the call graph for this function:

◆ update()

void update ( )
protected

Definition at line 95 of file SR1.C.

References Foam::endl(), forAll, Foam::Info, Field::map(), and Foam::Zero.

Here is the call graph for this function:

◆ readFromDict()

void readFromDict ( )
protected

Definition at line 128 of file SR1.C.

References Foam::identity(), n, and Foam::Zero.

Referenced by SR1::SR1().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ TypeName()

TypeName ( "SR1"  )

◆ computeCorrection()

void computeCorrection ( )
virtual

Implements updateMethod.

Definition at line 194 of file SR1.C.

References update().

Here is the call graph for this function:

◆ updateOldCorrection()

void updateOldCorrection ( const scalarField oldCorrection)
virtual

Reimplemented from updateMethod.

Definition at line 210 of file SR1.C.

References updateMethod::updateOldCorrection().

Here is the call graph for this function:

◆ write()

void write ( )
virtual

Reimplemented from updateMethod.

Definition at line 217 of file SR1.C.

References updateMethod::write().

Here is the call graph for this function:

Member Data Documentation

◆ etaHessian_

scalar etaHessian_
protected

Definition at line 59 of file SR1.H.

◆ nSteepestDescent_

label nSteepestDescent_
protected

Definition at line 62 of file SR1.H.

◆ ratioThreshold_

scalar ratioThreshold_
protected

Definition at line 65 of file SR1.H.

◆ activeDesignVars_

labelList activeDesignVars_
protected

Definition at line 68 of file SR1.H.

Referenced by SR1::allocateMatrices(), and SR1::SR1().

◆ HessianInv_

SquareMatrix<scalar> HessianInv_
protected

Definition at line 72 of file SR1.H.

Referenced by SR1::allocateMatrices().

◆ HessianInvOld_

SquareMatrix<scalar> HessianInvOld_
protected

Definition at line 75 of file SR1.H.

Referenced by SR1::allocateMatrices().

◆ derivativesOld_

scalarField derivativesOld_
protected

Definition at line 78 of file SR1.H.

◆ correctionOld_

scalarField correctionOld_
protected

Definition at line 81 of file SR1.H.

◆ counter_

label counter_
protected

Definition at line 84 of file SR1.H.


The documentation for this class was generated from the following files: