15 #ifndef GEOSX_MESH_AGGREGATEELEMENTSUBREGION_HPP_ 16 #define GEOSX_MESH_AGGREGATEELEMENTSUBREGION_HPP_ 49 {
return "AggregateCell"; }
67 template<
typename LAMBDA >
70 for(
localIndex fineCell = m_nbFineCellsPerCoarseCell[aggregateIndex];
71 fineCell < m_nbFineCellsPerCoarseCell[aggregateIndex+1]; fineCell++ )
73 lambda( m_fineToCoarse[fineCell] );
85 return m_nbFineCellsPerCoarseCell[aggregateIndex + 1] - m_nbFineCellsPerCoarseCell[aggregateIndex];
122 return m_fineToCoarse;
151 static constexpr
auto elementVolumeString =
"elementVolume";
152 static constexpr
auto fineElementsListString =
"fineElements";
localIndex GetNbCellsPerAggregate(localIndex aggregateIndex) const
Gives the number of fine cells of an aggregate coarse cell.
InterObjectRelation< array2d< localIndex > > FixedOneToManyRelation
A relationship from single objects to many other objects, where each object is related to the same nu...
Class facilitating the representation of a multi-level discretization of a MeshBody.
The NodeManager class provides an interface to ObjectManagerBase in order to manage node data...
AggregateElementSubRegion(string const &name, dataRepository::Group *const parent)
Constructor for this class.
virtual ~AggregateElementSubRegion() override
Destructor.
virtual void CalculateElementGeometricQuantities(NodeManager const &nodeManager, FaceManager const &faceManager) override
Calculate the geometric quantities for each element in the subregion.
This class serves to provide a "view" of a multidimensional array.
virtual const string getCatalogName() const override
Provide a virtual access to CatalogName().
The AggregateElementSubRegion class provides an interface to aggregate fine cells into coarse cells...
void CreateFromFineToCoarseMap(localIndex nbAggregates, arrayView1d< localIndex const > const &fineToCoarse, arrayView2d< real64 const > const &barycenters)
Construct the relation map between fine and coarse cells and order by aggregates. ...
#define GEOSX_UNUSED_VAR(...)
Mark an unused variable and silence compiler warnings.
std::ptrdiff_t localIndex
Local index type (for indexing objects within an MPI partition).
void forFineCellsInAggregate(localIndex aggregateIndex, LAMBDA lambda)
Find all the fine cell in a given aggregate coarse cell.
virtual void setupRelatedObjectsInRelations(MeshLevel const *const mesh) override
Link the connectivity maps of the subregion to the managers storing the mesh information.
The FaceManager class provides an interface to ObjectManagerBase in order to manage face data...
Contains added view access key to be bound with class data member.
static const string CatalogName()
Return the name of the aggregate element sub-region in the object catalog.
This class provides a fixed dimensional resizeable array interface in addition to an interface simila...
struct to serve as a container for variable strings and keys
const array1d< localIndex > & GetFineToCoarseMap()
Accessor to the relation array between fine and coarse elements.