NeoN
A framework for CFD software
Loading...
Searching...
No Matches
Public Types | Public Member Functions | Friends | List of all members
NeoN::BoundaryData< ValueType > Class Template Reference

Represents the boundary fields for a computational domain. More...

#include <boundaryData.hpp>

Public Types

using BoundaryDataType = ValueType
 

Public Member Functions

 ~BoundaryData ()
 
 BoundaryData (const BoundaryData< ValueType > &rhs)
 Copy constructor.
 
 BoundaryData (const Executor &exec, const BoundaryData< ValueType > &rhs)
 Copy constructor.
 
 BoundaryData (const Executor &exec, localIdx nBoundaryFaces, localIdx nBoundaryTypes)
 constructor with default initialized Vectors from sizes.
 
 BoundaryData (const Executor &exec, const std::vector< localIdx > &offsets)
 constructor from a given offsets vector @warn all members except offsets are default constructed
 
const Vector< ValueType > & value () const
 Get the view storing the computed values from the boundary condition.
 
Vector< ValueType > & value ()
 Get the view storing the computed values from the boundary condition.
 
const Vector< ValueType > & refValue () const
 Get the view storing the Dirichlet boundary values.
 
Vector< ValueType > & refValue ()
 Get the view storing the Dirichlet boundary values.
 
const Vector< scalar > & valueFraction () const
 Get the view storing the fraction of the boundary value.
 
Vector< scalar > & valueFraction ()
 Get the view storing the fraction of the boundary value.
 
const Vector< ValueType > & refGrad () const
 Get the view storing the Neumann boundary values.
 
Vector< ValueType > & refGrad ()
 Get the view storing the Neumann boundary values.
 
const Vector< int > & boundaryTypes () const
 Get the view storing the boundary types.
 
const Vector< localIdx > & offset () const
 Get the view storing the offsets of each boundary.
 
localIdx nBoundaries () const
 Get the number of boundaries.
 
localIdx nBoundaryFaces () const
 Get the number of boundary faces.
 
localIdx nBoundaryFaces (localIdx patchId) const
 Get the number of boundary faces for this patch.
 
const Executorexec ()
 
BoundaryData< ValueType > & operator= (const BoundaryData< ValueType > &rhs)
 
BoundaryData< ValueType > & operator= (const BoundaryData< ValueType > &&rhs)
 
void waitAll () const
 
std::pair< localIdx, localIdxrange (localIdx patchId) const
 Get the range for a given patchId.
 

Friends

struct NoWaitAccess
 Grants NoWaitAccess (and only it) access to valueNoWait().
 

Detailed Description

template<typename ValueType>
class NeoN::BoundaryData< ValueType >

Represents the boundary fields for a computational domain.

The BoundaryData class stores the boundary conditions and related information for a computational domain. It provides access to the computed values, reference values, value fractions, reference gradients, boundary types, offsets, and the number of boundaries and boundary faces.

Template Parameters
ValueTypeThe type of the underlying field values

Definition at line 41 of file boundaryData.hpp.

Member Typedef Documentation

◆ BoundaryDataType

template<typename ValueType >
using NeoN::BoundaryData< ValueType >::BoundaryDataType = ValueType

Definition at line 46 of file boundaryData.hpp.

Constructor & Destructor Documentation

◆ ~BoundaryData()

template<typename ValueType >
NeoN::BoundaryData< ValueType >::~BoundaryData ( )
inline

Definition at line 48 of file boundaryData.hpp.

◆ BoundaryData() [1/4]

template<typename ValueType >
NeoN::BoundaryData< ValueType >::BoundaryData ( const BoundaryData< ValueType > &  rhs)
inline

Copy constructor.

Parameters
rhsThe boundaryVectors object to be copied.

Definition at line 60 of file boundaryData.hpp.

◆ BoundaryData() [2/4]

template<typename ValueType >
NeoN::BoundaryData< ValueType >::BoundaryData ( const Executor exec,
const BoundaryData< ValueType > &  rhs 
)
inline

Copy constructor.

Parameters
rhsThe boundaryVectors object to be copied.

Definition at line 72 of file boundaryData.hpp.

◆ BoundaryData() [3/4]

template<typename ValueType >
NeoN::BoundaryData< ValueType >::BoundaryData ( const Executor exec,
localIdx  nBoundaryFaces,
localIdx  nBoundaryTypes 
)
inline

constructor with default initialized Vectors from sizes.

Parameters
exec- The executor
nBoundaryFaces- The total number of boundary faces
nBoundaryType- The total number of boundary patches

Definition at line 86 of file boundaryData.hpp.

◆ BoundaryData() [4/4]

template<typename ValueType >
NeoN::BoundaryData< ValueType >::BoundaryData ( const Executor exec,
const std::vector< localIdx > &  offsets 
)
inline

constructor from a given offsets vector @warn all members except offsets are default constructed

Parameters
exec- The executor
offsets- The total number of boundary faces

Definition at line 101 of file boundaryData.hpp.

Member Function Documentation

◆ boundaryTypes()

template<typename ValueType >
const Vector< int > & NeoN::BoundaryData< ValueType >::boundaryTypes ( ) const
inline

Get the view storing the boundary types.

Returns
The view storing the boundary types.

Definition at line 158 of file boundaryData.hpp.

◆ exec()

template<typename ValueType >
const Executor & NeoN::BoundaryData< ValueType >::exec ( )
inline

Definition at line 187 of file boundaryData.hpp.

◆ nBoundaries()

template<typename ValueType >
localIdx NeoN::BoundaryData< ValueType >::nBoundaries ( ) const
inline

Get the number of boundaries.

Returns
The number of boundaries.

Definition at line 170 of file boundaryData.hpp.

◆ nBoundaryFaces() [1/2]

template<typename ValueType >
localIdx NeoN::BoundaryData< ValueType >::nBoundaryFaces ( ) const
inline

Get the number of boundary faces.

Returns
The number of boundary faces.

Definition at line 176 of file boundaryData.hpp.

◆ nBoundaryFaces() [2/2]

template<typename ValueType >
localIdx NeoN::BoundaryData< ValueType >::nBoundaryFaces ( localIdx  patchId) const
inline

Get the number of boundary faces for this patch.

Returns
The number of boundary faces for this patch.

Definition at line 182 of file boundaryData.hpp.

◆ offset()

template<typename ValueType >
const Vector< localIdx > & NeoN::BoundaryData< ValueType >::offset ( ) const
inline

Get the view storing the offsets of each boundary.

Returns
The view storing the offsets of each boundary.

Definition at line 164 of file boundaryData.hpp.

◆ operator=() [1/2]

template<typename ValueType >
BoundaryData< ValueType > & NeoN::BoundaryData< ValueType >::operator= ( const BoundaryData< ValueType > &&  rhs)
inline

Definition at line 206 of file boundaryData.hpp.

◆ operator=() [2/2]

template<typename ValueType >
BoundaryData< ValueType > & NeoN::BoundaryData< ValueType >::operator= ( const BoundaryData< ValueType > &  rhs)
inline

Definition at line 189 of file boundaryData.hpp.

◆ range()

template<typename ValueType >
std::pair< localIdx, localIdx > NeoN::BoundaryData< ValueType >::range ( localIdx  patchId) const
inline

Get the range for a given patchId.

Returns
The number of boundary faces.

Definition at line 376 of file boundaryData.hpp.

◆ refGrad() [1/2]

template<typename ValueType >
Vector< ValueType > & NeoN::BoundaryData< ValueType >::refGrad ( )
inline

Get the view storing the Neumann boundary values.

Returns
The view storing the Neumann boundary values.

Definition at line 152 of file boundaryData.hpp.

◆ refGrad() [2/2]

template<typename ValueType >
const Vector< ValueType > & NeoN::BoundaryData< ValueType >::refGrad ( ) const
inline

Get the view storing the Neumann boundary values.

Returns
The view storing the Neumann boundary values.

Definition at line 146 of file boundaryData.hpp.

◆ refValue() [1/2]

template<typename ValueType >
Vector< ValueType > & NeoN::BoundaryData< ValueType >::refValue ( )
inline

Get the view storing the Dirichlet boundary values.

Returns
The view storing the Dirichlet boundary values.

Definition at line 134 of file boundaryData.hpp.

◆ refValue() [2/2]

template<typename ValueType >
const Vector< ValueType > & NeoN::BoundaryData< ValueType >::refValue ( ) const
inline

Get the view storing the Dirichlet boundary values.

Returns
The view storing the Dirichlet boundary values.

Definition at line 128 of file boundaryData.hpp.

◆ value() [1/2]

template<typename ValueType >
Vector< ValueType > & NeoN::BoundaryData< ValueType >::value ( )
inline

Get the view storing the computed values from the boundary condition.

Note
calls waitAll to ensure all boundary data is updated.
Returns
The view storing the computed values.

Definition at line 121 of file boundaryData.hpp.

◆ value() [2/2]

template<typename ValueType >
const Vector< ValueType > & NeoN::BoundaryData< ValueType >::value ( ) const
inline

Get the view storing the computed values from the boundary condition.

Note
calls waitAll to ensure all boundary data is updated.
Returns
The view storing the computed values.

Definition at line 109 of file boundaryData.hpp.

◆ valueFraction() [1/2]

template<typename ValueType >
Vector< scalar > & NeoN::BoundaryData< ValueType >::valueFraction ( )
inline

Get the view storing the fraction of the boundary value.

Returns
The view storing the fraction of the boundary value.

Definition at line 143 of file boundaryData.hpp.

◆ valueFraction() [2/2]

template<typename ValueType >
const Vector< scalar > & NeoN::BoundaryData< ValueType >::valueFraction ( ) const
inline

Get the view storing the fraction of the boundary value.

Returns
The view storing the fraction of the boundary value.

Definition at line 137 of file boundaryData.hpp.

◆ waitAll()

template<typename ValueType >
void NeoN::BoundaryData< ValueType >::waitAll ( ) const
inline

Definition at line 314 of file boundaryData.hpp.

Friends And Related Symbol Documentation

◆ NoWaitAccess

template<typename ValueType >
friend struct NoWaitAccess
friend

Grants NoWaitAccess (and only it) access to valueNoWait().

Definition at line 384 of file boundaryData.hpp.


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