OpenLB 1.7
Loading...
Searching...
No Matches
Public Member Functions | List of all members
olb::SuperRelativeErrorLpNorm3D< T, W, P > Class Template Reference

Relative error norm functor. More...

#include <superErrorNorm3D.h>

+ Inheritance diagram for olb::SuperRelativeErrorLpNorm3D< T, W, P >:
+ Collaboration diagram for olb::SuperRelativeErrorLpNorm3D< T, W, P >:

Public Member Functions

template<typename DESCRIPTOR >
 SuperRelativeErrorLpNorm3D (SuperLattice< T, DESCRIPTOR > &sLattice, FunctorPtr< SuperF3D< T, W > > &&f, FunctorPtr< AnalyticalF3D< T, W > > &&wantedF, FunctorPtr< SuperIndicatorF3D< T > > &&indicatorF)
 
template<typename DESCRIPTOR >
 SuperRelativeErrorLpNorm3D (SuperLatticeF3D< T, DESCRIPTOR > &f, FunctorPtr< AnalyticalF3D< T, W > > &&wantedF, FunctorPtr< SuperIndicatorF3D< T > > &&indicatorF)
 
- Public Member Functions inherited from olb::SuperIdentity3D< T, W >
 SuperIdentity3D (FunctorPtr< SuperF3D< T, W > > &&f)
 
bool operator() (W output[], const int input[]) override
 
- Public Member Functions inherited from olb::SuperF3D< T, W >
SuperF3D< T, W > & operator- (SuperF3D< T, W > &rhs)
 
SuperF3D< T, W > & operator+ (SuperF3D< T, W > &rhs)
 
SuperF3D< T, W > & operator* (SuperF3D< T, W > &rhs)
 
SuperF3D< T, W > & operator/ (SuperF3D< T, W > &rhs)
 
SuperStructure< T, 3 > & getSuperStructure ()
 
int getBlockFSize () const
 
BlockF3D< W > & getBlockF (int iCloc)
 
- Public Member Functions inherited from olb::GenericF< W, int >
virtual ~GenericF ()=default
 
int getSourceDim () const
 read only access to member variable _m
 
int getTargetDim () const
 read only access to member variable _n
 
std::string & getName ()
 read and write access to name
 
std::string const & getName () const
 read only access to name
 
bool operator() (W output[])
 wrapper that call the pure virtual operator() (T output[], const S input[]) from above
 
bool operator() (W output[], int input0)
 
bool operator() (W output[], int input0, int input1)
 
bool operator() (W output[], int input0, int input1, int input2)
 
bool operator() (W output[], int input0, int input1, int input2, int input3)
 

Additional Inherited Members

- Public Types inherited from olb::SuperF3D< T, W >
using identity_functor_type
 
- Public Types inherited from olb::GenericF< W, int >
using targetType
 
using sourceType
 
- Public Attributes inherited from olb::GenericF< W, int >
std::shared_ptr< GenericF< W, int > > _ptrCalcC
 memory management, frees resouces (calcClass)
 
- Static Public Attributes inherited from olb::SuperF3D< T, W >
static constexpr bool isSuper
 
static constexpr unsigned d
 
- Protected Member Functions inherited from olb::SuperF3D< T, W >
 SuperF3D (SuperStructure< T, 3 > &superStructure, int targetDim)
 
- Protected Member Functions inherited from olb::GenericF< W, int >
 GenericF (int targetDim, int sourceDim)
 
- Protected Attributes inherited from olb::SuperIdentity3D< T, W >
FunctorPtr< SuperF3D< T, W > > _f
 
- Protected Attributes inherited from olb::SuperF3D< T, W >
SuperStructure< T, 3 > & _superStructure
 
std::vector< std::unique_ptr< BlockF3D< W > > > _blockF
 Super functors may consist of several BlockF3D<W> derived functors.
 

Detailed Description

template<typename T, typename W, int P>
class olb::SuperRelativeErrorLpNorm3D< T, W, P >

Relative error norm functor.

Calculates "LpNorm(wantedF - f) / LpNorm(wantedF)"

Definition at line 37 of file superErrorNorm3D.h.

Constructor & Destructor Documentation

◆ SuperRelativeErrorLpNorm3D() [1/2]

template<typename T , typename W , int P>
template<typename DESCRIPTOR >
olb::SuperRelativeErrorLpNorm3D< T, W, P >::SuperRelativeErrorLpNorm3D ( SuperLattice< T, DESCRIPTOR > & sLattice,
FunctorPtr< SuperF3D< T, W > > && f,
FunctorPtr< AnalyticalF3D< T, W > > && wantedF,
FunctorPtr< SuperIndicatorF3D< T > > && indicatorF )

Definition at line 35 of file superErrorNorm3D.hh.

40 : SuperIdentity3D<T,W>([&]()
41{
42 using namespace functor_dsl;
43
44 auto wantedLatticeF = restrictF(wantedF.toShared(), sLattice);
45
46 return norm<P>(wantedLatticeF - f.toShared(), indicatorF.toShared())
47 / norm<P>(wantedLatticeF, indicatorF.toShared());
48}())
49{
50 this->getName() = "relErrorNormL" + std::to_string(P);
51}
std::string & getName()
read and write access to name
Definition genericF.hh:51
std::shared_ptr< SuperF2D< T, W > > restrictF(std::shared_ptr< AnalyticalF2D< T, W > > f, SuperLattice< T, DESCRIPTOR > &sLattice)
Returns restriction of a analytical functor f to the lattice sLattice.

◆ SuperRelativeErrorLpNorm3D() [2/2]

template<typename T , typename W , int P>
template<typename DESCRIPTOR >
olb::SuperRelativeErrorLpNorm3D< T, W, P >::SuperRelativeErrorLpNorm3D ( SuperLatticeF3D< T, DESCRIPTOR > & f,
FunctorPtr< AnalyticalF3D< T, W > > && wantedF,
FunctorPtr< SuperIndicatorF3D< T > > && indicatorF )

Definition at line 55 of file superErrorNorm3D.hh.

59 : SuperRelativeErrorLpNorm3D(f.getSuperLattice(),
60 f,
61 std::forward<decltype(wantedF)>(wantedF),
62 std::forward<decltype(indicatorF)>(indicatorF))
63{ }
SuperRelativeErrorLpNorm3D(SuperLattice< T, DESCRIPTOR > &sLattice, FunctorPtr< SuperF3D< T, W > > &&f, FunctorPtr< AnalyticalF3D< T, W > > &&wantedF, FunctorPtr< SuperIndicatorF3D< T > > &&indicatorF)

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