Logbook  (07-04-2025)
Static problems
StaticScalarSolver::Weight< dim, stage > Class Template Reference

Implements the weight function for calculating the \(L^2\), \(L^{\infty}\), and \(H^1\) error norms. More...

#include <static_scalar_input.hpp>

Inheritance diagram for StaticScalarSolver::Weight< dim, stage >:
Collaboration diagram for StaticScalarSolver::Weight< dim, stage >:

Public Member Functions

virtual double value (const Point< dim > &r, const unsigned int component=0) const override final
 Returns the value of weight at point r. All error norms, \(L^2\), \(L^{\infty}\), and \(H^1\), at point r will be multiplied by this value. More...
 
double value (const Point< 2 > &r, const unsigned int component) const
 
double value (const Point< 2 > &r, const unsigned int component) const
 
double value (const Point< 2 > &r, const unsigned int component) const
 

Detailed Description

template<int dim, int stage = 1>
class StaticScalarSolver::Weight< dim, stage >

Implements the weight function for calculating the \(L^2\), \(L^{\infty}\), and \(H^1\) error norms.

Objects of this class template are passed to VectorTools::integrate_difference.

This class template is used for selecting regions of the problem domain in which the error norms are calculated.

This class template is declared in shared/include/static_scalar_input.hpp but must be implemented in xyz/src/static_scalar_input.cpp, where xyz is the directory of the current numerical experiment. That is, the declaration is shared between all numerical experiments while implementation is specific for each individual numerical experiment. See the structure of the code for more details.

The dim template parameter is, as per usual, the amount of spatial dimensions. The purpose of the stage template parameter is discussed in here.

The user is supposed to implement

double value(...)
virtual double value(const Point< dim > &r, const unsigned int component=0) const override final
Returns the value of weight at point r. All error norms, , , and , at point r will be multiplied by t...

member function of this class template.

Definition at line 607 of file static_scalar_input.hpp.

Member Function Documentation

◆ value()

template<int dim, int stage = 1>
virtual double StaticScalarSolver::Weight< dim, stage >::value ( const Point< dim > &  r,
const unsigned int  component = 0 
) const
finaloverridevirtual

Returns the value of weight at point r. All error norms, \(L^2\), \(L^{\infty}\), and \(H^1\), at point r will be multiplied by this value.

Parameters
[in]r- The quadrature point at which the error norm is currently evaluated.
[in]component- The component of the function. Must equal zero in the case of a scalar function.

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