AXOM
Axom provides a robust, flexible software infrastructure for the development of multi-physics applications and computational tools.
axom::bump::views::StructuredTopologyView< IndexPolicy > Class Template Reference

This class provides a view for Conduit/Blueprint structured grid types. More...

#include </home/docs/checkouts/readthedocs.org/user_builds/axom/checkouts/develop/src/axom/bump/views/StructuredTopologyView.hpp>

Public Types

using IndexingPolicy = IndexPolicy
 
using IndexType = typename IndexingPolicy::IndexType
 
using LogicalIndex = typename IndexingPolicy::LogicalIndex
 
using ConnectivityType = IndexType
 
using Shape1D = LineShape< axom::StackArray< ConnectivityType, 2 > >
 
using Shape2D = QuadShape< axom::StackArray< ConnectivityType, 4 > >
 
using Shape3D = HexShape< axom::StackArray< ConnectivityType, 8 > >
 
using ShapeType = typename std::conditional< IndexingPolicy::dimension()==3, Shape3D, typename std::conditional< IndexingPolicy::dimension()==2, Shape2D, Shape1D >::type >::type
 

Public Member Functions

AXOM_HOST_DEVICE StructuredTopologyView ()
 Constructor. More...
 
AXOM_HOST_DEVICE StructuredTopologyView (const IndexingPolicy &indexing)
 Constructor. More...
 
AXOM_HOST_DEVICE IndexType size () const
 Return the number of zones. More...
 
AXOM_HOST_DEVICE IndexType numberOfZones () const
 Return the number of zones. More...
 
AXOM_HOST_DEVICE IndexType connectivitySize () const
 Return the size of the connectivity. More...
 
AXOM_HOST_DEVICE const LogicalIndexlogicalDimensions () const
 Return the mesh logical dimensions. More...
 
AXOM_HOST_DEVICE IndexingPolicyindexing ()
 Return indexing object. More...
 
AXOM_HOST_DEVICE const IndexingPolicyindexing () const
 Return indexing object. More...
 
template<int _ndims = IndexingPolicy::dimension()>
AXOM_HOST_DEVICE std::enable_if< _ndims==3, Shape3D >::type zone (axom::IndexType zoneIndex) const
 Return a zone. More...
 
template<int _ndims = IndexingPolicy::dimension()>
AXOM_HOST_DEVICE std::enable_if< _ndims==2, Shape2D >::type zone (axom::IndexType zoneIndex) const
 Return a zone. More...
 
template<int _ndims = IndexingPolicy::dimension()>
AXOM_HOST_DEVICE std::enable_if< _ndims==1, Shape1D >::type zone (axom::IndexType zoneIndex) const
 Return a zone. More...
 

Static Public Member Functions

constexpr static AXOM_HOST_DEVICE int dimension ()
 Return the number of dimensions. More...
 

Detailed Description

template<typename IndexPolicy>
class axom::bump::views::StructuredTopologyView< IndexPolicy >

This class provides a view for Conduit/Blueprint structured grid types.

Template Parameters
IndexPolicyThe policy for making/using indices.

Member Typedef Documentation

◆ IndexingPolicy

template<typename IndexPolicy >
using axom::bump::views::StructuredTopologyView< IndexPolicy >::IndexingPolicy = IndexPolicy

◆ IndexType

template<typename IndexPolicy >
using axom::bump::views::StructuredTopologyView< IndexPolicy >::IndexType = typename IndexingPolicy::IndexType

◆ LogicalIndex

template<typename IndexPolicy >
using axom::bump::views::StructuredTopologyView< IndexPolicy >::LogicalIndex = typename IndexingPolicy::LogicalIndex

◆ ConnectivityType

template<typename IndexPolicy >
using axom::bump::views::StructuredTopologyView< IndexPolicy >::ConnectivityType = IndexType

◆ Shape1D

template<typename IndexPolicy >
using axom::bump::views::StructuredTopologyView< IndexPolicy >::Shape1D = LineShape<axom::StackArray<ConnectivityType, 2> >

◆ Shape2D

template<typename IndexPolicy >
using axom::bump::views::StructuredTopologyView< IndexPolicy >::Shape2D = QuadShape<axom::StackArray<ConnectivityType, 4> >

◆ Shape3D

template<typename IndexPolicy >
using axom::bump::views::StructuredTopologyView< IndexPolicy >::Shape3D = HexShape<axom::StackArray<ConnectivityType, 8> >

◆ ShapeType

template<typename IndexPolicy >
using axom::bump::views::StructuredTopologyView< IndexPolicy >::ShapeType = typename std::conditional< IndexingPolicy::dimension() == 3, Shape3D, typename std::conditional<IndexingPolicy::dimension() == 2, Shape2D, Shape1D>::type>::type

Constructor & Destructor Documentation

◆ StructuredTopologyView() [1/2]

template<typename IndexPolicy >
AXOM_HOST_DEVICE axom::bump::views::StructuredTopologyView< IndexPolicy >::StructuredTopologyView ( )
inline

Constructor.

◆ StructuredTopologyView() [2/2]

template<typename IndexPolicy >
AXOM_HOST_DEVICE axom::bump::views::StructuredTopologyView< IndexPolicy >::StructuredTopologyView ( const IndexingPolicy indexing)
inline

Constructor.

Parameters
indexingThe indexing policy for the topology (num zones in each dimension).

Member Function Documentation

◆ dimension()

template<typename IndexPolicy >
constexpr static AXOM_HOST_DEVICE int axom::bump::views::StructuredTopologyView< IndexPolicy >::dimension ( )
inlinestaticconstexpr

Return the number of dimensions.

Returns
The number of dimensions.

◆ size()

template<typename IndexPolicy >
AXOM_HOST_DEVICE IndexType axom::bump::views::StructuredTopologyView< IndexPolicy >::size ( ) const
inline

Return the number of zones.

Returns
The number of zones.

◆ numberOfZones()

template<typename IndexPolicy >
AXOM_HOST_DEVICE IndexType axom::bump::views::StructuredTopologyView< IndexPolicy >::numberOfZones ( ) const
inline

Return the number of zones.

Returns
The number of zones.

References axom::bump::views::StructuredTopologyView< IndexPolicy >::size().

◆ connectivitySize()

template<typename IndexPolicy >
AXOM_HOST_DEVICE IndexType axom::bump::views::StructuredTopologyView< IndexPolicy >::connectivitySize ( ) const
inline

◆ logicalDimensions()

template<typename IndexPolicy >
AXOM_HOST_DEVICE const LogicalIndex& axom::bump::views::StructuredTopologyView< IndexPolicy >::logicalDimensions ( ) const
inline

Return the mesh logical dimensions.

Returns
The mesh logical dimensions.

◆ indexing() [1/2]

template<typename IndexPolicy >
AXOM_HOST_DEVICE IndexingPolicy& axom::bump::views::StructuredTopologyView< IndexPolicy >::indexing ( )
inline

Return indexing object.

Returns
The indexing object.

◆ indexing() [2/2]

template<typename IndexPolicy >
AXOM_HOST_DEVICE const IndexingPolicy& axom::bump::views::StructuredTopologyView< IndexPolicy >::indexing ( ) const
inline

Return indexing object.

Returns
The indexing object.

◆ zone() [1/3]

template<typename IndexPolicy >
template<int _ndims = IndexingPolicy::dimension()>
AXOM_HOST_DEVICE std::enable_if<_ndims == 3, Shape3D>::type axom::bump::views::StructuredTopologyView< IndexPolicy >::zone ( axom::IndexType  zoneIndex) const
inline

Return a zone.

Parameters
zoneIndexThe index of the zone to return.
Returns
The requested zone.
Note
3D implementation.

References axom::bump::views::Shape< ShapeTraits, ConnStorage >::getIdsStorage(), axom::bump::views::StructuredTopologyView< IndexPolicy >::numberOfZones(), and SLIC_ASSERT.

◆ zone() [2/3]

template<typename IndexPolicy >
template<int _ndims = IndexingPolicy::dimension()>
AXOM_HOST_DEVICE std::enable_if<_ndims == 2, Shape2D>::type axom::bump::views::StructuredTopologyView< IndexPolicy >::zone ( axom::IndexType  zoneIndex) const
inline

Return a zone.

Parameters
zoneIndexThe index of the zone to return.
Returns
The requested zone.
Note
2D implementation.

References axom::bump::views::Shape< ShapeTraits, ConnStorage >::getIdsStorage(), axom::bump::views::StructuredTopologyView< IndexPolicy >::numberOfZones(), and SLIC_ASSERT.

◆ zone() [3/3]

template<typename IndexPolicy >
template<int _ndims = IndexingPolicy::dimension()>
AXOM_HOST_DEVICE std::enable_if<_ndims == 1, Shape1D>::type axom::bump::views::StructuredTopologyView< IndexPolicy >::zone ( axom::IndexType  zoneIndex) const
inline

Return a zone.

Parameters
indexThe index of the zone to return.
Returns
The requested zone.
Note
1D implementation.

References axom::bump::views::Shape< ShapeTraits, ConnStorage >::getIdsStorage(), axom::bump::views::StructuredTopologyView< IndexPolicy >::numberOfZones(), and SLIC_ASSERT.


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