Alsvinn  0.5.3
The fast FVM simulator with UQ support
Namespaces | Classes | Typedefs | Functions
alsfvm::numflux Namespace Reference

Namespaces

 buckleyleverett
 
 burgers
 
 cubic
 
 euler
 
 linear
 

Classes

class  Central
 
class  has_stencil
 SFINAE test, see http://stackoverflow.com/a/257382. More...
 
class  LaxFriedrichs
 
class  NumericalFlux
 
class  NumericalFluxCPU
 
class  NumericalFluxCUDA
 
class  NumericalFluxFactory
 
class  Rusanov
 
class  ScalarEntropyConservativeFlux
 
class  TecnoCombined4
 
class  TecnoCombined6
 

Typedefs

typedef boost::fusion::map< boost::fusion::pair< equation::euler::Euler< 1 >, boost::fusion::vector< euler::HLL< 1 >, euler::HLL3< 1 >, Central< equation::euler::Euler< 1 > >, euler::Tecno1< 1 >, TecnoCombined4< equation::euler::Euler< 1 >, euler::Tecno1< 1 > >, TecnoCombined6< equation::euler::Euler< 1 >, euler::Tecno1< 1 > > > >, boost::fusion::pair< equation::euler::Euler< 2 >, boost::fusion::vector< euler::HLL< 2 >, euler::HLL3< 2 >, Central< equation::euler::Euler< 2 > >, euler::Tecno1< 2 >, TecnoCombined4< equation::euler::Euler< 2 >, euler::Tecno1< 2 > >, TecnoCombined6< equation::euler::Euler< 2 >, euler::Tecno1< 2 > > > >, boost::fusion::pair< equation::euler::Euler< 3 >, boost::fusion::vector< euler::HLL< 3 >, euler::HLL3< 3 >, Central< equation::euler::Euler< 3 > >, euler::Tecno1< 3 >, TecnoCombined4< equation::euler::Euler< 3 >, euler::Tecno1< 3 > >, TecnoCombined6< equation::euler::Euler< 3 >, euler::Tecno1< 3 > > > >, boost::fusion::pair< equation::burgers::Burgers, boost::fusion::vector< Central< equation::burgers::Burgers >, Rusanov< equation::burgers::Burgers >, burgers::Godunov, burgers::Roe, ScalarEntropyConservativeFlux< equation::burgers::Burgers >, TecnoCombined4< equation::burgers::Burgers, ScalarEntropyConservativeFlux< equation::burgers::Burgers > >, TecnoCombined4<::alsfvm::equation::burgers::Burgers, burgers::Godunov >, TecnoCombined6< equation::burgers::Burgers, ScalarEntropyConservativeFlux< equation::burgers::Burgers > >, TecnoCombined6<::alsfvm::equation::burgers::Burgers, burgers::Godunov > > >, boost::fusion::pair< equation::buckleyleverett::BuckleyLeverett, boost::fusion::vector< Central< equation::buckleyleverett::BuckleyLeverett >, buckleyleverett::Godunov, Rusanov< equation::buckleyleverett::BuckleyLeverett > > >, boost::fusion::pair< equation::cubic::Cubic, boost::fusion::vector< Central< equation::cubic::Cubic >, cubic::Roe, Rusanov< equation::cubic::Cubic > > >, boost::fusion::pair< equation::linear::Linear, boost::fusion::vector< Central< equation::linear::Linear >, Rusanov< equation::linear::Linear >, linear::Roe, linear::Upwind > > > NumericalFluxList
 

Functions

template<class Equation , class Function >
void for_each_flux (Function f)
 
template<class NumericalFluxType >
__device__ __host__ auto getStencil (NumericalFluxType) -> typename std::enable_if< has_stencil< NumericalFluxType >::value, decltype(NumericalFluxType::stencil())>::type
 Gets the stencil for numerical fluxes that have a stencil defined. More...
 
template<class NumericalFluxType >
__device__ __host__ std::enable_if< !has_stencil< NumericalFluxType >::value, ivec2 >::type getStencil (NumericalFluxType)
 
template<class Flux , class Equation , size_t direction>
__device__ __host__ real computeFluxForStencil (const Equation &eq, ivec2 indices, typename Equation::ConstViews &left, typename Equation::ConstViews &right, typename Equation::ConservedVariables &out)
 
template<class Flux , class Equation , size_t direction>
__device__ __host__ real computeFluxForStencil (const Equation &eq, ivec4 indices, typename Equation::ConstViews &left, typename Equation::ConstViews &right, typename Equation::ConservedVariables &out)
 
template<class Flux , class Equation , size_t direction>
__device__ __host__ real computeFluxForStencil (const Equation &eq, ivec6 indices, typename Equation::ConstViews &left, typename Equation::ConstViews &right, typename Equation::ConservedVariables &out)
 
__device__ __host__ real bar (real left, real right)
 
__device__ __host__ real diff (real left, real right)
 
__device__ __host__ real ln (real left, real right)
 
__device__ __host__ real divLn (real left, real right, real F)
 
__device__ __host__ real div (real a, real b)
 
template<class Flux , class Equation , size_t direction>
void computeNetFlux (const Equation &eq, const volume::Volume &left, const volume::Volume &right, volume::Volume &out, volume::Volume &temporaryVolume, real &waveSpeed, size_t numberOfGhostCells, const ivec3 start, const ivec3 end)
 
template<class Equation >
void makeZero (Equation &equation, volume::Volume &out, const ivec3 start, const ivec3 end)
 

Typedef Documentation

◆ NumericalFluxList

typedef boost::fusion::map<boost::fusion::pair<equation::euler::Euler<1>, boost::fusion::vector< euler::HLL<1>, euler::HLL3<1>, Central<equation::euler::Euler<1> >, euler::Tecno1<1>, TecnoCombined4<equation::euler::Euler<1>, euler::Tecno1<1> >, TecnoCombined6<equation::euler::Euler<1>, euler::Tecno1<1> > > >, boost::fusion::pair<equation::euler::Euler<2>, boost::fusion::vector< euler::HLL<2>, euler::HLL3<2>, Central<equation::euler::Euler<2> >, euler::Tecno1<2>, TecnoCombined4<equation::euler::Euler<2>, euler::Tecno1<2> >, TecnoCombined6<equation::euler::Euler<2>, euler::Tecno1<2> > > >, boost::fusion::pair<equation::euler::Euler<3>, boost::fusion::vector< euler::HLL<3>, euler::HLL3<3>, Central<equation::euler::Euler<3> >, euler::Tecno1<3>, TecnoCombined4<equation::euler::Euler<3>, euler::Tecno1<3> >, TecnoCombined6<equation::euler::Euler<3>, euler::Tecno1<3> > > >, boost::fusion::pair < equation::burgers::Burgers, boost::fusion::vector < Central<equation::burgers::Burgers>, Rusanov<equation::burgers::Burgers>, burgers::Godunov, burgers::Roe, ScalarEntropyConservativeFlux<equation::burgers::Burgers>, TecnoCombined4<equation::burgers::Burgers, ScalarEntropyConservativeFlux<equation::burgers::Burgers> >, TecnoCombined4<::alsfvm::equation::burgers::Burgers, burgers::Godunov>, TecnoCombined6<equation::burgers::Burgers, ScalarEntropyConservativeFlux<equation::burgers::Burgers> >, TecnoCombined6<::alsfvm::equation::burgers::Burgers, burgers::Godunov> > >, boost::fusion::pair < equation::buckleyleverett::BuckleyLeverett, boost::fusion::vector < Central<equation::buckleyleverett::BuckleyLeverett>, buckleyleverett::Godunov, Rusanov<equation::buckleyleverett::BuckleyLeverett> > >, boost::fusion::pair < equation::cubic::Cubic, boost::fusion::vector < Central<equation::cubic::Cubic>, cubic::Roe, Rusanov<equation::cubic::Cubic> > >, boost::fusion::pair < equation::linear::Linear, boost::fusion::vector < Central<equation::linear::Linear>, Rusanov<equation::linear::Linear>, linear::Roe, linear::Upwind > > > alsfvm::numflux::NumericalFluxList

Function Documentation

◆ bar()

__device__ __host__ real alsfvm::numflux::bar ( real  left,
real  right 
)
inline

◆ computeFluxForStencil() [1/3]

template<class Flux , class Equation , size_t direction>
__device__ __host__ real alsfvm::numflux::computeFluxForStencil ( const Equation &  eq,
ivec2  indices,
typename Equation::ConstViews &  left,
typename Equation::ConstViews &  right,
typename Equation::ConservedVariables &  out 
)

◆ computeFluxForStencil() [2/3]

template<class Flux , class Equation , size_t direction>
__device__ __host__ real alsfvm::numflux::computeFluxForStencil ( const Equation &  eq,
ivec4  indices,
typename Equation::ConstViews &  left,
typename Equation::ConstViews &  right,
typename Equation::ConservedVariables &  out 
)

For higher order fluxes.

Note
Here we assume the left input array equals the right one

◆ computeFluxForStencil() [3/3]

template<class Flux , class Equation , size_t direction>
__device__ __host__ real alsfvm::numflux::computeFluxForStencil ( const Equation &  eq,
ivec6  indices,
typename Equation::ConstViews &  left,
typename Equation::ConstViews &  right,
typename Equation::ConservedVariables &  out 
)

For higher order fluxes.

Note
Here we assume the left input array equals the right one

◆ computeNetFlux()

template<class Flux , class Equation , size_t direction>
void alsfvm::numflux::computeNetFlux ( const Equation &  eq,
const volume::Volume left,
const volume::Volume right,
volume::Volume out,
volume::Volume temporaryVolume,
real waveSpeed,
size_t  numberOfGhostCells,
const ivec3  start,
const ivec3  end 
)

◆ diff()

__device__ __host__ real alsfvm::numflux::diff ( real  left,
real  right 
)
inline

◆ div()

__device__ __host__ real alsfvm::numflux::div ( real  a,
real  b 
)
inline

◆ divLn()

__device__ __host__ real alsfvm::numflux::divLn ( real  left,
real  right,
real  F 
)
inline

Computes F/ln (left, right), but takes care if divLn==0, then it returns 0

◆ for_each_flux()

template<class Equation , class Function >
void alsfvm::numflux::for_each_flux ( Function  f)

◆ getStencil() [1/2]

template<class NumericalFluxType >
__device__ __host__ auto alsfvm::numflux::getStencil ( NumericalFluxType  ) -> typename std::enable_if<has_stencil<NumericalFluxType>::value, decltype(NumericalFluxType::stencil())>::type

Gets the stencil for numerical fluxes that have a stencil defined.

◆ getStencil() [2/2]

template<class NumericalFluxType >
__device__ __host__ std::enable_if< !has_stencil<NumericalFluxType>::value,ivec2 >::type alsfvm::numflux::getStencil ( NumericalFluxType  )

Gets the default numerical stencil (0,1) See http://stackoverflow.com/a/31860104 for how the overloading works

◆ ln()

__device__ __host__ real alsfvm::numflux::ln ( real  left,
real  right 
)
inline

◆ makeZero()

template<class Equation >
void alsfvm::numflux::makeZero ( Equation &  equation,
volume::Volume out,
const ivec3  start,
const ivec3  end 
)