3.4
DUNE for Multi-{Phase, Component, Scale, Physics, ...} flow and transport in porous media
Namespaces | Classes | Typedefs | Functions | Variables
Dumux::Detail Namespace Reference

Namespaces

namespace  Staggered
 

Classes

struct  AxisData
 In Axis Data stored per sub face. More...
 
struct  AxisData< GridView, 1 >
 In Axis Data stored per sub face for first-order scheme. More...
 
struct  BlockTypeHelper
 
struct  BlockTypeHelper< S, true >
 
struct  ConcatSeq
 
struct  ConcatSeq< std::index_sequence< Is1... >, offset, std::index_sequence< Is2... > >
 
class  createMultiTypeBlockMatrixType
 a helper class to create a multitype matrix given the diagonal matrix blocks More...
 
struct  GeometryDistance
 
struct  GeometryDistance< Geo1, Geo2, dimWorld, 0, 0 >
 
struct  GeometryDistance< Geo1, Geo2, dimWorld, 0, 1 >
 
struct  GeometryDistance< Geo1, Geo2, dimWorld, 1, 0 >
 
struct  hasState
 helper struct detecting if a PrimaryVariables object has a state() function More...
 
struct  InAxisVelocities
 
struct  InAxisVelocities< Scalar, 1 >
 
struct  isParallelAMGBackend
 
struct  isParallelAMGBackend< Dumux::AMGBiCGSTABBackend< T > >
 
struct  isUG
 
struct  Max
 
struct  Min
 
struct  MultiDomainMatrixType
 helper alias to create the JacobianMatrix type More...
 
struct  MultiDomainTupleSharedPtr
 helper alias to create a tuple of shared_ptr<...> from an indexed type More...
 
struct  MultiDomainTupleSharedPtrConst
 helper alias to create a tuple of shared_ptr<const ...> from an indexed type More...
 
struct  PairData
 Parallel Data stored per sub face. More...
 
struct  PriVarSwitchVariablesType
 
struct  PriVarSwitchVariablesType< Assembler, false >
 
struct  ProblemTraits
 
struct  ProblemTraits< Problem, DiscretizationMethod::box >
 
struct  ProblemTraits< Problem, DiscretizationMethod::ccmpfa >
 
struct  ProblemTraits< Problem, DiscretizationMethod::cctpfa >
 
struct  ProblemTraits< Problem, DiscretizationMethod::staggered >
 
struct  SetEqual
 
struct  Sum
 
struct  supportsPartialReassembly
 helper struct detecting if an assembler supports partial reassembly More...
 
struct  ValidityTestFunctor
 
class  VariablesBackend
 
class  VariablesBackend< Vars, false >
 Class providing operations for primary variable vector/scalar types. More...
 
class  VariablesBackend< Vars, true >
 
struct  VariablesChooser
 
struct  VariablesChooser< A, false >
 
struct  VariablesChooser< A, true >
 
struct  VolVarsWithOutPVSwitch
 
struct  VolVarsWithPVSwitch
 Helper structs to conditionally use a primary variable switch or not. More...
 

Typedefs

template<class Assembler >
using AssemblerVariablesType = typename Assembler::Variables
 
template<class Assembler >
using AssemblerVariables = typename VariablesChooser< Assembler >::Type
 
template<class Vars >
using SolutionVectorType = typename Vars::SolutionVector
 
template<class Assembler , class Index >
using DetectPVSwitchMultiDomain = typename Assembler::template GridVariables< Index::value >::VolumeVariables::PrimaryVariableSwitch
 
template<class Assembler , std::size_t i>
using GetPVSwitchMultiDomain = Dune::Std::detected_or< int, DetectPVSwitchMultiDomain, Assembler, Dune::index_constant< i > >
 
template<class Assembler >
using AssemblerGridVariablesType = typename Assembler::GridVariables
 
template<class Assembler >
using PriVarSwitchVariables = typename PriVarSwitchVariablesType< Assembler, assemblerExportsGridVariables< Assembler > >::Type
 
template<class LinearSolver , class Residual >
using NormDetector = decltype(std::declval< LinearSolver >().norm(std::declval< Residual >()))
 
template<class C >
using dynamicIndexAccess = decltype(std::declval< C >()[0])
 
template<class C >
using staticIndexAccess = decltype(std::declval< C >()[Dune::Indices::_0])
 
template<class SolutionVector >
using BlockType = typename BlockTypeHelper< SolutionVector, Dune::IsNumber< SolutionVector >::value >::type
 
template<class Variables >
using DetectPVSwitch = typename Variables::VolumeVariables::PrimaryVariableSwitch
 helper aliases to extract a primary variable switch from the VolumeVariables (if defined, yields int otherwise) More...
 
template<class Variables >
using GetPVSwitch = Dune::Std::detected_or< int, DetectPVSwitch, Variables >
 
template<class Variables >
using PrimaryVariableSwitch = typename GetPVSwitch< Variables >::type
 
template<class FluidMatrixInteraction >
using AdsorptionModelDetector = decltype(std::declval< FluidMatrixInteraction >().adsorptionModel())
 
template<typename T , typename ... Ts>
using RobinDerivDetector = decltype(std::declval< T >().addRobinFluxDerivatives(std::declval< Ts >()...))
 
template<typename T , typename ... Ts>
using SaturationDetector = decltype(std::declval< T >().spatialParams().saturation(std::declval< Ts >()...))
 

Functions

template<class ElementSolution >
bool allStatesEqual (const ElementSolution &elemSol, std::true_type hasState)
 returns true if all states in an element solution are the same More...
 
template<class ElementSolution >
bool allStatesEqual (const ElementSolution &elemSol, std::false_type hasState)
 overload if the solution is stateless More...
 
template<class Geometry , class ElementSolution >
auto minDistVertexSol (const Geometry &geometry, const typename Geometry::GlobalCoordinate &globalPos, const ElementSolution &elemSol)
 return the solution at the closest dof More...
 
template<class Matrix >
void setupReducedMatrices (const Matrix &massMatrix, const Matrix &projMatrix, const std::vector< bool > &dofIsVoid, Matrix &reducedM, Matrix &reducedP, std::vector< std::size_t > &expansionMap)
 Reduces a mass matrix and projection matrix such that they are composed of only those dofs that actually take part in the projection. Simultaneously, a container with the index map into the complete target space is filled so that the entries after projection can be assigned to the corresponding dof in the overall target space. More...
 
template<bool doBidirectional, class FEBasisDomain , class FEBasisTarget , class GlueType >
auto createProjectionMatrices (const FEBasisDomain &feBasisDomain, const FEBasisTarget &feBasisTarget, const GlueType &glue, bool treatDiagonalZeroes=true)
 Creates the matrices underlying l2-projections. More...
 
template<bool doBidirectional, class FEBasisDomain , class FEBasisTarget , class GlueType >
auto makeProjectorPair (const FEBasisDomain &feBasisDomain, const FEBasisTarget &feBasisTarget, const GlueType &glue)
 Creates a projector class between two function space bases. More...
 
template<class ElemVolVars , class SubControlVolumeFace , class UpwindTermFunction , class Scalar >
Scalar upwindSchemeMultiplier (const ElemVolVars &elemVolVars, const SubControlVolumeFace &scvf, const UpwindTermFunction &upwindTerm, Scalar flux, int phaseIdx)
 returns the upwind factor which is multiplied to the advective flux across the given scvf More...
 
template<class Geo1 , class Geo2 , class ctype , class GetFacetCornerIndices , class ComputeNormalFunction >
bool computeSegmentIntersection (const Geo1 &geo1, const Geo2 &geo2, ctype baseEps, ctype &tfirst, ctype &tlast, const GetFacetCornerIndices &getFacetCornerIndices, const ComputeNormalFunction &computeNormal)
 Algorithm to find segment-like intersections of a polgon/polyhedron with a segment. The result is stored in the form of the local coordinates tfirst and tlast on the segment geo1. More...
 
template<class Function , class Range >
Range evalFunctionForRange (const Function &f, const Range &range)
 
template<class S , class V >
void addDataSetToGnuplot (GnuplotInterface< S > &gnuplot, const V &x, const V &y, const std::string &curveName, const std::string &curveOptions, const std::string &xLabel, const std::string &yLabel)
 
template<class LinearSolver , class Residual >
static constexpr bool hasNorm ()
 
template<class V , class Scalar , class Reduce , class Transform >
auto hybridInnerProduct (const V &v1, const V &v2, Scalar init, Reduce &&r, Transform &&t) -> std::enable_if_t< hasDynamicIndexAccess< V >(), Scalar >
 
template<class Scalar , class V >
auto maxRelativeShift (const V &v1, const V &v2) -> std::enable_if_t< Dune::IsNumber< V >::value, Scalar >
 
template<class To , class From >
void assign (To &to, const From &from)
 
template<class T , std::enable_if_t< Dune::IsNumber< std::decay_t< T > >::value, int > = 0>
constexpr std::size_t blockSize ()
 
template<class FluidMatrixInteraction >
static constexpr bool hasAdsorptionModel ()
 
template<class FluidMatrixInteraction >
static constexpr bool hasAdsorptionModel ()
 
template<class T , typename ... Args>
static constexpr bool hasAddRobinFluxDerivatives ()
 
template<class T , typename ... Args>
static constexpr bool hasSaturation ()
 

Variables

template<class Grid , int dofCodim>
static constexpr bool canCommunicate
 
template<class Assembler >
constexpr bool exportsVariables = Dune::Std::is_detected_v<AssemblerVariablesType, Assembler>
 
template<class Assembler >
constexpr bool assemblerExportsGridVariables = Dune::Std::is_detected_v<AssemblerGridVariablesType, Assembler>
 
template<class C >
static constexpr auto hasDynamicIndexAccess = Dune::Std::is_detected<dynamicIndexAccess, C>{}
 
template<class C >
static constexpr auto hasStaticIndexAccess = Dune::Std::is_detected<staticIndexAccess, C>{}
 

Typedef Documentation

◆ AdsorptionModelDetector

template<class FluidMatrixInteraction >
using Dumux::Detail::AdsorptionModelDetector = typedef decltype(std::declval<FluidMatrixInteraction>().adsorptionModel())

◆ AssemblerGridVariablesType

template<class Assembler >
using Dumux::Detail::AssemblerGridVariablesType = typedef typename Assembler::GridVariables

◆ AssemblerVariables

template<class Assembler >
using Dumux::Detail::AssemblerVariables = typedef typename VariablesChooser<Assembler>::Type

◆ AssemblerVariablesType

template<class Assembler >
using Dumux::Detail::AssemblerVariablesType = typedef typename Assembler::Variables

◆ BlockType

template<class SolutionVector >
using Dumux::Detail::BlockType = typedef typename BlockTypeHelper<SolutionVector, Dune::IsNumber<SolutionVector>::value>::type

◆ DetectPVSwitch

template<class Variables >
using Dumux::Detail::DetectPVSwitch = typedef typename Variables::VolumeVariables::PrimaryVariableSwitch

helper aliases to extract a primary variable switch from the VolumeVariables (if defined, yields int otherwise)

◆ DetectPVSwitchMultiDomain

template<class Assembler , class Index >
using Dumux::Detail::DetectPVSwitchMultiDomain = typedef typename Assembler::template GridVariables<Index::value>::VolumeVariables::PrimaryVariableSwitch

◆ dynamicIndexAccess

template<class C >
using Dumux::Detail::dynamicIndexAccess = typedef decltype(std::declval<C>()[0])

◆ GetPVSwitch

template<class Variables >
using Dumux::Detail::GetPVSwitch = typedef Dune::Std::detected_or<int, DetectPVSwitch, Variables>

◆ GetPVSwitchMultiDomain

template<class Assembler , std::size_t i>
using Dumux::Detail::GetPVSwitchMultiDomain = typedef Dune::Std::detected_or<int, DetectPVSwitchMultiDomain, Assembler, Dune::index_constant<i> >

◆ NormDetector

template<class LinearSolver , class Residual >
using Dumux::Detail::NormDetector = typedef decltype(std::declval<LinearSolver>().norm(std::declval<Residual>()))

◆ PrimaryVariableSwitch

template<class Variables >
using Dumux::Detail::PrimaryVariableSwitch = typedef typename GetPVSwitch<Variables>::type

◆ PriVarSwitchVariables

template<class Assembler >
using Dumux::Detail::PriVarSwitchVariables = typedef typename PriVarSwitchVariablesType<Assembler, assemblerExportsGridVariables<Assembler> >::Type

◆ RobinDerivDetector

template<typename T , typename ... Ts>
using Dumux::Detail::RobinDerivDetector = typedef decltype(std::declval<T>().addRobinFluxDerivatives(std::declval<Ts>()...))

◆ SaturationDetector

template<typename T , typename ... Ts>
using Dumux::Detail::SaturationDetector = typedef decltype(std::declval<T>().spatialParams().saturation(std::declval<Ts>()...))

◆ SolutionVectorType

template<class Vars >
using Dumux::Detail::SolutionVectorType = typedef typename Vars::SolutionVector

◆ staticIndexAccess

template<class C >
using Dumux::Detail::staticIndexAccess = typedef decltype(std::declval<C>()[Dune::Indices::_0])

Function Documentation

◆ addDataSetToGnuplot()

template<class S , class V >
void Dumux::Detail::addDataSetToGnuplot ( GnuplotInterface< S > &  gnuplot,
const V &  x,
const V &  y,
const std::string &  curveName,
const std::string &  curveOptions,
const std::string &  xLabel,
const std::string &  yLabel 
)

◆ allStatesEqual() [1/2]

template<class ElementSolution >
bool Dumux::Detail::allStatesEqual ( const ElementSolution &  elemSol,
std::false_type  hasState 
)

overload if the solution is stateless

◆ allStatesEqual() [2/2]

template<class ElementSolution >
bool Dumux::Detail::allStatesEqual ( const ElementSolution &  elemSol,
std::true_type  hasState 
)

returns true if all states in an element solution are the same

◆ assign()

template<class To , class From >
void Dumux::Detail::assign ( To &  to,
const From &  from 
)

◆ blockSize()

template<class T , std::enable_if_t< Dune::IsNumber< std::decay_t< T > >::value, int > = 0>
constexpr std::size_t Dumux::Detail::blockSize ( )
constexpr

◆ createProjectionMatrices()

template<bool doBidirectional, class FEBasisDomain , class FEBasisTarget , class GlueType >
auto Dumux::Detail::createProjectionMatrices ( const FEBasisDomain &  feBasisDomain,
const FEBasisTarget &  feBasisTarget,
const GlueType &  glue,
bool  treatDiagonalZeroes = true 
)

Creates the matrices underlying l2-projections.

Template Parameters
doBidirectionalIf false, the backward projection matrix is not assembled
Parameters
feBasisDomainThe basis to the domain finite element space
feBasisTargetThe basis to the target finite element space
glueThe glue object containing the intersections between the two grids
treatDiagonalZeroesIf true, zero entries on the diagonal of the matrices that appear if the two domains occupy different geometric regions (and some dofs to not take part in the projection as a result) are substituted by ones. This substitution will lead to those dofs being mapped to zeroes in the target space.
Returns
An std::pair of projection matrices, where the first entry stores the matrices of the forward projection and the second entry stores those of the backward projection. The entries of the returned pair are itself std::pairs which store the mass matrix in the first and the projection matrix in the second entry.

◆ evalFunctionForRange()

template<class Function , class Range >
Range Dumux::Detail::evalFunctionForRange ( const Function &  f,
const Range &  range 
)

◆ hasAddRobinFluxDerivatives()

template<class T , typename ... Args>
static constexpr bool Dumux::Detail::hasAddRobinFluxDerivatives ( )
staticconstexpr

◆ hasAdsorptionModel() [1/2]

template<class FluidMatrixInteraction >
static constexpr bool Dumux::Detail::hasAdsorptionModel ( )
staticconstexpr

◆ hasAdsorptionModel() [2/2]

template<class FluidMatrixInteraction >
static constexpr bool Dumux::Detail::hasAdsorptionModel ( )
staticconstexpr

◆ hasNorm()

template<class LinearSolver , class Residual >
static constexpr bool Dumux::Detail::hasNorm ( )
staticconstexpr

◆ hasSaturation()

template<class T , typename ... Args>
static constexpr bool Dumux::Detail::hasSaturation ( )
staticconstexpr

◆ hybridInnerProduct()

template<class V , class Scalar , class Reduce , class Transform >
auto Dumux::Detail::hybridInnerProduct ( const V &  v1,
const V &  v2,
Scalar  init,
Reduce &&  r,
Transform &&  t 
) -> std::enable_if_t<hasDynamicIndexAccess<V>(), Scalar>

◆ makeProjectorPair()

template<bool doBidirectional, class FEBasisDomain , class FEBasisTarget , class GlueType >
auto Dumux::Detail::makeProjectorPair ( const FEBasisDomain &  feBasisDomain,
const FEBasisTarget &  feBasisTarget,
const GlueType &  glue 
)

Creates a projector class between two function space bases.

Template Parameters
doBidirectionalIf false, the backward projection matrix is not assembled
Returns
an std::pair with the forward and backward projector

◆ maxRelativeShift()

template<class Scalar , class V >
auto Dumux::Detail::maxRelativeShift ( const V &  v1,
const V &  v2 
) -> std::enable_if_t<Dune::IsNumber<V>::value, Scalar>

◆ minDistVertexSol()

template<class Geometry , class ElementSolution >
auto Dumux::Detail::minDistVertexSol ( const Geometry &  geometry,
const typename Geometry::GlobalCoordinate &  globalPos,
const ElementSolution &  elemSol 
)

return the solution at the closest dof

◆ setupReducedMatrices()

template<class Matrix >
void Dumux::Detail::setupReducedMatrices ( const Matrix &  massMatrix,
const Matrix &  projMatrix,
const std::vector< bool > &  dofIsVoid,
Matrix &  reducedM,
Matrix &  reducedP,
std::vector< std::size_t > &  expansionMap 
)

Reduces a mass matrix and projection matrix such that they are composed of only those dofs that actually take part in the projection. Simultaneously, a container with the index map into the complete target space is filled so that the entries after projection can be assigned to the corresponding dof in the overall target space.

◆ upwindSchemeMultiplier()

template<class ElemVolVars , class SubControlVolumeFace , class UpwindTermFunction , class Scalar >
Scalar Dumux::Detail::upwindSchemeMultiplier ( const ElemVolVars &  elemVolVars,
const SubControlVolumeFace &  scvf,
const UpwindTermFunction &  upwindTerm,
Scalar  flux,
int  phaseIdx 
)

returns the upwind factor which is multiplied to the advective flux across the given scvf

Variable Documentation

◆ assemblerExportsGridVariables

template<class Assembler >
constexpr bool Dumux::Detail::assemblerExportsGridVariables = Dune::Std::is_detected_v<AssemblerGridVariablesType, Assembler>
inlineconstexpr

◆ canCommunicate

template<class Grid , int dofCodim>
constexpr bool Dumux::Detail::canCommunicate
staticconstexpr
Initial value:
=
Dune::Capabilities::canCommunicate<Grid, dofCodim>::v
Definition: gridcapabilities.hh:45

◆ exportsVariables

template<class Assembler >
constexpr bool Dumux::Detail::exportsVariables = Dune::Std::is_detected_v<AssemblerVariablesType, Assembler>
inlineconstexpr

◆ hasDynamicIndexAccess

template<class C >
constexpr auto Dumux::Detail::hasDynamicIndexAccess = Dune::Std::is_detected<dynamicIndexAccess, C>{}
staticconstexpr

◆ hasStaticIndexAccess

template<class C >
constexpr auto Dumux::Detail::hasStaticIndexAccess = Dune::Std::is_detected<staticIndexAccess, C>{}
staticconstexpr