dune-pdelab  2.4-dev
Public Types | Public Member Functions | List of all members
Dune::PDELab::StokesDGVectorFEM< F, B, V, P, IP > Class Template Reference

A local operator for solving the stokes equation using a DG discretization and a vector valued finite element map for the velocity grid function space. More...

#include <dune/pdelab/localoperator/stokesdg_vecfem.hh>

Inheritance diagram for Dune::PDELab::StokesDGVectorFEM< F, B, V, P, IP >:
Inheritance graph

Public Types

enum  { doPatternVolume = true }
 
enum  { doPatternSkeleton = true }
 
enum  { doAlphaVolume = true }
 
enum  { doAlphaSkeleton = true }
 
enum  { doAlphaBoundary = true }
 
typedef IP InteriorPenaltyFactor
 
typedef double RealType
 
Flags for the sparsity pattern
enum  { doPatternVolume }
 Whether to assemble the pattern on the elements, i.e. whether or not pattern_volume() should be called. More...
 
enum  { doPatternVolumePostSkeleton }
 Whether to assemble the pattern on the elements after the skeleton has been handled, i.e. whether or not pattern_volume_post_skeleton() should be called. More...
 
enum  { doPatternSkeleton }
 Whether to assemble the pattern on the interior intersections, i.e. whether or not pattern_skeleton() should be called. More...
 
enum  { doPatternBoundary }
 Whether to assemble the pattern on the boundary intersections, i.e. whether or not pattern_boundary() should be called. More...
 
Flags for the non-constant part of the residual and the jacobian
enum  { doAlphaVolume }
 Whether to call the local operator's alpha_volume(), jacobian_apply_volume() and jacobian_volume(). More...
 
enum  { doAlphaVolumePostSkeleton }
 Whether to call the local operator's alpha_volume_post_skeleton(), jacobian_apply_volume_post_skeleton() and jacobian_volume_post_skeleton(). More...
 
enum  { doAlphaSkeleton }
 Whether to call the local operator's alpha_skeleton(), jacobian_apply_skeleton() and jacobian_skeleton(). More...
 
enum  { doAlphaBoundary }
 Whether to call the local operator's alpha_boundary(), jacobian_apply_boundary() and jacobian_boundary(). More...
 
Flags for the constant part of the residual
enum  { doLambdaVolume }
 Whether to call the local operator's lambda_volume(). More...
 
enum  { doLambdaVolumePostSkeleton }
 Whether to call the local operator's lambda_volume_post_skeleton(). More...
 
enum  { doLambdaSkeleton }
 Whether to call the local operator's lambda_skeleton(). More...
 
enum  { doLambdaBoundary }
 Whether to call the local operator's lambda_boundary(). More...
 
Special flags
enum  { doSkeletonTwoSided }
 Whether to visit the skeleton methods from both sides. More...
 

Public Member Functions

 StokesDGVectorFEM (const Dune::ParameterTree &configuration, const IP &ip_factor_, const RF mu_, const F &_f, const B &_b, const V &_v, const P &_p, int _qorder=4)
 
template<typename EG , typename LFSU , typename X , typename LFSV , typename R >
void alpha_volume (const EG &eg, const LFSU &lfsu, const X &x, const LFSV &lfsv, R &r) const
 
template<typename IG , typename LFSU , typename X , typename LFSV , typename R >
void alpha_skeleton (const IG &ig, const LFSU &lfsu_s, const X &x_s, const LFSV &lfsv_s, const LFSU &lfsu_n, const X &x_n, const LFSV &lfsv_n, R &r_s, R &r_n) const
 
template<typename IG , typename LFSU , typename X , typename LFSV , typename R >
void alpha_boundary (const IG &ig, const LFSU &lfsu_s, const X &x_s, const LFSV &lfsv_s, R &r_s) const
 
template<typename LFSU , typename LFSV , typename LocalPattern >
void pattern_skeleton (const LFSU &lfsu_s, const LFSV &lfsv_s, const LFSU &lfsu_n, const LFSV &lfsv_n, LocalPattern &pattern_sn, LocalPattern &pattern_ns) const
 
template<typename LFSU , typename LFSV , typename LocalPattern >
void pattern_volume (const LFSU &lfsu, const LFSV &lfsv, LocalPattern &pattern) const
 
void jacobian_apply_volume (const EG &eg, const LFSU &lfsu, const X &x, const LFSV &lfsv, Y &y) const
 apply local jacobian of the volume term More...
 
void jacobian_volume (const EG &eg, const LFSU &lfsu, const X &x, const LFSV &lfsv, Jacobian &mat) const
 compute local jacobian of the volume term More...
 
void jacobian_apply_skeleton (const IG &ig, const LFSU &lfsu_s, const X &x_s, const LFSV &lfsv_s, const LFSU &lfsu_n, const X &x_n, const LFSV &lfsv_n, Y &y_s, Y &y_n) const
 apply local jacobian of the skeleton term More...
 
void jacobian_skeleton (const IG &ig, const LFSU &lfsu_s, const X &x_s, const LFSV &lfsv_s, const LFSU &lfsu_n, const X &x_n, const LFSV &lfsv_n, Jacobian &mat_ss, Jacobian &mat_sn, Jacobian &mat_ns, Jacobian &mat_nn) const
 compute local jacobian of the skeleton term More...
 
void jacobian_apply_boundary (const IG &ig, const LFSU &lfsu_s, const X &x_s, const LFSV &lfsv_s, Y &y_s) const
 apply local jacobian of the boundaryterm More...
 
void jacobian_boundary (const IG &ig, const LFSU &lfsu_s, const X &x_s, const LFSV &lfsv_s, Jacobian &mat_ss) const
 compute local jacobian of the boundary term More...
 
void setTime (doublet_)
 set time for subsequent evaluation More...
 
double getTime () const
 get current time More...
 
void preStep (RealType time, RealType dt, int stages)
 to be called once before each time step More...
 
void postStep ()
 to be called once at the end of each time step More...
 
void preStage (RealType time, int r)
 to be called once before each stage More...
 
int getStage () const
 get current stage More...
 
void postStage ()
 to be called once at the end of each stage More...
 
RealType suggestTimestep (RealType dt) const
 to be called after stage 1 More...
 

Detailed Description

template<typename F, typename B, typename V, typename P, typename IP = DefaultInteriorPenalty<typename V::Traits::RangeFieldType>>
class Dune::PDELab::StokesDGVectorFEM< F, B, V, P, IP >

A local operator for solving the stokes equation using a DG discretization and a vector valued finite element map for the velocity grid function space.

Template Parameters
Fvelocity source term function
Bboundary condition function
Vdirichlet velocity boundary condition function
Pdirichlet pressure boundary condition function
IPa class providing the interior penalty factor for each face

Member Typedef Documentation

template<typename F , typename B , typename V , typename P , typename IP = DefaultInteriorPenalty<typename V::Traits::RangeFieldType>>
typedef IP Dune::PDELab::StokesDGVectorFEM< F, B, V, P, IP >::InteriorPenaltyFactor

Member Enumeration Documentation

template<typename F , typename B , typename V , typename P , typename IP = DefaultInteriorPenalty<typename V::Traits::RangeFieldType>>
anonymous enum
Enumerator
doPatternVolume 
template<typename F , typename B , typename V , typename P , typename IP = DefaultInteriorPenalty<typename V::Traits::RangeFieldType>>
anonymous enum
Enumerator
doPatternSkeleton 
template<typename F , typename B , typename V , typename P , typename IP = DefaultInteriorPenalty<typename V::Traits::RangeFieldType>>
anonymous enum
Enumerator
doAlphaVolume 
template<typename F , typename B , typename V , typename P , typename IP = DefaultInteriorPenalty<typename V::Traits::RangeFieldType>>
anonymous enum
Enumerator
doAlphaSkeleton 
template<typename F , typename B , typename V , typename P , typename IP = DefaultInteriorPenalty<typename V::Traits::RangeFieldType>>
anonymous enum
Enumerator
doAlphaBoundary 

Constructor & Destructor Documentation

template<typename F , typename B , typename V , typename P , typename IP = DefaultInteriorPenalty<typename V::Traits::RangeFieldType>>
Dune::PDELab::StokesDGVectorFEM< F, B, V, P, IP >::StokesDGVectorFEM ( const Dune::ParameterTree &  configuration,
const IP &  ip_factor_,
const RF  mu_,
const F &  _f,
const B &  _b,
const V &  _v,
const P &  _p,
int  _qorder = 4 
)
inline
Deprecated:
"Deprecated in DUNE-PDELab 2.4, use DGNavierStokesVelVecFEM instead!"

Member Function Documentation

template<typename F , typename B , typename V , typename P , typename IP = DefaultInteriorPenalty<typename V::Traits::RangeFieldType>>
template<typename IG , typename LFSU , typename X , typename LFSV , typename R >
void Dune::PDELab::StokesDGVectorFEM< F, B, V, P, IP >::alpha_boundary ( const IG &  ig,
const LFSU &  lfsu_s,
const X &  x_s,
const LFSV &  lfsv_s,
R &  r_s 
) const
inline

References dim, and p.

template<typename F , typename B , typename V , typename P , typename IP = DefaultInteriorPenalty<typename V::Traits::RangeFieldType>>
template<typename IG , typename LFSU , typename X , typename LFSV , typename R >
void Dune::PDELab::StokesDGVectorFEM< F, B, V, P, IP >::alpha_skeleton ( const IG &  ig,
const LFSU &  lfsu_s,
const X &  x_s,
const LFSV &  lfsv_s,
const LFSU &  lfsu_n,
const X &  x_n,
const LFSV &  lfsv_n,
R &  r_s,
R &  r_n 
) const
inline

References dim.

template<typename F , typename B , typename V , typename P , typename IP = DefaultInteriorPenalty<typename V::Traits::RangeFieldType>>
template<typename EG , typename LFSU , typename X , typename LFSV , typename R >
void Dune::PDELab::StokesDGVectorFEM< F, B, V, P, IP >::alpha_volume ( const EG &  eg,
const LFSU &  lfsu,
const X &  x,
const LFSV &  lfsv,
R &  r 
) const
inline

References dim.

int Dune::PDELab::InstationaryLocalOperatorDefaultMethods< double >::getStage ( ) const
inlineinherited

get current stage

Returns
The current stage number previously set by preStage().
double Dune::PDELab::InstationaryLocalOperatorDefaultMethods< double >::getTime ( ) const
inlineinherited

get current time

Returns
The time previously set by setTime().
void Dune::PDELab::NumericalJacobianApplyBoundary< StokesDGVectorFEM< F, B, V, P, IP > >::jacobian_apply_boundary ( const IG &  ig,
const LFSU &  lfsu_s,
const X &  x_s,
const LFSV &  lfsv_s,
Y &  y_s 
) const
inlineinherited

apply local jacobian of the boundaryterm

void Dune::PDELab::NumericalJacobianApplySkeleton< StokesDGVectorFEM< F, B, V, P, IP > >::jacobian_apply_skeleton ( const IG &  ig,
const LFSU &  lfsu_s,
const X &  x_s,
const LFSV &  lfsv_s,
const LFSU &  lfsu_n,
const X &  x_n,
const LFSV &  lfsv_n,
Y &  y_s,
Y &  y_n 
) const
inlineinherited

apply local jacobian of the skeleton term

void Dune::PDELab::NumericalJacobianApplyVolume< StokesDGVectorFEM< F, B, V, P, IP > >::jacobian_apply_volume ( const EG &  eg,
const LFSU &  lfsu,
const X &  x,
const LFSV &  lfsv,
Y &  y 
) const
inlineinherited

apply local jacobian of the volume term

void Dune::PDELab::NumericalJacobianBoundary< StokesDGVectorFEM< F, B, V, P, IP > >::jacobian_boundary ( const IG &  ig,
const LFSU &  lfsu_s,
const X &  x_s,
const LFSV &  lfsv_s,
Jacobian &  mat_ss 
) const
inlineinherited

compute local jacobian of the boundary term

void Dune::PDELab::NumericalJacobianSkeleton< StokesDGVectorFEM< F, B, V, P, IP > >::jacobian_skeleton ( const IG &  ig,
const LFSU &  lfsu_s,
const X &  x_s,
const LFSV &  lfsv_s,
const LFSU &  lfsu_n,
const X &  x_n,
const LFSV &  lfsv_n,
Jacobian &  mat_ss,
Jacobian &  mat_sn,
Jacobian &  mat_ns,
Jacobian &  mat_nn 
) const
inlineinherited

compute local jacobian of the skeleton term

void Dune::PDELab::NumericalJacobianVolume< StokesDGVectorFEM< F, B, V, P, IP > >::jacobian_volume ( const EG &  eg,
const LFSU &  lfsu,
const X &  x,
const LFSV &  lfsv,
Jacobian &  mat 
) const
inlineinherited

compute local jacobian of the volume term

template<typename LFSU , typename LFSV , typename LocalPattern >
void Dune::PDELab::FullSkeletonPattern::pattern_skeleton ( const LFSU &  lfsu_s,
const LFSV &  lfsv_s,
const LFSU &  lfsu_n,
const LFSV &  lfsv_n,
LocalPattern &  pattern_sn,
LocalPattern &  pattern_ns 
) const
inlineinherited
template<typename LFSU , typename LFSV , typename LocalPattern >
void Dune::PDELab::FullVolumePattern::pattern_volume ( const LFSU &  lfsu,
const LFSV &  lfsv,
LocalPattern &  pattern 
) const
inlineinherited
void Dune::PDELab::InstationaryLocalOperatorDefaultMethods< double >::postStage ( )
inlineinherited

to be called once at the end of each stage

void Dune::PDELab::InstationaryLocalOperatorDefaultMethods< double >::postStep ( )
inlineinherited

to be called once at the end of each time step

Note
With the OneStepMethod and the ExplicitOneStepMetod, for reasons unknown this is only called for temporal but not for spatial local operators. With the MultiStepMethod this is called for all local operators.
void Dune::PDELab::InstationaryLocalOperatorDefaultMethods< double >::preStage ( RealType  time,
int  r 
)
inlineinherited

to be called once before each stage

Parameters
timeTime of the stage
rNumber of the stage, r ∈ [1, nstages] inclusive, where nstages is the number of stage in the step given in the previous call to preStep()
Note
For ExplicitOneStepMethod the time given here for stage 1 may be incorrect, since the time step size is only finally determined after the first stage has been assembled.
For the MultiStepMethod, this is called once after preStep() with r=1.
void Dune::PDELab::InstationaryLocalOperatorDefaultMethods< double >::preStep ( RealType  time,
RealType  dt,
int  stages 
)
inlineinherited

to be called once before each time step

Parameters
timeTime at beginning of the step.
dtSize of time step.
stagesNumber of stages to do in the step. For the MultiStepMethod this is always 1.
Note
For ExplicitOneStepMethod the dt given here may be incorrect, since the time step size is only finally determined after the first stage has been assembled.
For the MultiStepMethod the number of stages is given as
  1. Since there are no times of evaluation in the middle of the step, a multi-step method is similar to a one step method with one stage.
void Dune::PDELab::InstationaryLocalOperatorDefaultMethods< double >::setTime ( double  t_)
inlineinherited

set time for subsequent evaluation

This method set the time for subsequent calls to the alpha_*(), lambda_*(), jacobian_*() and jacobian_apply_*() methods.

Note
For ExplicitOneStepMethod the time given here in the first stage may be incorrect, since the time step size is only finally determined after the first stage has been assembled.

Referenced by Dune::PDELab::DGNavierStokes< PRM >::setTime(), and Dune::PDELab::DGNavierStokesVelVecFEM< PRM >::setTime().

RealType Dune::PDELab::InstationaryLocalOperatorDefaultMethods< double >::suggestTimestep ( RealType  dt) const
inlineinherited

to be called after stage 1

Note
Only used by the ExplicitOneStepMethod.

This may be called on the spatial local operator in the case of an explicit one step scheme. It is called after stage 1 has been assembled (so the time given to preStep() may not apply anymore in this case). All the alpha_*() and lambda_*() methods should have been called, so they are a good place to generate the information returned here.


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