Peano
Loading...
Searching...
No Matches
exahype2::blockstructured::tests::SommerfeldBoundaryConditionsTest Class Reference

Test exahype2::blockstructured::applySommerfeldBoundaryConditions() More...

#include <SommerfeldBoundaryConditionsTest.h>

Inheritance diagram for exahype2::blockstructured::tests::SommerfeldBoundaryConditionsTest:
Collaboration diagram for exahype2::blockstructured::tests::SommerfeldBoundaryConditionsTest:

Public Member Functions

 SommerfeldBoundaryConditionsTest ()
 
void run () override
 This routine is triggered by the TestCaseCollection.
 
- Public Member Functions inherited from tarch::tests::TestCase
 TestCase (const std::string &testCaseName)
 Constructor.
 
virtual ~TestCase ()
 Destructor.
 
int getNumberOfErrors () const
 
std::string getTestCaseName () const
 

Private Member Functions

void testFarFieldIsPreserved ()
 If the old and the new solution equal a constant far-field solution, the ghost cells have to equal it, too, on every boundary face.
 
void testBoxSchemeOnAxis ()
 One ghost cell on the upper boundary along the axis through the origin, where the radial and the normal direction coincide.
 
void testLowerAndUpperFacesAreSymmetric ()
 The lower and the upper boundary face of a domain around the origin are mirror images of each other.
 
void testZeroTimeStepSizeCopiesGhostCells ()
 A time step size of zero copies the old ghost cells.
 
void testInteriorAndPeriodicFacesAreSkipped ()
 Faces within the domain and boundary faces along periodic axes are left unchanged.
 

Additional Inherited Members

- Protected Member Functions inherited from tarch::tests::TestCase
 TestCase ()=delete
 
- Protected Attributes inherited from tarch::tests::TestCase
const std::string _testCaseName
 Name of the test case.
 
int _errors
 Error counter.
 
bool _error
 Indicate within macro if one specific validation failed.
 

Detailed Description

Test exahype2::blockstructured::applySommerfeldBoundaryConditions()

All tests work over the domain \( [-1,1]^d \) around the origin with patches of three grid cells per axis and two unknowns plus one auxiliary variable per grid cell. Unless stated otherwise, the overlap is three, i.e. the one of fourth-order Finite Differences. Entries the routine is not supposed to touch are initialised with a marker value and have to keep it.

Definition at line 28 of file SommerfeldBoundaryConditionsTest.h.

Constructor & Destructor Documentation

◆ SommerfeldBoundaryConditionsTest()

exahype2::blockstructured::tests::SommerfeldBoundaryConditionsTest::SommerfeldBoundaryConditionsTest ( )

Member Function Documentation

◆ run()

void exahype2::blockstructured::tests::SommerfeldBoundaryConditionsTest::run ( )
overridevirtual

This routine is triggered by the TestCaseCollection.

Implements tarch::tests::TestCase.

◆ testBoxSchemeOnAxis()

void exahype2::blockstructured::tests::SommerfeldBoundaryConditionsTest::testBoxSchemeOnAxis ( )
private

One ghost cell on the upper boundary along the axis through the origin, where the radial and the normal direction coincide.

The new ghost value has to satisfy the discrete box scheme documented in applySommerfeldBoundaryConditions(), i.e. its residual has to vanish. The other unknowns of the face are not on the axis and are not checked.

◆ testFarFieldIsPreserved()

void exahype2::blockstructured::tests::SommerfeldBoundaryConditionsTest::testFarFieldIsPreserved ( )
private

If the old and the new solution equal a constant far-field solution, the ghost cells have to equal it, too, on every boundary face.

The auxiliary variable is copied from the new interior solution.

◆ testInteriorAndPeriodicFacesAreSkipped()

void exahype2::blockstructured::tests::SommerfeldBoundaryConditionsTest::testInteriorAndPeriodicFacesAreSkipped ( )
private

Faces within the domain and boundary faces along periodic axes are left unchanged.

◆ testLowerAndUpperFacesAreSymmetric()

void exahype2::blockstructured::tests::SommerfeldBoundaryConditionsTest::testLowerAndUpperFacesAreSymmetric ( )
private

The lower and the upper boundary face of a domain around the origin are mirror images of each other.

With mirrored data, they have to yield the same ghost values. This test fails for a scheme that uses the signed coordinate along the normal, as the removed legacy exahype2::fd::applySommerfeldConditions() did.

◆ testZeroTimeStepSizeCopiesGhostCells()

void exahype2::blockstructured::tests::SommerfeldBoundaryConditionsTest::testZeroTimeStepSizeCopiesGhostCells ( )
private

A time step size of zero copies the old ghost cells.


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