Solver of the adjoint to the Laplace grid displacement equation. More...
Public Member Functions | |
TypeName ("adjointMeshMovementSolver") | |
Runtime type information. More... | |
adjointMeshMovementSolver (const fvMesh &mesh, const dictionary &dict, Foam::incompressible::adjointSensitivity &adjointSensitivity, const labelHashSet &sensitivityPatchIDs, const autoPtr< adjointEikonalSolver > &adjointEikonalSolverPtr) | |
Construct from components. More... | |
virtual | ~adjointMeshMovementSolver ()=default |
Destructor. More... | |
virtual bool | readDict (const dictionary &dict) |
Read dict if changed. More... | |
void | accumulateIntegrand (const scalar dt) |
Accumulate source term. More... | |
void | solve () |
Calculate the adjoint distance field. More... | |
void | reset () |
Reset source term. More... | |
boundaryVectorField & | meshMovementSensitivities () |
Return the sensitivity term depending on da. More... | |
const volVectorField & | ma () |
Return the adjoint distance field. More... | |
Protected Member Functions | |
void | read () |
Read options each time a new solution is found. More... | |
Protected Attributes | |
const fvMesh & | mesh_ |
dictionary | dict_ |
Foam::incompressible::adjointSensitivity & | adjointSensitivity_ |
const labelHashSet & | sensitivityPatchIDs_ |
label | nLaplaceIters_ |
scalar | tolerance_ |
volVectorField | ma_ |
volVectorField | source_ |
autoPtr< boundaryVectorField > | meshMovementSensPtr_ |
Wall face sens w.r.t.(x, y.z) //wall face sens w.r.t. (x,y.z) More... | |
const autoPtr< adjointEikonalSolver > & | adjointEikonalSolverPtr_ |
Solver of the adjoint to the Laplace grid displacement equation.
Kavvadias, I., Papoutsis-Kiachagias, E., & Giannakoglou, K. (2015). On the proper treatment of grid sensitivities in continuous adjoint methods for shape optimization. Journal of Computational Physics, 301, 1–18. http://doi.org/10.1016/j.jcp.2015.08.012
Definition at line 64 of file adjointMeshMovementSolverIncompressible.H.
adjointMeshMovementSolver | ( | const fvMesh & | mesh, |
const dictionary & | dict, | ||
Foam::incompressible::adjointSensitivity & | adjointSensitivity, | ||
const labelHashSet & | sensitivityPatchIDs, | ||
const autoPtr< adjointEikonalSolver > & | adjointEikonalSolverPtr | ||
) |
Construct from components.
Definition at line 52 of file adjointMeshMovementSolverIncompressible.C.
References Foam::read().
|
virtualdefault |
Destructor.
|
protected |
Read options each time a new solution is found.
Definition at line 42 of file adjointMeshMovementSolverIncompressible.C.
References adjointMeshMovementSolver::dict_, Foam::constant::electromagnetic::e, dictionary::getOrDefault(), adjointMeshMovementSolver::nLaplaceIters_, and adjointMeshMovementSolver::tolerance_.
Referenced by adjointMeshMovementSolver::solve().
TypeName | ( | "adjointMeshMovementSolver" | ) |
Runtime type information.
|
virtual |
Read dict if changed.
Definition at line 107 of file adjointMeshMovementSolverIncompressible.C.
References dict, and adjointMeshMovementSolver::dict_.
void accumulateIntegrand | ( | const scalar | dt | ) |
Accumulate source term.
Definition at line 115 of file adjointMeshMovementSolverIncompressible.C.
References adjointSensitivity::adjointMeshMovementSource(), adjointMeshMovementSolver::adjointSensitivity_, and adjointMeshMovementSolver::source_.
void solve | ( | ) |
Calculate the adjoint distance field.
Definition at line 125 of file adjointMeshMovementSolverIncompressible.C.
References adjointMeshMovementSolver::adjointEikonalSolverPtr_, GeometricField< Type, PatchField, GeoMesh >::boundaryFieldRef(), fvMatrix< Type >::boundaryManipulate(), Foam::fvc::div(), Foam::endl(), Foam::gMax(), Foam::Info, Foam::fvm::laplacian(), adjointMeshMovementSolver::ma_, Foam::mag(), adjointMeshMovementSolver::mesh_, adjointMeshMovementSolver::nLaplaceIters_, Time::printExecutionTime(), adjointMeshMovementSolver::read(), Foam::solve(), solution::solverDict(), adjointMeshMovementSolver::source_, Foam::T(), fvMesh::time(), adjointMeshMovementSolver::tolerance_, and regIOobject::write().
void reset | ( | ) |
Reset source term.
Definition at line 169 of file adjointMeshMovementSolverIncompressible.C.
References DimensionedField< Type, GeoMesh >::dimensions(), adjointMeshMovementSolver::meshMovementSensPtr_, adjointMeshMovementSolver::source_, and Foam::Zero.
boundaryVectorField & meshMovementSensitivities | ( | ) |
Return the sensitivity term depending on da.
Definition at line 176 of file adjointMeshMovementSolverIncompressible.C.
References GeometricField< Type, PatchField, GeoMesh >::boundaryField(), Foam::endl(), Foam::Info, adjointMeshMovementSolver::ma_, adjointMeshMovementSolver::meshMovementSensPtr_, and adjointMeshMovementSolver::sensitivityPatchIDs_.
const volVectorField & ma | ( | ) |
Return the adjoint distance field.
Definition at line 192 of file adjointMeshMovementSolverIncompressible.C.
References adjointMeshMovementSolver::ma_.
|
protected |
Definition at line 70 of file adjointMeshMovementSolverIncompressible.H.
Referenced by adjointMeshMovementSolver::solve().
|
protected |
Definition at line 71 of file adjointMeshMovementSolverIncompressible.H.
Referenced by adjointMeshMovementSolver::read(), and adjointMeshMovementSolver::readDict().
|
protected |
Definition at line 72 of file adjointMeshMovementSolverIncompressible.H.
Referenced by adjointMeshMovementSolver::accumulateIntegrand().
|
protected |
Definition at line 73 of file adjointMeshMovementSolverIncompressible.H.
Referenced by adjointMeshMovementSolver::meshMovementSensitivities().
|
protected |
Definition at line 74 of file adjointMeshMovementSolverIncompressible.H.
Referenced by adjointMeshMovementSolver::read(), and adjointMeshMovementSolver::solve().
|
protected |
Definition at line 75 of file adjointMeshMovementSolverIncompressible.H.
Referenced by adjointMeshMovementSolver::read(), and adjointMeshMovementSolver::solve().
|
protected |
Definition at line 76 of file adjointMeshMovementSolverIncompressible.H.
Referenced by adjointMeshMovementSolver::ma(), adjointMeshMovementSolver::meshMovementSensitivities(), and adjointMeshMovementSolver::solve().
|
protected |
Definition at line 77 of file adjointMeshMovementSolverIncompressible.H.
Referenced by adjointMeshMovementSolver::accumulateIntegrand(), adjointMeshMovementSolver::reset(), and adjointMeshMovementSolver::solve().
|
protected |
Wall face sens w.r.t.(x, y.z) //wall face sens w.r.t. (x,y.z)
Definition at line 82 of file adjointMeshMovementSolverIncompressible.H.
Referenced by adjointMeshMovementSolver::meshMovementSensitivities(), and adjointMeshMovementSolver::reset().
|
protected |
Definition at line 83 of file adjointMeshMovementSolverIncompressible.H.
Referenced by adjointMeshMovementSolver::solve().
Copyright © 2011-2018 OpenFOAM | OPENFOAM® is a registered trademark of OpenCFD Ltd.