|
Smith
0.1
Smith is an implicit thermal structural mechanics simulation code.
|
Abstract interface to DifferentiableSolver interface. Each differentiable solve should provide both its forward solve and an adjoint solve. More...
#include <differentiable_solver.hpp>
Public Member Functions | |
| virtual | ~DifferentiableSolver () |
| destructor | |
| virtual void | completeSetup (const smith::FiniteElementState &u)=0 |
| Required for certain solvers/preconditioners, e.g. when multigrid algorithms want a near null-space For these cases, it should be called before solve. | |
| virtual std::shared_ptr< smith::FiniteElementState > | solve (const smith::FiniteElementState &u_guess, std::function< mfem::Vector(const smith::FiniteElementState &)> equation, std::function< std::unique_ptr< mfem::HypreParMatrix >(const smith::FiniteElementState &)> jacobian) const =0 |
| Solve a set of equations with a FiniteElementState as unknown. More... | |
| virtual std::shared_ptr< smith::FiniteElementState > | solveAdjoint (const smith::FiniteElementDual &u_bar, std::unique_ptr< mfem::HypreParMatrix > jacobian_transposed) const =0 |
| Solve the (linear) adjoint set of equations with a FiniteElementState as unknown. More... | |
| virtual void | clearMemory () const |
| Interface option to clear memory between solves to avoid high-water mark memory usage. | |
Abstract interface to DifferentiableSolver interface. Each differentiable solve should provide both its forward solve and an adjoint solve.
Definition at line 37 of file differentiable_solver.hpp.
|
pure virtual |
Solve a set of equations with a FiniteElementState as unknown.
| u_guess | initial guess for solver |
| equation | std::function for equation to be solved |
| jacobian | std::function for evaluating the linearized Jacobian about the current solution |
Implemented in smith::NonlinearDifferentiableSolver, and smith::LinearDifferentiableSolver.
|
pure virtual |
Solve the (linear) adjoint set of equations with a FiniteElementState as unknown.
| u_bar | rhs for the solve |
| jacobian_transposed | the evaluated linearized adjoint space matrix |
Implemented in smith::NonlinearDifferentiableSolver, and smith::LinearDifferentiableSolver.