ug4

Classes

class  ug::Domain< d, TGrid, TSubsetHandler >
 
class  ug::DomainInfo
 Describes the contents of a domain. More...
 
class  ug::IDomain< TGrid, TSubsetHandler >
 describes a physical domain More...
 

Typedefs

typedef IDomain< TGrid, TSubsetHandler > ug::Domain< d, TGrid, TSubsetHandler >::base_type
 base type More...
 
typedef Domain< 1, MultiGrid, MGSubsetHandlerug::Domain1d
 
typedef Domain< 2, MultiGrid, MGSubsetHandlerug::Domain2d
 
typedef Domain< 3, MultiGrid, MGSubsetHandlerug::Domain3d
 
typedef TGrid ug::IDomain< TGrid, TSubsetHandler >::grid_type
 Grid type. More...
 
typedef base_type::grid_type ug::Domain< d, TGrid, TSubsetHandler >::grid_type
 Grid type. More...
 
typedef unsigned long long ug::DomainInfo::int_t
 
typedef Grid::VertexAttachmentAccessor< position_attachment_typeug::Domain< d, TGrid, TSubsetHandler >::position_accessor_type
 Type of Accessor to the Position Data Attachment. More...
 
typedef Attachment< position_typeug::Domain< d, TGrid, TSubsetHandler >::position_attachment_type
 Type of Position Attachment. More...
 
typedef MathVector< dimug::Domain< d, TGrid, TSubsetHandler >::position_type
 Type of position coordinates. More...
 
typedef TSubsetHandler ug::IDomain< TGrid, TSubsetHandler >::subset_handler_type
 Subset Handler type. More...
 
typedef base_type::subset_handler_type ug::Domain< d, TGrid, TSubsetHandler >::subset_handler_type
 Subset Handler type. More...
 

Functions

SmartPtr< TSubsetHandler > ug::IDomain< TGrid, TSubsetHandler >::additional_subset_handler (std::string name)
 returns an additional subset handler Subset Handler More...
 
const ConstSmartPtr< TSubsetHandler > ug::IDomain< TGrid, TSubsetHandler >::additional_subset_handler (std::string name) const
 const access to Subset Handler More...
 
std::vector< std::string > ug::IDomain< TGrid, TSubsetHandler >::additional_subset_handler_names () const
 returns a list with the names of additional subset handlers More...
 
SPRefinementProjector ug::IDomain< TGrid, TSubsetHandler >::broadcast_refinement_projector (int rootProc, pcl::ProcessCommunicator &procCom, SPIGeometry3d geometry, SPRefinementProjector projector=SPNULL)
 helper method to broadcast ug::RefinementProjectors to different processes More...
 
template<typename TDomain >
void ug::CollectCornerCoordinates (int base_object_id, std::vector< typename TDomain::position_type > &vCornerCoordsOut, GridObject &elem, const TDomain &domain, bool clearContainer)
 returns the corner coordinates of a geometric object More...
 
template<typename TElem , typename TAAPos >
void ug::CollectCornerCoordinates (std::vector< typename TAAPos::ValueType > &vCornerCoordsOut, const TElem &elem, const TAAPos &aaPos, bool clearContainer=true)
 returns the corner coordinates of a geometric object More...
 
template<typename TElem , typename TDomain >
void ug::CollectCornerCoordinates (std::vector< typename TDomain::position_type > &vCornerCoordsOut, const TElem &elem, const TDomain &domain, bool clearContainer=true)
 returns the corner coordinates of a geometric object More...
 
template<class TElem >
void ug::IDomain< TGrid, TSubsetHandler >::count_ghosts (std::vector< DomainInfo::int_t > &numGhostsOnLvlOut)
 
template<class TElem >
size_t ug::IDomain< TGrid, TSubsetHandler >::count_local_unique_surface_elements ()
 counts local surface elements which are not ghosts or h-slaves More...
 
bool ug::IDomain< TGrid, TSubsetHandler >::create_additional_subset_handler (std::string name)
 creates an additional subset-handler with the given name More...
 
SPRefinementProjector ug::IDomain< TGrid, TSubsetHandler >::deserialize_projector (BinaryBuffer &buf)
 
DistributedGridManagerug::IDomain< TGrid, TSubsetHandler >::distributed_grid_manager ()
 returns Distributed Grid Manager More...
 
 ug::Domain< d, TGrid, TSubsetHandler >::Domain (bool isAdaptive=true)
 Default constructor. More...
 
const DomainInfoug::IDomain< TGrid, TSubsetHandler >::domain_info () const
 returns information on the current domain More...
 
int ug::DomainInfo::element_type () const
 
template<typename TElem , typename TDomain >
number ug::ElementDiameter (const TElem &elem, TDomain &domain)
 returns the maximal distance between to element vertices More...
 
template<typename TElem , typename TDomain >
number ug::ElementDiameterSq (const TElem &elem, TDomain &domain)
 returns the maximal squared distance between to element vertices More...
 
template<typename TElem , typename TPosition >
number ug::ElementSize (const TElem &elem, const Grid::VertexAttachmentAccessor< Attachment< TPosition > > &aaPos)
 returns the size of a geometric object More...
 
template<typename TElem , typename TDomain >
number ug::ElementSize (const TElem &elem, const TDomain &domain)
 returns the size of a geometric object More...
 
bool ug::IDomain< TGrid, TSubsetHandler >::empty () const
 returns whether the associated grid is empty More...
 
virtual SPIGeometry3d ug::Domain< d, TGrid, TSubsetHandler >::geometry3d () const
 returns the geometry of the domain More...
 
virtual SPIGeometry3d ug::IDomain< TGrid, TSubsetHandler >::geometry3d () const =0
 returns the geometry of the domain More...
 
virtual int ug::Domain< d, TGrid, TSubsetHandler >::get_dim () const
 World Dimension. More...
 
virtual int ug::IDomain< TGrid, TSubsetHandler >::get_dim () const =0
 World Dimension. More...
 
SmartPtr< TGrid > ug::IDomain< TGrid, TSubsetHandler >::grid ()
 returns Grid More...
 
const ConstSmartPtr< TGrid > ug::IDomain< TGrid, TSubsetHandler >::grid () const
 const access to Grid More...
 
void ug::IDomain< TGrid, TSubsetHandler >::grid_adaption_callback (const GridMessage_Adaption &msg)
 
void ug::IDomain< TGrid, TSubsetHandler >::grid_creation_callback (const GridMessage_Creation &msg)
 Called when a domain has been loaded and during domain distribution. More...
 
void ug::IDomain< TGrid, TSubsetHandler >::grid_distribution_callback (const GridMessage_Distribution &msg)
 
 ug::IDomain< TGrid, TSubsetHandler >::IDomain (bool isAdaptive=true)
 Default constructor. More...
 
bool ug::IDomain< TGrid, TSubsetHandler >::is_adaptive () const
 returns whether the domain may be used for adaptive refinement More...
 
bool ug::IDomain< TGrid, TSubsetHandler >::is_parallel ()
 returns whether the domain can be used for parallel computations More...
 
size_t ug::DomainInfo::max_num_local_elements_on_level (size_t lvl) const
 returns the maximum number of elements a process has on a given leven (excluding ghosts) More...
 
template<typename TDomain >
number ug::MaxElementDiameter (TDomain &domain, int level)
 returns the maximal diameter of all elements between iterBegin and iterEnd. More...
 
SPMessageHub ug::IDomain< TGrid, TSubsetHandler >::message_hub ()
 returns the message hub of the grid More...
 
size_t ug::DomainInfo::min_num_local_elements_on_level (size_t lvl) const
 returns the minimum number of elements a process has on a given leven (excluding ghosts) More...
 
template<typename TDomain >
number ug::MinElementDiameter (TDomain &domain, int level)
 returns the minimal diameter of all elements between iterBegin and iterEnd. More...
 
size_t ug::DomainInfo::num_elements () const
 
size_t ug::DomainInfo::num_elements_on_level (size_t lvl) const
 returns the global number of elements on the given level (excluding ghosts...) More...
 
size_t ug::DomainInfo::num_levels () const
 
size_t ug::DomainInfo::num_local_elements_on_level (size_t lvl) const
 returns the local number of elements on the given level (excluding ghosts...) More...
 
size_t ug::DomainInfo::num_local_ghosts_on_level (size_t lvl) const
 returns the local number of ghosts on the given level More...
 
size_t ug::DomainInfo::num_subsets () const
 
size_t ug::DomainInfo::num_surface_elements () const
 returns the global number of surface elements (elements without children) More...
 
position_accessor_typeug::Domain< d, TGrid, TSubsetHandler >::position_accessor ()
 get Position Accessor More...
 
const position_accessor_typeug::Domain< d, TGrid, TSubsetHandler >::position_accessor () const
 const access to Position Accessor More...
 
position_attachment_typeug::Domain< d, TGrid, TSubsetHandler >::position_attachment ()
 returns Position Attachment More...
 
const position_attachment_typeug::Domain< d, TGrid, TSubsetHandler >::position_attachment () const
 const access to Position Attachment More...
 
SPRefinementProjector ug::IDomain< TGrid, TSubsetHandler >::refinement_projector () const
 returns the domain's ug::RefinementProjector. The pointer may be invalid. More...
 
template<typename TDomain >
void ug::SaveDomain (TDomain &domain, const char *filename)
 Saves the domain to a grid-file. More...
 
void ug::IDomain< TGrid, TSubsetHandler >::serialize_projector (BinaryBuffer &bufOut, SPRefinementProjector proj)
 
void ug::DomainInfo::set_info (GridBaseObjectId elemType, const std::vector< int_t > &numElems, const std::vector< int_t > &numLocalElems, const std::vector< int_t > &minNumLocalElems, const std::vector< int_t > &maxNumLocalElems, const std::vector< int_t > &numLocalGhosts, const std::vector< int_t > &subsetDims, int_t numSurfElems)
 
void ug::IDomain< TGrid, TSubsetHandler >::set_refinement_projector (SPRefinementProjector proj)
 sets the ug::RefinementProjector which can be used by refiners during refinement More...
 
size_t ug::DomainInfo::subset_dim (int si) const
 
SmartPtr< TSubsetHandler > ug::IDomain< TGrid, TSubsetHandler >::subset_handler ()
 returns Subset Handler More...
 
const ConstSmartPtr< TSubsetHandler > ug::IDomain< TGrid, TSubsetHandler >::subset_handler () const
 const access to Subset Handler More...
 
std::string ug::DomainInfo::to_string () const
 
void ug::IDomain< TGrid, TSubsetHandler >::update_domain_info ()
 updates the internal domain-info object. More...
 
void ug::IDomain< TGrid, TSubsetHandler >::update_subset_infos (int rootProc)
 updates and broadcasts subset names and dimensions from the given rootProc to all other processes. More...
 
virtual ug::Domain< d, TGrid, TSubsetHandler >::~Domain ()
 
virtual ug::IDomain< TGrid, TSubsetHandler >::~IDomain ()
 Destructor. More...
 

Variables

static const int ug::Domain< d, TGrid, TSubsetHandler >::dim = d
 World dimension. More...
 
position_accessor_type ug::Domain< d, TGrid, TSubsetHandler >::m_aaPos
 Accessor. More...
 
bool ug::IDomain< TGrid, TSubsetHandler >::m_adaptionIsActive
 
std::map< std::string, SmartPtr< TSubsetHandler > > ug::IDomain< TGrid, TSubsetHandler >::m_additionalSH
 additional subset handlers More...
 
position_attachment_type ug::Domain< d, TGrid, TSubsetHandler >::m_aPos
 Position Attachment. More...
 
DomainInfo ug::IDomain< TGrid, TSubsetHandler >::m_domainInfo
 
GridBaseObjectId ug::DomainInfo::m_elementType
 
SPIGeometry3d ug::Domain< d, TGrid, TSubsetHandler >::m_geometry3d
 
bool ug::IDomain< TGrid, TSubsetHandler >::m_isAdaptive
 
std::vector< int_tug::DomainInfo::m_maxNumLocalElems
 
std::vector< int_tug::DomainInfo::m_minNumLocalElems
 
std::vector< int_tug::DomainInfo::m_numElems
 
std::vector< int_tug::DomainInfo::m_numLocalElems
 local number of elements excluding ghosts. More...
 
std::vector< int_tug::DomainInfo::m_numLocalGhosts
 
int_t ug::DomainInfo::m_numSurfElems
 
SPRefinementProjector ug::IDomain< TGrid, TSubsetHandler >::m_refinementProjector
 
SmartPtr< TGrid > ug::IDomain< TGrid, TSubsetHandler >::m_spGrid
 Grid. More...
 
MessageHub::SPCallbackId ug::IDomain< TGrid, TSubsetHandler >::m_spGridAdaptionCallbackID
 
MessageHub::SPCallbackId ug::IDomain< TGrid, TSubsetHandler >::m_spGridCreationCallbackID
 
MessageHub::SPCallbackId ug::IDomain< TGrid, TSubsetHandler >::m_spGridDistributionCallbackID
 
SmartPtr< TSubsetHandler > ug::IDomain< TGrid, TSubsetHandler >::m_spSH
 Subset Handler. More...
 
std::vector< int_tug::DomainInfo::m_subsetDims
 
template<typename TDomain >
void ug::LoadDomain (TDomain &domain, const char *filename)
 Loads a domain from a grid-file. More...
 
template<typename TDomain >
void ug::LoadDomain (TDomain &domain, const char *filename, int procId)
 Loads a domain from a grid-file. More...
 

Detailed Description

Domain

Typedef Documentation

◆ base_type

template<int d, typename TGrid = MultiGrid, typename TSubsetHandler = MGSubsetHandler>
typedef IDomain<TGrid, TSubsetHandler> ug::Domain< d, TGrid, TSubsetHandler >::base_type
private

base type

◆ Domain1d

◆ Domain2d

◆ Domain3d

◆ grid_type [1/2]

template<typename TGrid = MultiGrid, typename TSubsetHandler = MGSubsetHandler>
typedef TGrid ug::IDomain< TGrid, TSubsetHandler >::grid_type

Grid type.

◆ grid_type [2/2]

template<int d, typename TGrid = MultiGrid, typename TSubsetHandler = MGSubsetHandler>
typedef base_type::grid_type ug::Domain< d, TGrid, TSubsetHandler >::grid_type

Grid type.

◆ int_t

typedef unsigned long long ug::DomainInfo::int_t

◆ position_accessor_type

template<int d, typename TGrid = MultiGrid, typename TSubsetHandler = MGSubsetHandler>
typedef Grid::VertexAttachmentAccessor<position_attachment_type> ug::Domain< d, TGrid, TSubsetHandler >::position_accessor_type

Type of Accessor to the Position Data Attachment.

◆ position_attachment_type

template<int d, typename TGrid = MultiGrid, typename TSubsetHandler = MGSubsetHandler>
typedef Attachment<position_type> ug::Domain< d, TGrid, TSubsetHandler >::position_attachment_type

Type of Position Attachment.

◆ position_type

template<int d, typename TGrid = MultiGrid, typename TSubsetHandler = MGSubsetHandler>
typedef MathVector<dim> ug::Domain< d, TGrid, TSubsetHandler >::position_type

Type of position coordinates.

◆ subset_handler_type [1/2]

template<typename TGrid = MultiGrid, typename TSubsetHandler = MGSubsetHandler>
typedef TSubsetHandler ug::IDomain< TGrid, TSubsetHandler >::subset_handler_type

Subset Handler type.

◆ subset_handler_type [2/2]

template<int d, typename TGrid = MultiGrid, typename TSubsetHandler = MGSubsetHandler>
typedef base_type::subset_handler_type ug::Domain< d, TGrid, TSubsetHandler >::subset_handler_type

Subset Handler type.

Function Documentation

◆ additional_subset_handler() [1/2]

template<typename TGrid , typename TSubsetHandler >
SmartPtr< TSubsetHandler > ug::IDomain< TGrid, TSubsetHandler >::additional_subset_handler ( std::string  name)

returns an additional subset handler Subset Handler

References name, UG_THROW, and SmartPtr< T, FreePolicy >::valid().

◆ additional_subset_handler() [2/2]

template<typename TGrid , typename TSubsetHandler >
const ConstSmartPtr< TSubsetHandler > ug::IDomain< TGrid, TSubsetHandler >::additional_subset_handler ( std::string  name) const

const access to Subset Handler

References name, UG_THROW, and SmartPtr< T, FreePolicy >::valid().

◆ additional_subset_handler_names()

template<typename TGrid , typename TSubsetHandler >
std::vector< std::string > ug::IDomain< TGrid, TSubsetHandler >::additional_subset_handler_names

returns a list with the names of additional subset handlers

◆ broadcast_refinement_projector()

◆ CollectCornerCoordinates() [1/3]

template<typename TDomain >
void ug::CollectCornerCoordinates ( int  base_object_id,
std::vector< typename TDomain::position_type > &  vCornerCoordsOut,
GridObject elem,
const TDomain &  domain,
bool  clearContainer 
)

returns the corner coordinates of a geometric object

Returns the corner coordinates for a given geometric object in a vector

This function calls CollectCornerCoordinates based on the base object id

Parameters
[out]vCornerCoordsOut
[in]base_object_id
[in]elem
[in]domain
[in]clearContainer

References ug::EDGE, ug::FACE, UG_THROW, ug::VERTEX, and ug::VOLUME.

◆ CollectCornerCoordinates() [2/3]

template<typename TElem , typename TAAPos >
void ug::CollectCornerCoordinates ( std::vector< typename TAAPos::ValueType > &  vCornerCoordsOut,
const TElem &  elem,
const TAAPos &  aaPos,
bool  clearContainer = true 
)

returns the corner coordinates of a geometric object

Returns the corner coordinated of a geometric object in a vector

This function collects the corner coordinates for a given geometric object in the order prescribed by the reference elements

Parameters
[out]vCornerCoordsOutvector of corner coordinates
[in]elemGeometric Object
[in]aaPosAttachmentAccessor for Positions
[in]clearContainerempty container before filling

Referenced by ug::ActiveSet< TDomain, TAlgebra >::active_index_elem(), ug::DirichletBoundary< TDomain, TAlgebra >::adjust_error(), ug::ObstacleInNormalDir< TDomain, TAlgebra >::adjust_sol_and_cor_elem(), ug::DomainDiscretizationBase< TDomain, TAlgebra, TGlobAssembler >::calc_error(), ug::ActiveSet< TDomain, TAlgebra >::check_conv_elem(), ug::CheckDoFElem(), ug::CollectCornerCoordinates(), ug::ComputeGradientCrouzeixRaviart(), ug::ComputeGradientLagrange1(), ug::ComputeGradientPiecewiseConstant(), ug::ConstructGridOfSCV(), ug::ConstructGridOfSCVF(), ug::DoFPosition(), ug::ElementSize(), ug::GradientEvaluator_LagrangeP1< TFunction >::evaluate(), ug::GlobalGridFunctionGradientData< TGridFunction >::evaluate(), ug::GlobalGridFunctionNumberData< TGridFunction, elemDim >::evaluate(), ug::L2DistIntegrand< TGridFunction >::evaluate(), ug::H1SemiDistIntegrand< TGridFunction >::evaluate(), ug::H1EnergyDistIntegrand< TGridFunction >::evaluate(), ug::H1DistIntegrand< TGridFunction >::evaluate(), ug::UserDataDistIntegrandSq< TData, TGridFunction >::evaluate(), ug::OutNormCmp< TDomain >::evaluate(), ug::bridge::Evaluate::NumberValuedUserDataEvaluator< TDomain, TAlgebra >::evaluateOnThisProcess(), ug::bridge::Evaluate::VectorValuedUserDataEvaluator< TDomain, TAlgebra >::evaluateOnThisProcess(), ug::bridge::Evaluate::VectorValuedUserDataEvaluator< TDomain, TAlgebra >::evaluateOnThisProcessNeighbouring(), ug::InnerDoFPosition(), ug::IntegralNormalComponentOnManifoldGeneral(), ug::IntegralNormalComponentOnManifoldUsingFV1Geom(), ug::Integrate(), ug::IntegrateNormalComponentOnManifold(), ug::IntegrateNormalGradientOnManifold(), ug::InterpolateOnDiffElements(), ug::ActiveSet< TDomain, TAlgebra >::lagrange_mat_inv_elem(), ug::MaxErrorOnElements(), ug::CrouzeixRaviartElemTransfer< TDomain >::prolongate(), ug::StdLagrangeElemTransfer< TDomain >::prolongate(), ug::ProlongateElemwise(), ug::RestrictElemwise(), ug::ShapesAtGlobalPosition(), ug::SideAndElemErrEstData< TDomain >::summarize_err_est_data(), ug::VTKOutput< TDim >::write_cell_data_elementwise(), and ug::VTKOutput< TDim >::write_nodal_data_elementwise().

◆ CollectCornerCoordinates() [3/3]

template<typename TElem , typename TDomain >
void ug::CollectCornerCoordinates ( std::vector< typename TDomain::position_type > &  vCornerCoordsOut,
const TElem &  elem,
const TDomain &  domain,
bool  clearContainer = true 
)

returns the corner coordinates of a geometric object

Returns the corner coordinated of a geometric object in a vector

This function collects the corner coordinates for a given geometric object in the order prescribed by the reference elements

Parameters
[out]vCornerCoordsOutvector of corner coordinates
[in]elemGeometric Object
[in]domainDomain
[in]clearContainerempty container before filling

References ug::CollectCornerCoordinates().

◆ count_ghosts()

template<typename TGrid , typename TSubsetHandler >
template<class TElem >
void ug::IDomain< TGrid, TSubsetHandler >::count_ghosts ( std::vector< DomainInfo::int_t > &  numGhostsOnLvlOut)
protected

make sure that elements of the given type are contained in at most one vmaster interface. This is always the case for highest dimensional elements.

References ug::GridLayoutMap::clear(), ug::GridLayoutMap::get_layout(), ug::DistributedGridManager::grid_layout_map(), ug::GridLayoutMap::has_layout(), ug::INT_V_MASTER, and ug::DistributedGridManager::is_ghost().

◆ count_local_unique_surface_elements()

template<typename TGrid , typename TSubsetHandler >
template<class TElem >
size_t ug::IDomain< TGrid, TSubsetHandler >::count_local_unique_surface_elements
protected

counts local surface elements which are not ghosts or h-slaves

References ug::DistributedGridManager::contains_status(), ug::ES_H_SLAVE, and ug::DistributedGridManager::is_ghost().

◆ create_additional_subset_handler()

template<typename TGrid , typename TSubsetHandler >
bool ug::IDomain< TGrid, TSubsetHandler >::create_additional_subset_handler ( std::string  name)

creates an additional subset-handler with the given name

If this subset-handler is created before the domain is loaded from a file, the contents of the handler will be filled with the contents of the file's subset-handler-node with the same name.

References name.

◆ deserialize_projector()

template<typename TGrid , typename TSubsetHandler >
SPRefinementProjector ug::IDomain< TGrid, TSubsetHandler >::deserialize_projector ( BinaryBuffer buf)
protected

◆ distributed_grid_manager()

template<typename TGrid = MultiGrid, typename TSubsetHandler = MGSubsetHandler>
DistributedGridManager* ug::IDomain< TGrid, TSubsetHandler >::distributed_grid_manager ( )
inline

returns Distributed Grid Manager

References ug::IDomain< TGrid, TSubsetHandler >::m_spGrid.

◆ Domain()

◆ domain_info()

template<typename TGrid = MultiGrid, typename TSubsetHandler = MGSubsetHandler>
const DomainInfo& ug::IDomain< TGrid, TSubsetHandler >::domain_info ( ) const
inline

returns information on the current domain

In a parallel environment, this information relates to the global (distributed) domain.

References ug::IDomain< TGrid, TSubsetHandler >::m_domainInfo.

◆ element_type()

int ug::DomainInfo::element_type ( ) const
inline

◆ ElementDiameter()

template<typename TElem , typename TDomain >
number ug::ElementDiameter ( const TElem &  elem,
TDomain &  domain 
)

returns the maximal distance between to element vertices

Referenced by ug::ElementDiameter(), and ug::EvaluateGradientJump_SideIntegral().

◆ ElementDiameterSq()

template<typename TElem , typename TDomain >
number ug::ElementDiameterSq ( const TElem &  elem,
TDomain &  domain 
)

returns the maximal squared distance between to element vertices

Referenced by ug::ElementDiameter(), ug::ElementDiameterSq(), ug::EvaluateResidualErrorP1(), ug::MaxElementDiameter(), and ug::MinElementDiameter().

◆ ElementSize() [1/2]

template<typename TElem , typename TPosition >
number ug::ElementSize ( const TElem &  elem,
const Grid::VertexAttachmentAccessor< Attachment< TPosition > > &  aaPos 
)

returns the size of a geometric object

Returns the size of a geometric object

This function returns the size of a geometric object.

Parameters
[in]elemGeometric Object
[in]aaPosAttachmentAccessor for Positions
Returns
number Size of Element

References ug::CollectCornerCoordinates(), and dim.

◆ ElementSize() [2/2]

template<typename TElem , typename TDomain >
number ug::ElementSize ( const TElem &  elem,
const TDomain &  domain 
)

returns the size of a geometric object

Returns the size of a geometric object

This function returns the size of a geometric object.

Parameters
[in]elemGeometric Object
[in]domainDomain
Returns
number Size of Element

References ug::ElementSize().

◆ empty()

template<typename TGrid = MultiGrid, typename TSubsetHandler = MGSubsetHandler>
bool ug::IDomain< TGrid, TSubsetHandler >::empty ( ) const
inline

returns whether the associated grid is empty

Note that one vertex is enough to consider the grid as non-empty.

References ug::IDomain< TGrid, TSubsetHandler >::m_spGrid.

◆ geometry3d() [1/2]

template<int d, typename TGrid = MultiGrid, typename TSubsetHandler = MGSubsetHandler>
virtual SPIGeometry3d ug::Domain< d, TGrid, TSubsetHandler >::geometry3d ( ) const
inlinevirtual

returns the geometry of the domain

Implements ug::IDomain< MultiGrid, MGSubsetHandler >.

References ug::Domain< d, TGrid, TSubsetHandler >::m_geometry3d.

◆ geometry3d() [2/2]

template<typename TGrid = MultiGrid, typename TSubsetHandler = MGSubsetHandler>
virtual SPIGeometry3d ug::IDomain< TGrid, TSubsetHandler >::geometry3d ( ) const
pure virtual

◆ get_dim() [1/2]

template<int d, typename TGrid = MultiGrid, typename TSubsetHandler = MGSubsetHandler>
virtual int ug::Domain< d, TGrid, TSubsetHandler >::get_dim ( ) const
inlinevirtual

◆ get_dim() [2/2]

template<typename TGrid = MultiGrid, typename TSubsetHandler = MGSubsetHandler>
virtual int ug::IDomain< TGrid, TSubsetHandler >::get_dim ( ) const
pure virtual

◆ grid() [1/2]

template<typename TGrid = MultiGrid, typename TSubsetHandler = MGSubsetHandler>
SmartPtr<TGrid> ug::IDomain< TGrid, TSubsetHandler >::grid ( )
inline

◆ grid() [2/2]

template<typename TGrid = MultiGrid, typename TSubsetHandler = MGSubsetHandler>
const ConstSmartPtr<TGrid> ug::IDomain< TGrid, TSubsetHandler >::grid ( ) const
inline

◆ grid_adaption_callback()

template<typename TGrid , typename TSubsetHandler >
void ug::IDomain< TGrid, TSubsetHandler >::grid_adaption_callback ( const GridMessage_Adaption msg)
inlineprotected

this callback is called by the message hub, when a grid adaption has been performed. It will call all necessary actions in order to keep the grid correct for computations.

References ug::GridMessage_Adaption::adaption_begins(), ug::GridMessage_Adaption::adaption_ends(), and UG_THROW.

◆ grid_creation_callback()

template<typename TGrid , typename TSubsetHandler >
void ug::IDomain< TGrid, TSubsetHandler >::grid_creation_callback ( const GridMessage_Creation msg)
inlineprotected

Called when a domain has been loaded and during domain distribution.

References ug::GMCT_CREATION_STOPS, ug::GridMessage_Creation::msg(), and ug::GridMessage_Creation::proc_id().

◆ grid_distribution_callback()

template<typename TGrid , typename TSubsetHandler >
void ug::IDomain< TGrid, TSubsetHandler >::grid_distribution_callback ( const GridMessage_Distribution msg)
inlineprotected

this callback is called by the message hub, when a grid has been distributed between different processes.

◆ IDomain()

template<typename TGrid , typename TSubsetHandler >
ug::IDomain< TGrid, TSubsetHandler >::IDomain ( bool  isAdaptive = true)

◆ is_adaptive()

template<typename TGrid = MultiGrid, typename TSubsetHandler = MGSubsetHandler>
bool ug::IDomain< TGrid, TSubsetHandler >::is_adaptive ( ) const
inline

returns whether the domain may be used for adaptive refinement

References ug::IDomain< TGrid, TSubsetHandler >::m_isAdaptive.

◆ is_parallel()

template<typename TGrid = MultiGrid, typename TSubsetHandler = MGSubsetHandler>
bool ug::IDomain< TGrid, TSubsetHandler >::is_parallel ( )
inline

returns whether the domain can be used for parallel computations

If ug was build with support for parallelism, this method will always return true and always false, if ug was build for serial environments.

References ug::IDomain< TGrid, TSubsetHandler >::m_spGrid.

◆ LoadDomain() [1/2]

template<typename TDomain >
void ug::LoadDomain ( TDomain &  domain,
const char *  filename 
)

Loads a domain from a grid-file.

By optionally specifying a procId, you can make sure that the domain is only loaded on one process. Pass -1, if you want to load it on all processes. Note that the procId is only important in parallel environments.

References ug::LoadDomain().

Referenced by ug::LoadAndRefineDomain().

◆ LoadDomain() [2/2]

template<typename TDomain >
void ug::LoadDomain ( TDomain &  domain,
const char *  filename,
int  procId 
)

Loads a domain from a grid-file.

By optionally specifying a procId, you can make sure that the domain is only loaded on one process. Pass -1, if you want to load it on all processes. Note that the procId is only important in parallel environments.

References ug::LoadGridFromFile(), make_sp(), PROFILE_FUNC_GROUP, and UG_THROW.

Referenced by ug::LoadDomain().

◆ max_num_local_elements_on_level()

size_t ug::DomainInfo::max_num_local_elements_on_level ( size_t  lvl) const
inline

returns the maximum number of elements a process has on a given leven (excluding ghosts)

References ug::DomainInfo::m_maxNumLocalElems.

◆ MaxElementDiameter()

template<typename TDomain >
number ug::MaxElementDiameter ( TDomain &  domain,
int  level 
)

returns the maximal diameter of all elements between iterBegin and iterEnd.

◆ message_hub()

template<typename TGrid = MultiGrid, typename TSubsetHandler = MGSubsetHandler>
SPMessageHub ug::IDomain< TGrid, TSubsetHandler >::message_hub ( )
inline

returns the message hub of the grid

References ug::IDomain< TGrid, TSubsetHandler >::m_spGrid.

Referenced by ug::IDomain< TGrid, TSubsetHandler >::IDomain().

◆ min_num_local_elements_on_level()

size_t ug::DomainInfo::min_num_local_elements_on_level ( size_t  lvl) const
inline

returns the minimum number of elements a process has on a given leven (excluding ghosts)

References ug::DomainInfo::m_minNumLocalElems.

◆ MinElementDiameter()

template<typename TDomain >
number ug::MinElementDiameter ( TDomain &  domain,
int  level 
)

returns the minimal diameter of all elements between iterBegin and iterEnd.

◆ num_elements()

size_t ug::DomainInfo::num_elements ( ) const
inline

◆ num_elements_on_level()

size_t ug::DomainInfo::num_elements_on_level ( size_t  lvl) const
inline

returns the global number of elements on the given level (excluding ghosts...)

References ug::DomainInfo::m_numElems.

Referenced by ug::CreateProcessHierarchy().

◆ num_levels()

size_t ug::DomainInfo::num_levels ( ) const
inline

◆ num_local_elements_on_level()

size_t ug::DomainInfo::num_local_elements_on_level ( size_t  lvl) const
inline

returns the local number of elements on the given level (excluding ghosts...)

References ug::DomainInfo::m_numLocalElems.

◆ num_local_ghosts_on_level()

size_t ug::DomainInfo::num_local_ghosts_on_level ( size_t  lvl) const
inline

returns the local number of ghosts on the given level

References ug::DomainInfo::m_numLocalGhosts.

◆ num_subsets()

size_t ug::DomainInfo::num_subsets ( ) const
inline

◆ num_surface_elements()

size_t ug::DomainInfo::num_surface_elements ( ) const
inline

returns the global number of surface elements (elements without children)

References ug::DomainInfo::m_numSurfElems.

◆ position_accessor() [1/2]

template<int d, typename TGrid = MultiGrid, typename TSubsetHandler = MGSubsetHandler>
position_accessor_type& ug::Domain< d, TGrid, TSubsetHandler >::position_accessor ( )
inline

get Position Accessor

References ug::Domain< d, TGrid, TSubsetHandler >::m_aaPos.

Referenced by ug::VTKOutput< TDim >::print().

◆ position_accessor() [2/2]

template<int d, typename TGrid = MultiGrid, typename TSubsetHandler = MGSubsetHandler>
const position_accessor_type& ug::Domain< d, TGrid, TSubsetHandler >::position_accessor ( ) const
inline

const access to Position Accessor

References ug::Domain< d, TGrid, TSubsetHandler >::m_aaPos.

◆ position_attachment() [1/2]

template<int d, typename TGrid = MultiGrid, typename TSubsetHandler = MGSubsetHandler>
position_attachment_type& ug::Domain< d, TGrid, TSubsetHandler >::position_attachment ( )
inline

◆ position_attachment() [2/2]

template<int d, typename TGrid = MultiGrid, typename TSubsetHandler = MGSubsetHandler>
const position_attachment_type& ug::Domain< d, TGrid, TSubsetHandler >::position_attachment ( ) const
inline

const access to Position Attachment

References ug::Domain< d, TGrid, TSubsetHandler >::m_aPos.

◆ refinement_projector()

template<typename TGrid , typename TSubsetHandler >
SPRefinementProjector ug::IDomain< TGrid, TSubsetHandler >::refinement_projector

returns the domain's ug::RefinementProjector. The pointer may be invalid.

◆ SaveDomain()

template<typename TDomain >
void ug::SaveDomain ( TDomain &  domain,
const char *  filename 
)

◆ serialize_projector()

template<typename TGrid , typename TSubsetHandler >
void ug::IDomain< TGrid, TSubsetHandler >::serialize_projector ( BinaryBuffer bufOut,
SPRefinementProjector  proj 
)
protected

◆ set_info()

void ug::DomainInfo::set_info ( GridBaseObjectId  elemType,
const std::vector< int_t > &  numElems,
const std::vector< int_t > &  numLocalElems,
const std::vector< int_t > &  minNumLocalElems,
const std::vector< int_t > &  maxNumLocalElems,
const std::vector< int_t > &  numLocalGhosts,
const std::vector< int_t > &  subsetDims,
int_t  numSurfElems 
)
inline

◆ set_refinement_projector()

template<typename TGrid , typename TSubsetHandler >
void ug::IDomain< TGrid, TSubsetHandler >::set_refinement_projector ( SPRefinementProjector  proj)

sets the ug::RefinementProjector which can be used by refiners during refinement

References ug::RefinementProjector::set_geometry(), and SmartPtr< T, FreePolicy >::valid().

◆ subset_dim()

size_t ug::DomainInfo::subset_dim ( int  si) const
inline

◆ subset_handler() [1/2]

template<typename TGrid = MultiGrid, typename TSubsetHandler = MGSubsetHandler>
SmartPtr<TSubsetHandler> ug::IDomain< TGrid, TSubsetHandler >::subset_handler ( )
inline

returns Subset Handler

References ug::IDomain< TGrid, TSubsetHandler >::m_spSH.

Referenced by ug::VTKOutput< TDim >::print().

◆ subset_handler() [2/2]

template<typename TGrid = MultiGrid, typename TSubsetHandler = MGSubsetHandler>
const ConstSmartPtr<TSubsetHandler> ug::IDomain< TGrid, TSubsetHandler >::subset_handler ( ) const
inline

const access to Subset Handler

References ug::IDomain< TGrid, TSubsetHandler >::m_spSH.

◆ to_string()

std::string ug::DomainInfo::to_string ( ) const

◆ update_domain_info()

template<typename TGrid , typename TSubsetHandler >
void ug::IDomain< TGrid, TSubsetHandler >::update_domain_info

updates the internal domain-info object.

This method is called automatically each time the associated grid has changed.

◆ update_subset_infos()

template<typename TGrid , typename TSubsetHandler >
void ug::IDomain< TGrid, TSubsetHandler >::update_subset_infos ( int  rootProc)

updates and broadcasts subset names and dimensions from the given rootProc to all other processes.

References pcl::ProcessCommunicator::broadcast(), ug::Deserialize(), dim, pcl::ProcRank(), PROFILE_FUNC, and ug::Serialize().

◆ ~Domain()

template<int d, typename TGrid = MultiGrid, typename TSubsetHandler = MGSubsetHandler>
virtual ug::Domain< d, TGrid, TSubsetHandler >::~Domain ( )
inlinevirtual

◆ ~IDomain()

template<typename TGrid , typename TSubsetHandler >
ug::IDomain< TGrid, TSubsetHandler >::~IDomain
virtual

Destructor.

Variable Documentation

◆ dim

template<int d, typename TGrid = MultiGrid, typename TSubsetHandler = MGSubsetHandler>
const int ug::Domain< d, TGrid, TSubsetHandler >::dim = d
static

◆ m_aaPos

template<int d, typename TGrid = MultiGrid, typename TSubsetHandler = MGSubsetHandler>
position_accessor_type ug::Domain< d, TGrid, TSubsetHandler >::m_aaPos
protected

◆ m_adaptionIsActive

template<typename TGrid = MultiGrid, typename TSubsetHandler = MGSubsetHandler>
bool ug::IDomain< TGrid, TSubsetHandler >::m_adaptionIsActive
protected

◆ m_additionalSH

template<typename TGrid = MultiGrid, typename TSubsetHandler = MGSubsetHandler>
std::map<std::string, SmartPtr<TSubsetHandler> > ug::IDomain< TGrid, TSubsetHandler >::m_additionalSH
protected

additional subset handlers

◆ m_aPos

template<int d, typename TGrid = MultiGrid, typename TSubsetHandler = MGSubsetHandler>
position_attachment_type ug::Domain< d, TGrid, TSubsetHandler >::m_aPos
protected

◆ m_domainInfo

template<typename TGrid = MultiGrid, typename TSubsetHandler = MGSubsetHandler>
DomainInfo ug::IDomain< TGrid, TSubsetHandler >::m_domainInfo
protected

◆ m_elementType

GridBaseObjectId ug::DomainInfo::m_elementType
private

◆ m_geometry3d

template<int d, typename TGrid = MultiGrid, typename TSubsetHandler = MGSubsetHandler>
SPIGeometry3d ug::Domain< d, TGrid, TSubsetHandler >::m_geometry3d
protected

◆ m_isAdaptive

template<typename TGrid = MultiGrid, typename TSubsetHandler = MGSubsetHandler>
bool ug::IDomain< TGrid, TSubsetHandler >::m_isAdaptive
protected

◆ m_maxNumLocalElems

std::vector<int_t> ug::DomainInfo::m_maxNumLocalElems
private

◆ m_minNumLocalElems

std::vector<int_t> ug::DomainInfo::m_minNumLocalElems
private

◆ m_numElems

◆ m_numLocalElems

std::vector<int_t> ug::DomainInfo::m_numLocalElems
private

local number of elements excluding ghosts.

Referenced by ug::DomainInfo::num_local_elements_on_level(), and ug::DomainInfo::set_info().

◆ m_numLocalGhosts

std::vector<int_t> ug::DomainInfo::m_numLocalGhosts
private

◆ m_numSurfElems

int_t ug::DomainInfo::m_numSurfElems
private

◆ m_refinementProjector

template<typename TGrid = MultiGrid, typename TSubsetHandler = MGSubsetHandler>
SPRefinementProjector ug::IDomain< TGrid, TSubsetHandler >::m_refinementProjector
protected

◆ m_spGrid

◆ m_spGridAdaptionCallbackID

template<typename TGrid = MultiGrid, typename TSubsetHandler = MGSubsetHandler>
MessageHub::SPCallbackId ug::IDomain< TGrid, TSubsetHandler >::m_spGridAdaptionCallbackID
protected

◆ m_spGridCreationCallbackID

template<typename TGrid = MultiGrid, typename TSubsetHandler = MGSubsetHandler>
MessageHub::SPCallbackId ug::IDomain< TGrid, TSubsetHandler >::m_spGridCreationCallbackID
protected

◆ m_spGridDistributionCallbackID

template<typename TGrid = MultiGrid, typename TSubsetHandler = MGSubsetHandler>
MessageHub::SPCallbackId ug::IDomain< TGrid, TSubsetHandler >::m_spGridDistributionCallbackID
protected

◆ m_spSH

template<typename TGrid = MultiGrid, typename TSubsetHandler = MGSubsetHandler>
SmartPtr<TSubsetHandler> ug::IDomain< TGrid, TSubsetHandler >::m_spSH
protected

◆ m_subsetDims

std::vector<int_t> ug::DomainInfo::m_subsetDims
private