A linear system assembler (residual and Jacobian) for finite volume schemes (box, tpfa, mpfa, ...). More...
#include <dumux/assembly/fvassembler.hh>
A linear system assembler (residual and Jacobian) for finite volume schemes (box, tpfa, mpfa, ...).
| TypeTag | The TypeTag |
| diffMethod | The differentiation method to residual compute derivatives |
| isImplicit | Specifies whether the time discretization is implicit or not not (i.e. explicit) |
Public Types | |
| using | Scalar = GetPropType<TypeTag, Properties::Scalar> |
| using | JacobianMatrix = GetPropType<TypeTag, Properties::JacobianMatrix> |
| using | GridGeometry = GetPropType<TypeTag, Properties::GridGeometry> |
| using | Problem = GetPropType<TypeTag, Properties::Problem> |
| using | GridVariables = GetPropType<TypeTag, Properties::GridVariables> |
| using | ResidualType = SolutionVector |
Public Member Functions | |
| FVAssembler (std::shared_ptr< const Problem > problem, std::shared_ptr< const GridGeometry > gridGeometry, std::shared_ptr< GridVariables > gridVariables) | |
| The constructor for stationary problems. | |
| FVAssembler (std::shared_ptr< const Problem > problem, std::shared_ptr< const GridGeometry > gridGeometry, std::shared_ptr< GridVariables > gridVariables, std::shared_ptr< const TimeLoop > timeLoop, const SolutionVector &prevSol) | |
| The constructor for instationary problems. | |
| template<class PartialReassembler = DefaultPartialReassembler> | |
| void | assembleJacobianAndResidual (const SolutionVector &curSol, const PartialReassembler *partialReassembler=nullptr) |
| Assembles the global Jacobian of the residual and the residual for the current solution. | |
| void | assembleJacobian (const SolutionVector &curSol) |
| Assembles only the global Jacobian of the residual. | |
| void | assembleResidual (const SolutionVector &curSol) |
| compute the residuals using the internal residual | |
| void | assembleResidual (ResidualType &r, const SolutionVector &curSol) const |
| assemble a residual r | |
| Scalar | residualNorm (const SolutionVector &curSol) const |
| compute the residual and return it's vector norm | |
| void | setLinearSystem (std::shared_ptr< JacobianMatrix > A, std::shared_ptr< SolutionVector > r) |
| Tells the assembler which jacobian and residual to use. This also resizes the containers to the required sizes and sets the sparsity pattern of the jacobian matrix. | |
| void | setLinearSystem () |
| The version without arguments uses the default constructor to create the jacobian and residual objects in this assembler if you don't need them outside this class. | |
| void | setJacobianPattern () |
| Resizes the jacobian and sets the jacobian' sparsity pattern. | |
| void | setResidualSize () |
| Resizes the residual. | |
| std::size_t | numDofs () const |
| Returns the number of degrees of freedom. | |
| const Problem & | problem () const |
| The problem. | |
| const GridGeometry & | gridGeometry () const |
| The global finite volume geometry. | |
| const GridView & | gridView () const |
| The gridview. | |
| GridVariables & | gridVariables () |
| The global grid variables. | |
| const GridVariables & | gridVariables () const |
| The global grid variables. | |
| JacobianMatrix & | jacobian () |
| The jacobian matrix. | |
| SolutionVector & | residual () |
| The residual vector (rhs). | |
| const SolutionVector & | prevSol () const |
| The solution of the previous time step. | |
| void | setTimeLoop (std::shared_ptr< const TimeLoop > timeLoop) |
| Set time loop for instationary problems. | |
| void | setPreviousSolution (const SolutionVector &u) |
| Sets the solution from which to start the time integration. Has to be called prior to assembly for time-dependent problems. | |
| bool | isStationaryProblem () const |
| Whether we are assembling a stationary or instationary problem. | |
| LocalResidual | localResidual () const |
| Create a local residual object (used by the local assembler). | |
| void | updateGridVariables (const SolutionVector &cursol) |
| Update the grid variables. | |
| void | resetTimeStep (const SolutionVector &cursol) |
| Reset the gridVariables. | |
| using Dumux::FVAssembler< TypeTag, diffMethod, isImplicit >::GridGeometry = GetPropType<TypeTag, Properties::GridGeometry> |
| using Dumux::FVAssembler< TypeTag, diffMethod, isImplicit >::GridVariables = GetPropType<TypeTag, Properties::GridVariables> |
| using Dumux::FVAssembler< TypeTag, diffMethod, isImplicit >::JacobianMatrix = GetPropType<TypeTag, Properties::JacobianMatrix> |
| using Dumux::FVAssembler< TypeTag, diffMethod, isImplicit >::Problem = GetPropType<TypeTag, Properties::Problem> |
| using Dumux::FVAssembler< TypeTag, diffMethod, isImplicit >::ResidualType = SolutionVector |
| using Dumux::FVAssembler< TypeTag, diffMethod, isImplicit >::Scalar = GetPropType<TypeTag, Properties::Scalar> |
|
inline |
The constructor for stationary problems.
|
inline |
The constructor for instationary problems.
|
inline |
Assembles only the global Jacobian of the residual.
|
inline |
Assembles the global Jacobian of the residual and the residual for the current solution.
|
inline |
compute the residuals using the internal residual
|
inline |
assemble a residual r
|
inline |
The global finite volume geometry.
|
inline |
The global grid variables.
|
inline |
The global grid variables.
|
inline |
The gridview.
|
inline |
Whether we are assembling a stationary or instationary problem.
|
inline |
The jacobian matrix.
|
inline |
Create a local residual object (used by the local assembler).
|
inline |
Returns the number of degrees of freedom.
|
inline |
The solution of the previous time step.
|
inline |
The problem.
|
inline |
Reset the gridVariables.
|
inline |
The residual vector (rhs).
|
inline |
compute the residual and return it's vector norm
|
inline |
Resizes the jacobian and sets the jacobian' sparsity pattern.
|
inline |
The version without arguments uses the default constructor to create the jacobian and residual objects in this assembler if you don't need them outside this class.
|
inline |
Tells the assembler which jacobian and residual to use. This also resizes the containers to the required sizes and sets the sparsity pattern of the jacobian matrix.
|
inline |
Sets the solution from which to start the time integration. Has to be called prior to assembly for time-dependent problems.
|
inline |
Resizes the residual.
|
inline |
Set time loop for instationary problems.
|
inline |
Update the grid variables.