https://mooseframework.inl.gov
Loading...
Searching...
No Matches
Public Types | Public Member Functions | Static Public Member Functions | Public Attributes | Static Public Attributes | Protected Member Functions | Static Protected Member Functions | Protected Attributes | Private Member Functions | Static Private Member Functions | Private Attributes | List of all members
AdjointTransientSolve Class Reference

Transient adjoint solve object. More...

#include <AdjointTransientSolve.h>

Inheritance diagram for AdjointTransientSolve:
[legend]

Public Types

typedef DataFileName DataFileParameterType
 

Public Member Functions

 AdjointTransientSolve (Executioner &ex)
 
virtual bool solve () override
 Overriding parent class so the time-derivative residual is stored for the next time step.
 
void insertForwardSolution (int tstep)
 This function should be called after every converged forward time step.
 
void setForwardSolution (int tstep)
 Takes the previously saved forward solutions residing in the adjoint system and copies them to the available solution states in the forward systems.
 
virtual void initialSetup ()
 
virtual void setInnerSolve (SolveObject &solve)
 
virtual bool enabled () const
 
std::shared_ptr< MooseObjectgetSharedPtr ()
 
std::shared_ptr< const MooseObjectgetSharedPtr () const
 
bool isKokkosObject () const
 
MooseAppgetMooseApp () const
 
const std::string & type () const
 
const std::string & name () const
 
std::string typeAndName () const
 
MooseObjectParameterName uniqueParameterName (const std::string &parameter_name) const
 
MooseObjectName uniqueName () const
 
const InputParametersparameters () const
 
const hit::Node * getHitNode () const
 
bool hasBase () const
 
const std::string & getBase () const
 
const TgetParam (const std::string &name) const
 
std::vector< std::pair< T1, T2 > > getParam (const std::string &param1, const std::string &param2) const
 
const TqueryParam (const std::string &name) const
 
const TgetRenamedParam (const std::string &old_name, const std::string &new_name) const
 
T getCheckedPointerParam (const std::string &name, const std::string &error_string="") const
 
bool isParamValid (const std::string &name) const
 
bool isParamSetByUser (const std::string &name) const
 
void connectControllableParams (const std::string &parameter, const std::string &object_type, const std::string &object_name, const std::string &object_parameter) const
 
void paramError (const std::string &param, Args... args) const
 
void paramWarning (const std::string &param, Args... args) const
 
void paramWarning (const std::string &param, Args... args) const
 
void paramInfo (const std::string &param, Args... args) const
 
std::string messagePrefix (const bool hit_prefix=true) const
 
std::string errorPrefix (const std::string &) const
 
void mooseError (Args &&... args) const
 
void mooseDocumentedError (const std::string &repo_name, const unsigned int issue_num, Args &&... args) const
 
void mooseErrorNonPrefixed (Args &&... args) const
 
void mooseWarning (Args &&... args) const
 
void mooseWarning (Args &&... args) const
 
void mooseWarningNonPrefixed (Args &&... args) const
 
void mooseWarningNonPrefixed (Args &&... args) const
 
void mooseDeprecated (Args &&... args) const
 
void mooseDeprecated (Args &&... args) const
 
void mooseDeprecatedNoTrace (Args &&... args) const
 
void mooseInfo (Args &&... args) const
 
void callMooseError (std::string msg, const bool with_prefix, const hit::Node *node=nullptr, const bool show_trace=true) const
 
std::string getDataFileName (const std::string &param) const
 
std::string getDataFileNameByName (const std::string &relative_path) const
 
std::string getDataFilePath (const std::string &relative_path) const
 
PerfGraphperfGraph ()
 
bool isDefaultPostprocessorValue (const std::string &param_name, const unsigned int index=0) const
 
bool hasPostprocessor (const std::string &param_name, const unsigned int index=0) const
 
bool hasPostprocessorByName (const PostprocessorName &name) const
 
std::size_t coupledPostprocessors (const std::string &param_name) const
 
const PostprocessorName & getPostprocessorName (const std::string &param_name, const unsigned int index=0) const
 
const PostprocessorValuegetPostprocessorValue (const std::string &param_name, const unsigned int index=0) const
 
const PostprocessorValuegetPostprocessorValue (const std::string &param_name, const unsigned int index=0) const
 
const PostprocessorValuegetPostprocessorValueOld (const std::string &param_name, const unsigned int index=0) const
 
const PostprocessorValuegetPostprocessorValueOld (const std::string &param_name, const unsigned int index=0) const
 
const PostprocessorValuegetPostprocessorValueOlder (const std::string &param_name, const unsigned int index=0) const
 
const PostprocessorValuegetPostprocessorValueOlder (const std::string &param_name, const unsigned int index=0) const
 
virtual const PostprocessorValuegetPostprocessorValueByName (const PostprocessorName &name) const
 
virtual const PostprocessorValuegetPostprocessorValueByName (const PostprocessorName &name) const
 
const PostprocessorValuegetPostprocessorValueOldByName (const PostprocessorName &name) const
 
const PostprocessorValuegetPostprocessorValueOldByName (const PostprocessorName &name) const
 
const PostprocessorValuegetPostprocessorValueOlderByName (const PostprocessorName &name) const
 
const PostprocessorValuegetPostprocessorValueOlderByName (const PostprocessorName &name) const
 
const Parallel::Communicator & comm () const
 
processor_id_type n_processors () const
 
processor_id_type processor_id () const
 

Static Public Member Functions

static InputParameters validParams ()
 
static void callMooseError (MooseApp *const app, const InputParameters &params, std::string msg, const bool with_prefix, const hit::Node *node, const bool show_trace=true)
 

Public Attributes

 usingCombinedWarningSolutionWarnings
 
const ConsoleStream _console
 

Static Public Attributes

static const std::string type_param
 
static const std::string name_param
 
static const std::string unique_name_param
 
static const std::string app_param
 
static const std::string moose_base_param
 
static const std::string kokkos_object_param
 

Protected Member Functions

virtual void assembleAdjointSystem (SparseMatrix< Number > &matrix, const NumericVector< Number > &solution, NumericVector< Number > &rhs) override
 Overriding parent class so the previous time-derivative residual is added to the right-hand-side of the linear solve.
 
void evaluateTimeResidual (const NumericVector< Number > &solution, NumericVector< Number > &residual)
 This evaluates the time part of the adjoint residual.
 
void checkIntegrity ()
 Checks whether the forward and adjoint systems are consistent.
 
void applyNodalBCs (SparseMatrix< Number > &matrix, const NumericVector< Number > &solution, NumericVector< Number > &rhs)
 Helper function for applying nodal BCs to the adjoint matrix and RHS.
 
void flagInvalidSolutionInternal (const InvalidSolutionID invalid_solution_id) const
 
InvalidSolutionID registerInvalidSolutionInternal (const std::string &message, const bool warning) const
 
PerfID registerTimedSection (const std::string &section_name, const unsigned int level) const
 
PerfID registerTimedSection (const std::string &section_name, const unsigned int level, const std::string &live_message, const bool print_dots=true) const
 
std::string timedSectionName (const std::string &section_name) const
 
virtual void addPostprocessorDependencyHelper (const PostprocessorName &) const
 
TdeclareRestartableData (const std::string &data_name, Args &&... args)
 
ManagedValue< TdeclareManagedRestartableDataWithContext (const std::string &data_name, void *context, Args &&... args)
 
const TgetRestartableData (const std::string &data_name) const
 
TdeclareRestartableDataWithContext (const std::string &data_name, void *context, Args &&... args)
 
TdeclareRecoverableData (const std::string &data_name, Args &&... args)
 
TdeclareRestartableDataWithObjectName (const std::string &data_name, const std::string &object_name, Args &&... args)
 
TdeclareRestartableDataWithObjectNameWithContext (const std::string &data_name, const std::string &object_name, void *context, Args &&... args)
 
std::string restartableName (const std::string &data_name) const
 

Static Protected Member Functions

static std::string getForwardSolutionName (int tstep)
 Prescribed name of the forward solution at a specified time step.
 

Protected Attributes

const unsigned int _forward_sys_num
 The number of the nonlinear system representing the forward model.
 
const unsigned int _adjoint_sys_num
 The number of the nonlinear system representing the adjoint model.
 
NonlinearSystemBase_nl_forward
 The nonlinear system representing the forward model.
 
NonlinearSystemBase_nl_adjoint
 The nonlinear system representing the adjoint model.
 
Executioner_executioner
 
FEProblemBase_problem
 
DisplacedProblem_displaced_problem
 
MooseMesh_mesh
 
MooseMesh_displaced_mesh
 
SystemBase_solver_sys
 
AuxiliarySystem_aux
 
SolveObject_inner_solve
 
const bool & _enabled
 
MooseApp_app
 
Factory_factory
 
ActionFactory_action_factory
 
const std::string & _type
 
const std::string & _name
 
const InputParameters_pars
 
MooseApp_pg_moose_app
 
const std::string _prefix
 
const Parallel::Communicator & _communicator
 
MooseApp_restartable_app
 
const std::string _restartable_system_name
 
const THREAD_ID _restartable_tid
 
const bool _restartable_read_only
 

Private Member Functions

const PostprocessorName & getPostprocessorNameInternal (const std::string &param_name, const unsigned int index, const bool allow_default_value=true) const
 
bool isDefaultPostprocessorValueByName (const PostprocessorName &name) const
 
PostprocessorValue getDefaultPostprocessorValueByName (const PostprocessorName &name) const
 
void checkParam (const std::string &param_name, const unsigned int index=std::numeric_limits< unsigned int >::max()) const
 
bool postprocessorsAdded () const
 
const PostprocessorValuegetPostprocessorValueInternal (const std::string &param_name, unsigned int index, std::size_t t_index) const
 
const PostprocessorValuegetPostprocessorValueInternal (const std::string &param_name, unsigned int index, std::size_t t_index) const
 
const PostprocessorValuegetPostprocessorValueByNameInternal (const PostprocessorName &name, std::size_t t_index) const
 
const PostprocessorValuegetPostprocessorValueByNameInternal (const PostprocessorName &name, std::size_t t_index) const
 
RestartableDataValueregisterRestartableDataOnApp (std::unique_ptr< RestartableDataValue > data, THREAD_ID tid) const
 
void registerRestartableNameWithFilterOnApp (const std::string &name, Moose::RESTARTABLE_FILTER filter)
 
RestartableData< T > & declareRestartableDataHelper (const std::string &data_name, void *context, Args &&... args) const
 

Static Private Member Functions

static const hit::Node * getHitNode (const InputParameters &params)
 
static std::string messagePrefix (const InputParameters &params, const bool hit_prefix)
 

Private Attributes

NumericVector< Number > & _old_time_residual
 The residual contribution from previous adjoint solutions.
 
std::vector< std::string > & _forward_solutions
 Name of the forward solution at each time step residing in the adjoint system.
 
const ParallelParamObject_parent
 
const MooseBase_si_moose_base
 
const FEProblemBase_si_problem
 
const MooseObject_ppi_moose_object
 
const InputParameters_ppi_params
 
const FEProblemBase_ppi_feproblem
 
std::map< PostprocessorName, std::unique_ptr< PostprocessorValue > > _default_values
 
const RestartableDataMapName _metaname
 
std::string _restartable_name
 

Detailed Description

Transient adjoint solve object.

See also
TransientAndAdjoint for example usage. General algorithm:
  1. Set forward initial conditions
  2. Save the forward initial solution using insertForwardSolution(0)
  3. for t_step = 1,...,num_step
  4. Solve forward time step
  5. Save forward solution using insertForwardSolution(t_step)
  6. Set _old_time_residual = 0
  1. for t_step = num_step,...,1
  2. Set forward solution using setForwardSolution(t_step)
  3. Solve adjoint time step: A* u* = b* + _old_time_residual
  4. Evaluate time residual: _old_time_residual = A_t* u*

where A* is the transpose of the linearized forward operator at the specified timestep, u* is the adjoint solution, and A_t* is the transpose of the linearized forward time operator.

Definition at line 32 of file AdjointTransientSolve.h.

Constructor & Destructor Documentation

◆ AdjointTransientSolve()

AdjointTransientSolve::AdjointTransientSolve ( Executioner ex)

Definition at line 28 of file AdjointTransientSolve.C.

29 : AdjointSolve(ex),
30 Restartable(this, "Executioners"),
32 _forward_solutions(declareRecoverableData<std::vector<std::string>>("forward_solutions"))
33{
34}
The solve object is responsible for solving the adjoint version of a forward model.
NonlinearSystemBase & _nl_adjoint
The nonlinear system representing the adjoint model.
std::vector< std::string > & _forward_solutions
Name of the forward solution at each time step residing in the adjoint system.
NumericVector< Number > & _old_time_residual
The residual contribution from previous adjoint solutions.
NumericVector< Number > & getResidualTimeVector()
T & declareRecoverableData(const std::string &data_name, Args &&... args)

Member Function Documentation

◆ applyNodalBCs()

void AdjointSolve::applyNodalBCs ( SparseMatrix< Number > &  matrix,
const NumericVector< Number > &  solution,
NumericVector< Number > &  rhs 
)
protectedinherited

Helper function for applying nodal BCs to the adjoint matrix and RHS.

Say there is a BC setting the d-th DoF to a dirichlet condition on the forward problem. This basically sets the d-th column of the matrix to zero, the d-th entry of the matrix diagonal to one, and the d-th entry of the RHS to the solution passed in.

Parameters
matrixThe matrix whose columns are set to 0
solutionThe solution to replace the entries of the RHS
rhsThe RHS to to replace with the solution

Definition at line 159 of file AdjointSolve.C.

162{
163 std::vector<dof_id_type> nbc_dofs;
164 auto & nbc_warehouse = _nl_forward.getNodalBCWarehouse();
165 if (nbc_warehouse.hasActiveObjects())
166 {
167 for (const auto & bnode : *_mesh.getBoundaryNodeRange())
168 {
169 BoundaryID boundary_id = bnode->_bnd_id;
170 Node * node = bnode->_node;
171
172 if (!nbc_warehouse.hasActiveBoundaryObjects(boundary_id) ||
173 node->processor_id() != processor_id())
174 continue;
175
176 for (const auto & bc : nbc_warehouse.getActiveBoundaryObjects(boundary_id))
177 if (bc->shouldApply())
178 for (unsigned int c = 0; c < bc->variable().count(); ++c)
179 nbc_dofs.push_back(node->dof_number(_forward_sys_num, bc->variable().number() + c, 0));
180 }
181
182 // Petsc has a nice interface for zeroing rows and columns, so we'll use it
183 auto petsc_matrix = dynamic_cast<PetscMatrix<Number> *>(&matrix);
184 auto petsc_solution = dynamic_cast<const PetscVector<Number> *>(&solution);
185 auto petsc_rhs = dynamic_cast<PetscVector<Number> *>(&rhs);
186 if (petsc_matrix && petsc_solution && petsc_rhs)
187 LibmeshPetscCall(MatZeroRowsColumns(petsc_matrix->mat(),
188 cast_int<PetscInt>(nbc_dofs.size()),
189 numeric_petsc_cast(nbc_dofs.data()),
190 1.0,
191 petsc_solution->vec(),
192 petsc_rhs->vec()));
193 else
194 mooseError("Using PETSc matrices and vectors is required for applying homogenized boundary "
195 "conditions.");
196 }
197}
boundary_id_type BoundaryID
for(PetscInt i=0;i< nvars;++i)
void ErrorVector unsigned int
const unsigned int _forward_sys_num
The number of the nonlinear system representing the forward model.
NonlinearSystemBase & _nl_forward
The nonlinear system representing the forward model.
void mooseError(Args &&... args) const
const MooseObjectTagWarehouse< NodalBCBase > & getNodalBCWarehouse() const
MooseMesh & _mesh
dof_id_type dof_number(const unsigned int s, const unsigned int var, const unsigned int comp) const
processor_id_type processor_id() const
processor_id_type processor_id() const
if(subdm)
PetscInt * numeric_petsc_cast(const numeric_index_type *p)

Referenced by AdjointSolve::solve().

◆ assembleAdjointSystem()

void AdjointTransientSolve::assembleAdjointSystem ( SparseMatrix< Number > &  matrix,
const NumericVector< Number > &  solution,
NumericVector< Number > &  rhs 
)
overrideprotectedvirtual

Overriding parent class so the previous time-derivative residual is added to the right-hand-side of the linear solve.

Reimplemented from AdjointSolve.

Definition at line 96 of file AdjointTransientSolve.C.

99{
100 // Assemble the steady-state version of the adjoint problem
101 AdjointSolve::assembleAdjointSystem(matrix, solution, rhs);
102 // Add the contribution from old solutions
103 rhs += _old_time_residual;
104}
virtual void assembleAdjointSystem(SparseMatrix< Number > &matrix, const NumericVector< Number > &solution, NumericVector< Number > &rhs)
Assembles adjoint system.

◆ checkIntegrity()

void AdjointSolve::checkIntegrity ( )
protectedinherited

Checks whether the forward and adjoint systems are consistent.

Definition at line 200 of file AdjointSolve.C.

201{
202 const auto adj_vars = _nl_adjoint.getVariables(0);
203 for (const auto & adj_var : adj_vars)
204 // If the user supplies any scaling factors for individual variables the
205 // adjoint system won't be consistent.
206 if (!absolute_fuzzy_equals(adj_var->scalingFactor(), 1.0))
208 "User cannot supply scaling factors for adjoint variables. Adjoint system is scaled "
209 "automatically by the forward system.");
210
211 // This is to prevent automatic scaling of the adjoint system. Scaling is
212 // taken from the forward system
213 if (_nl_adjoint.hasVector("scaling_factors"))
214 _nl_adjoint.removeVector("scaling_factors");
215
216 // Main thing is that the number of dofs in each system is the same
219 "The forward and adjoint systems do not seem to be the same size. This could be due to (1) "
220 "the number of variables added to each system is not the same, (2) variables do not have "
221 "consistent family/order, (3) variables do not have the same block restriction.");
222}
virtual libMesh::System & system() override
bool hasVector(const std::string &tag_name) const
void removeVector(const std::string &name)
const std::vector< MooseVariableFieldBase * > & getVariables(THREAD_ID tid)
dof_id_type n_dofs() const
bool absolute_fuzzy_equals(const T &var1, const T2 &var2, const Real tol=TOLERANCE *TOLERANCE)

Referenced by AdjointSolve::solve().

◆ evaluateTimeResidual()

void AdjointTransientSolve::evaluateTimeResidual ( const NumericVector< Number > &  solution,
NumericVector< Number > &  residual 
)
protected

This evaluates the time part of the adjoint residual.

This is used to accumulate the source contribution from previous adjoint time steps for the next adjoint time step. It works by evaluating the Jacobian of the time-derivative term on the forward system and multiplying the transpose by the current adjoint solution.

Parameters
solutionCurrent adjoint solution
residualVector to save the result into

Definition at line 107 of file AdjointTransientSolve.C.

109{
110 // This tag should exist, but the matrix might not necessarily be added
111 auto time_matrix_tag = _problem.getMatrixTagID("TIME");
112 // Use the adjoint system matrix to hold the time Jacobian
113 auto & time_matrix = static_cast<ImplicitSystem &>(_nl_adjoint.system()).get_system_matrix();
114
115 // Make sure we tell the problem which system we are evaluating
117 // Accumulate the time part of the Jacobian into the adjoint matrix
118 _problem.computeJacobianTag(*_nl_forward.currentSolution(), time_matrix, time_matrix_tag);
119
120 // Perform multiplication of the adjoint solution on the transpose of the time Jacobian
121 residual.zero();
122 residual.add_vector_transpose(solution, time_matrix);
123}
void setCurrentNonlinearSystem(const unsigned int nl_sys_num)
virtual void computeJacobianTag(const NumericVector< libMesh::Number > &soln, libMesh::SparseMatrix< libMesh::Number > &jacobian, TagID tag)
FEProblemBase & _problem
virtual const NumericVector< Number > *const & currentSolution() const override final
virtual TagID getMatrixTagID(const TagName &tag_name) const
virtual void add_vector_transpose(const NumericVector< T > &v, const SparseMatrix< T > &A)=0
virtual void zero()=0

Referenced by solve().

◆ getForwardSolutionName()

static std::string AdjointTransientSolve::getForwardSolutionName ( int  tstep)
inlinestaticprotected

Prescribed name of the forward solution at a specified time step.

Parameters
tstepThe forward time step
Returns
std::string The name of the vector representing the forward solution on the adjoint system

Definition at line 89 of file AdjointTransientSolve.h.

90 {
91 return "forward_solution" + std::to_string(tstep);
92 }

Referenced by insertForwardSolution().

◆ insertForwardSolution()

void AdjointTransientSolve::insertForwardSolution ( int  tstep)

This function should be called after every converged forward time step.

It adds a new vector (if necessary) to the adjoint system representing the forward solution at the given time step.

Parameters
tstepTime step of the forward solution in which to store in _forward_solutions

Definition at line 49 of file AdjointTransientSolve.C.

50{
51 // Time step should not be negative
52 if (tstep < 0)
53 mooseError("Negative time step occurred.");
54 auto t_step = cast_int<std::size_t>(tstep); // Avoid compiler warnings
55 // Should not be inserting a time greater the last one inserted
56 if (t_step > _forward_solutions.size())
57 mooseError("Trying to insert a solution at a time-step greater than one past the previously "
58 "inserted time step. Previous time step = ",
59 (int)_forward_solutions.size() - 1,
60 ", inserted time step = ",
61 t_step,
62 ".");
63
64 // Add vector name to member variable if this time has not occurred
65 if (t_step == _forward_solutions.size())
67
68 // Get/add vector from/to adjoint system
69 auto & solution = _nl_adjoint.addVector(_forward_solutions[t_step], false, PARALLEL);
70
71 // Set the vector to the inserted solution
72 solution = _nl_forward.solution();
73}
static std::string getForwardSolutionName(int tstep)
Prescribed name of the forward solution at a specified time step.
NumericVector< Number > & solution()
NumericVector< Number > & addVector(const std::string &vector_name, const bool project, const libMesh::ParallelType type)

Referenced by TransientAndAdjoint::postStep(), and TransientAndAdjoint::preExecute().

◆ setForwardSolution()

void AdjointTransientSolve::setForwardSolution ( int  tstep)

Takes the previously saved forward solutions residing in the adjoint system and copies them to the available solution states in the forward systems.

This should be called at each adjoint time step.

Parameters
tstepThe forward time step index being evaluated during the adjoint solve.

Definition at line 76 of file AdjointTransientSolve.C.

77{
78 // Make sure the time step was saved
79 if (tstep < 0 || tstep >= cast_int<int>(_forward_solutions.size()))
80 mooseError("Could not find forward solution at time step ", tstep, ".");
81 auto t_step = cast_int<std::size_t>(tstep); // Avoid compiler warnings
82
83 // Copy the solutions to states that exist in the system
84 unsigned int state = 0;
85 while (_nl_forward.hasSolutionState(state))
86 {
87 const auto & name = t_step > state ? _forward_solutions[t_step - state] : _forward_solutions[0];
89 state++;
90 }
91
93}
const std::string & name() const
virtual NumericVector< Number > & getVector(const std::string &name)
virtual NumericVector< Number > & solutionState(const unsigned int state, Moose::SolutionIterationType iteration_type=Moose::SolutionIterationType::Time)
virtual bool hasSolutionState(const unsigned int state, Moose::SolutionIterationType iteration_type=Moose::SolutionIterationType::Time) const

Referenced by TransientAndAdjoint::postExecute().

◆ solve()

bool AdjointTransientSolve::solve ( )
overridevirtual

Overriding parent class so the time-derivative residual is stored for the next time step.

Reimplemented from AdjointSolve.

Definition at line 37 of file AdjointTransientSolve.C.

38{
40
41 // Gather the contribution of this timestep to add to the next solve's source
42 if (converged)
44
45 return converged;
46}
virtual bool solve() override
Solve the adjoint system with the following procedure:
void evaluateTimeResidual(const NumericVector< Number > &solution, NumericVector< Number > &residual)
This evaluates the time part of the adjoint residual.
bool converged(const std::vector< std::pair< unsigned int, Real > > &residuals, const std::vector< Real > &abs_tolerances)
Based on the residuals, determine if the iterative process converged or not.

Referenced by TransientAndAdjoint::postExecute().

◆ validParams()

InputParameters AdjointTransientSolve::validParams ( )
static

Definition at line 22 of file AdjointTransientSolve.C.

23{
25 return params;
26}
static InputParameters validParams()

Referenced by TransientAndAdjoint::validParams().

Member Data Documentation

◆ _adjoint_sys_num

const unsigned int AdjointSolve::_adjoint_sys_num
protectedinherited

The number of the nonlinear system representing the adjoint model.

Definition at line 88 of file AdjointSolve.h.

Referenced by AdjointSolve::assembleAdjointSystem().

◆ _forward_solutions

std::vector<std::string>& AdjointTransientSolve::_forward_solutions
private

Name of the forward solution at each time step residing in the adjoint system.

Definition at line 98 of file AdjointTransientSolve.h.

Referenced by insertForwardSolution(), and setForwardSolution().

◆ _forward_sys_num

const unsigned int AdjointSolve::_forward_sys_num
protectedinherited

The number of the nonlinear system representing the forward model.

Definition at line 86 of file AdjointSolve.h.

Referenced by AdjointSolve::applyNodalBCs(), AdjointSolve::assembleAdjointSystem(), and evaluateTimeResidual().

◆ _nl_adjoint

NonlinearSystemBase& AdjointSolve::_nl_adjoint
protectedinherited

◆ _nl_forward

NonlinearSystemBase& AdjointSolve::_nl_forward
protectedinherited

◆ _old_time_residual

NumericVector<Number>& AdjointTransientSolve::_old_time_residual
private

The residual contribution from previous adjoint solutions.

Definition at line 96 of file AdjointTransientSolve.h.

Referenced by assembleAdjointSystem(), and solve().


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