Peano
Loading...
Searching...
No Matches
exahype2::enumerator::SoALexicographicEnumerator Struct Reference

SoA Lexicographic Enumerator. More...

#include <SoALexicographicEnumerator.h>

Public Member Functions

constexpr GPUCallableInlineMethod SoALexicographicEnumerator (int numberOfCells, int numberOfDoFsPerAxisInCell, int haloSize, int unknowns, int numberOfAuxiliaryVariables)
 
GPUCallableInlineMethod int operator() (int cellIndex, const tarch::la::Vector< Dimensions, int > &volumeIndex, int unknown) const InlineMethod
 Access an index.
 
GPUCallableInlineMethod int size () const InlineMethod
 Returns the total size.
 

Data Fields

const int _numberOfCells
 
const int _numberOfDoFsPerAxisInCell
 
const int _haloSize
 
const int _unknowns
 
const int _numberOfAuxiliaryVariables
 

Detailed Description

SoA Lexicographic Enumerator.

Enumerates the degrees of freedom assuming that they are

  • organised as structure of arrays, i.e., if you store quantities (a,b,c) per degree of freedom, then the array first holds the a values, then all the b values, then all the c values.
  • organised lexicographically, i.e., we first enumerate all the degrees of freedom along the x-axis, then along the y-axis, then along the z-axis.
  • organised from left to right, bottom-up and front to back.
  • organised one cell after another, i.e., we first enumerate all the a values of the first cell, followed by all the a unknowns of the second cell, and so forth. After the a values of the last cell, we continue with the b values in the examples with (a,b,c) per degree of freedom.

This native SoA enumerator uses SoA within the cells plus over cells: It first enumerates all Q[0] data from cell one, then all Q[0] from cell two, then all Q[0] from cell three, and so forth. After that, it continues with Q[1]. This means: The enumerator interleaves the individual cells.

See also
enumerator.h for a generic description of attribute semantics.

Definition at line 39 of file SoALexicographicEnumerator.h.

Constructor & Destructor Documentation

◆ SoALexicographicEnumerator()

constexpr GPUCallableInlineMethod exahype2::enumerator::SoALexicographicEnumerator::SoALexicographicEnumerator ( int numberOfCells,
int numberOfDoFsPerAxisInCell,
int haloSize,
int unknowns,
int numberOfAuxiliaryVariables )
constexpr

Definition at line 40 of file SoALexicographicEnumerator.h.

Member Function Documentation

◆ operator()()

GPUCallableInlineMethod int exahype2::enumerator::SoALexicographicEnumerator::operator() ( int cellIndex,
const tarch::la::Vector< Dimensions, int > & volumeIndex,
int unknown ) const

Access an index.

The index always refers to the interior of the cells. So you can use negative indices if you want.

Definition at line 53 of file SoALexicographicEnumerator.h.

References _haloSize, _numberOfCells, _numberOfDoFsPerAxisInCell, and exahype2::volumeIndex().

Here is the call graph for this function:

◆ size()

GPUCallableInlineMethod int exahype2::enumerator::SoALexicographicEnumerator::size ( ) const

Field Documentation

◆ _haloSize

const int exahype2::enumerator::SoALexicographicEnumerator::_haloSize

Definition at line 85 of file SoALexicographicEnumerator.h.

Referenced by operator()(), and size().

◆ _numberOfAuxiliaryVariables

const int exahype2::enumerator::SoALexicographicEnumerator::_numberOfAuxiliaryVariables

Definition at line 87 of file SoALexicographicEnumerator.h.

Referenced by size().

◆ _numberOfCells

const int exahype2::enumerator::SoALexicographicEnumerator::_numberOfCells

Definition at line 83 of file SoALexicographicEnumerator.h.

Referenced by operator()(), and size().

◆ _numberOfDoFsPerAxisInCell

const int exahype2::enumerator::SoALexicographicEnumerator::_numberOfDoFsPerAxisInCell

Definition at line 84 of file SoALexicographicEnumerator.h.

Referenced by operator()(), and size().

◆ _unknowns


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