Public Member Functions | |
TypeName ("DAFunction") | |
Runtime type information. More... | |
declareRunTimeSelectionTable (autoPtr, DAFunction, dictionary,(const fvMesh &mesh, const DAOption &daOption, const DAModel &daModel, const DAIndex &daIndex, const word functionName),(mesh, daOption, daModel, daIndex, functionName)) | |
DAFunction (const fvMesh &mesh, const DAOption &daOption, const DAModel &daModel, const DAIndex &daIndex, const word functionName) | |
virtual | ~DAFunction () |
void | clear () |
clear up members More... | |
void | calcFunctionSources () |
calculate DAFunction::faceSources_ and DAFunction::cellSources_ More... | |
virtual scalar | calcFunction ()=0 |
calculate the value of objective function More... | |
word | getFunctionName () |
return the name of objective function More... | |
word | getFunctionType () |
return the part of objective function More... | |
word | getFunctionTimeOp () |
return the time operator such as final, sum, average, variance More... | |
const labelList & | getFaceSources () const |
return DAFunction::faceSources_ More... | |
const labelList & | getCellSources () const |
return DAFunction::cellSources_ More... | |
void | calcRefVar (scalar &functionValue) |
calculate (var-ref)^2 More... | |
Static Public Member Functions | |
static autoPtr< DAFunction > | New (const fvMesh &mesh, const DAOption &daOption, const DAModel &daModel, const DAIndex &daIndex, const word functionName) |
Protected Attributes | |
const fvMesh & | mesh_ |
fvMesh More... | |
const DAOption & | daOption_ |
DAOption object. More... | |
const DAModel & | daModel_ |
DAModel object. More... | |
const DAIndex & | daIndex_ |
DAIndex object. More... | |
word | functionName_ |
the name of the objective function More... | |
word | functionType_ |
the type of the objective function More... | |
word | timeOp_ |
time operator such as final, sum, or average More... | |
dictionary | functionDict_ |
dictionary containing the information for the objective function More... | |
labelList | faceSources_ |
a sorted list of all face sources for the objective function More... | |
labelList | cellSources_ |
a sorted list of all cell sources for the objective function More... | |
scalar | scale_ |
scale of the objective function More... | |
label | calcRefVar_ |
whether to calculate (obj-ref)^2 More... | |
scalarList | ref_ |
if calcRefVar_ is True, set the reference value list More... | |
Definition at line 31 of file DAFunction.H.
DAFunction | ( | const fvMesh & | mesh, |
const DAOption & | daOption, | ||
const DAModel & | daModel, | ||
const DAIndex & | daIndex, | ||
const word | functionName | ||
) |
Definition at line 22 of file DAFunction.C.
References DAFunction::calcFunctionSources(), DAFunction::calcRefVar_, DAFunction::functionDict_, DAFunction::functionType_, DAOption::getAllOptions(), DAFunction::ref_, DAFunction::scale_, and DAFunction::timeOp_.
|
inlinevirtual |
Definition at line 124 of file DAFunction.H.
TypeName | ( | "DAFunction" | ) |
Runtime type information.
declareRunTimeSelectionTable | ( | autoPtr | , |
DAFunction | , | ||
dictionary | , | ||
(const fvMesh &mesh, const DAOption &daOption, const DAModel &daModel, const DAIndex &daIndex, const word functionName) | , | ||
(mesh, daOption, daModel, daIndex, functionName) | |||
) |
|
static |
Definition at line 54 of file DAFunction.C.
References DAOption::getAllOptions(), and mesh.
Referenced by DASolver::setDAFunctionList().
|
inline |
clear up members
Definition at line 129 of file DAFunction.H.
References DAFunction::cellSources_, and DAFunction::faceSources_.
void calcFunctionSources | ( | ) |
calculate DAFunction::faceSources_ and DAFunction::cellSources_
Definition at line 107 of file DAFunction.C.
References DAFunction::cellSources_, DAFunction::faceSources_, forAll(), DAFunction::functionDict_, and DAFunction::mesh_.
Referenced by DAFunction::DAFunction().
|
pure virtual |
calculate the value of objective function
Implemented in DAFunctionVariance, DAFunctionLocation, DAFunctionVariableVolSum, DAFunctionWallHeatFlux, DAFunctionForce, DAFunctionTotalPressureRatio, DAFunctionTotalTemperatureRatio, DAFunctionMeshQualityKS, DAFunctionPatchMean, DAFunctionMoment, DAFunctionTotalPressure, DAFunctionResidualNorm, DAFunctionMassFlowRate, and DAFunctionVonMisesStressKS.
Referenced by DASolver::calcAllFunctions(), and DAOutputFunction::run().
|
inline |
return the name of objective function
Definition at line 142 of file DAFunction.H.
References DAFunction::functionName_.
Referenced by DASolver::calcAllFunctions(), DASolver::getdFScaling(), DAOutputFunction::getFunctionListIndex(), DASolver::getFunctionListIndex(), and DASolver::getTimeOpFuncVal().
|
inline |
return the part of objective function
Definition at line 148 of file DAFunction.H.
References DAFunction::functionType_.
|
inline |
return the time operator such as final, sum, average, variance
Definition at line 154 of file DAFunction.H.
References DAFunction::timeOp_.
Referenced by DASolver::calcAllFunctions().
|
inline |
return DAFunction::faceSources_
Definition at line 160 of file DAFunction.H.
References DAFunction::faceSources_.
|
inline |
return DAFunction::cellSources_
Definition at line 166 of file DAFunction.H.
References DAFunction::cellSources_.
void calcRefVar | ( | scalar & | functionValue | ) |
calculate (var-ref)^2
Definition at line 216 of file DAFunction.C.
References DAFunction::calcRefVar_, DAFunction::mesh_, and DAFunction::ref_.
Referenced by DAFunctionMassFlowRate::calcFunction(), DAFunctionVonMisesStressKS::calcFunction(), DAFunctionResidualNorm::calcFunction(), DAFunctionMoment::calcFunction(), DAFunctionTotalPressure::calcFunction(), DAFunctionPatchMean::calcFunction(), DAFunctionMeshQualityKS::calcFunction(), DAFunctionTotalPressureRatio::calcFunction(), DAFunctionTotalTemperatureRatio::calcFunction(), DAFunctionForce::calcFunction(), DAFunctionVariableVolSum::calcFunction(), DAFunctionWallHeatFlux::calcFunction(), and DAFunctionLocation::calcFunction().
|
protected |
fvMesh
Definition at line 43 of file DAFunction.H.
Referenced by DAFunctionMassFlowRate::calcFunction(), DAFunctionVonMisesStressKS::calcFunction(), DAFunctionResidualNorm::calcFunction(), DAFunctionMoment::calcFunction(), DAFunctionTotalPressure::calcFunction(), DAFunctionPatchMean::calcFunction(), DAFunctionMeshQualityKS::calcFunction(), DAFunctionTotalTemperatureRatio::calcFunction(), DAFunctionTotalPressureRatio::calcFunction(), DAFunctionForce::calcFunction(), DAFunctionVariableVolSum::calcFunction(), DAFunctionWallHeatFlux::calcFunction(), DAFunctionLocation::calcFunction(), DAFunctionVariance::calcFunction(), DAFunction::calcFunctionSources(), DAFunction::calcRefVar(), DAFunctionLocation::DAFunctionLocation(), DAFunctionMeshQualityKS::DAFunctionMeshQualityKS(), DAFunctionTotalPressureRatio::DAFunctionTotalPressureRatio(), DAFunctionTotalTemperatureRatio::DAFunctionTotalTemperatureRatio(), DAFunctionVariance::DAFunctionVariance(), DAFunctionWallHeatFlux::DAFunctionWallHeatFlux(), and DAFunctionLocation::findGlobalSnappedCenter().
|
protected |
DAOption object.
Definition at line 46 of file DAFunction.H.
Referenced by DAFunctionForce::DAFunctionForce(), DAFunctionTotalPressureRatio::DAFunctionTotalPressureRatio(), DAFunctionTotalTemperatureRatio::DAFunctionTotalTemperatureRatio(), and DAFunctionWallHeatFlux::DAFunctionWallHeatFlux().
|
protected |
DAModel object.
Definition at line 49 of file DAFunction.H.
Referenced by DAFunctionResidualNorm::calcFunction(), DAFunctionWallHeatFlux::calcFunction(), and DAFunctionWallHeatFlux::DAFunctionWallHeatFlux().
|
protected |
DAIndex object.
Definition at line 52 of file DAFunction.H.
Referenced by DAFunctionMassFlowRate::calcFunction(), DAFunctionResidualNorm::calcFunction(), DAFunctionMoment::calcFunction(), DAFunctionTotalPressure::calcFunction(), DAFunctionPatchMean::calcFunction(), DAFunctionTotalPressureRatio::calcFunction(), DAFunctionTotalTemperatureRatio::calcFunction(), DAFunctionForce::calcFunction(), DAFunctionWallHeatFlux::calcFunction(), DAFunctionLocation::calcFunction(), DAFunctionVariance::calcFunction(), DAFunctionLocation::DAFunctionLocation(), and DAFunctionVariance::DAFunctionVariance().
|
protected |
the name of the objective function
Definition at line 55 of file DAFunction.H.
Referenced by DAFunction::getFunctionName().
|
protected |
the type of the objective function
Definition at line 58 of file DAFunction.H.
Referenced by DAFunction::DAFunction(), and DAFunction::getFunctionType().
|
protected |
time operator such as final, sum, or average
Definition at line 61 of file DAFunction.H.
Referenced by DAFunction::DAFunction(), and DAFunction::getFunctionTimeOp().
|
protected |
dictionary containing the information for the objective function
Definition at line 64 of file DAFunction.H.
Referenced by DAFunction::calcFunctionSources(), DAFunction::DAFunction(), DAFunctionForce::DAFunctionForce(), DAFunctionLocation::DAFunctionLocation(), DAFunctionMeshQualityKS::DAFunctionMeshQualityKS(), DAFunctionMoment::DAFunctionMoment(), DAFunctionPatchMean::DAFunctionPatchMean(), DAFunctionTotalPressureRatio::DAFunctionTotalPressureRatio(), DAFunctionTotalTemperatureRatio::DAFunctionTotalTemperatureRatio(), DAFunctionVariableVolSum::DAFunctionVariableVolSum(), DAFunctionVariance::DAFunctionVariance(), DAFunctionVonMisesStressKS::DAFunctionVonMisesStressKS(), and DAFunctionWallHeatFlux::DAFunctionWallHeatFlux().
|
protected |
a sorted list of all face sources for the objective function
Definition at line 67 of file DAFunction.H.
Referenced by DAFunctionMassFlowRate::calcFunction(), DAFunctionMoment::calcFunction(), DAFunctionTotalPressure::calcFunction(), DAFunctionPatchMean::calcFunction(), DAFunctionTotalPressureRatio::calcFunction(), DAFunctionTotalTemperatureRatio::calcFunction(), DAFunctionForce::calcFunction(), DAFunctionWallHeatFlux::calcFunction(), DAFunctionLocation::calcFunction(), DAFunctionVariance::calcFunction(), DAFunction::calcFunctionSources(), DAFunction::clear(), DAFunctionLocation::DAFunctionLocation(), DAFunctionVariance::DAFunctionVariance(), and DAFunction::getFaceSources().
|
protected |
a sorted list of all cell sources for the objective function
Definition at line 70 of file DAFunction.H.
Referenced by DAFunctionVonMisesStressKS::calcFunction(), DAFunctionVariableVolSum::calcFunction(), DAFunctionVariance::calcFunction(), DAFunction::calcFunctionSources(), DAFunction::clear(), DAFunctionVariance::DAFunctionVariance(), and DAFunction::getCellSources().
|
protected |
scale of the objective function
Definition at line 73 of file DAFunction.H.
Referenced by DAFunctionMassFlowRate::calcFunction(), DAFunctionVonMisesStressKS::calcFunction(), DAFunctionMoment::calcFunction(), DAFunctionTotalPressure::calcFunction(), DAFunctionPatchMean::calcFunction(), DAFunctionForce::calcFunction(), DAFunctionVariableVolSum::calcFunction(), DAFunctionWallHeatFlux::calcFunction(), DAFunctionVariance::calcFunction(), and DAFunction::DAFunction().
|
protected |
whether to calculate (obj-ref)^2
Definition at line 76 of file DAFunction.H.
Referenced by DAFunction::calcRefVar(), and DAFunction::DAFunction().
|
protected |
if calcRefVar_ is True, set the reference value list
Definition at line 79 of file DAFunction.H.
Referenced by DAFunction::calcRefVar(), and DAFunction::DAFunction().