OpenFCST: The open-source Fuel Cell Simulation Toolbox
|
A collection of functions and classes for the mesh loops that are an ubiquitous part of each finite element program. More...
Namespaces | |
namespace | Assembler |
The namespace containing objects that can be used to assemble data computed on cells and faces into global objects. | |
namespace | InfoObjects |
namespace | internal |
namespace | WorkerObjects |
Classes | |
struct | BlockInfo |
A small structure collecting the different BlockIndices of FEVector vectors (for instance, solution) involved in the computations. More... | |
class | VectorSelector |
A class that selects the named FEVector vectors in FEVectors and assigns the types of information extracted. More... | |
Functions | |
unsigned int | selector_size (const VectorSelector &s, const std::vector< double > &) |
Additionally to the VectorSelector class we collect some helper functions that choose the right access functions in the VectorSelector class itself depending on the data type being used. | |
template<int dim> | |
unsigned int | selector_size (const VectorSelector &s, const std::vector< Tensor< 1, dim > > &) |
template<int dim> | |
unsigned int | selector_size (const VectorSelector &s, const std::vector< Tensor< 2, dim > > &) |
unsigned int | selector_index (const VectorSelector &s, unsigned int i, const std::vector< double > &) |
template<int dim> | |
unsigned int | selector_index (const VectorSelector &s, unsigned int i, const std::vector< Tensor< 1, dim > > &) |
template<int dim> | |
unsigned int | selector_index (const VectorSelector &s, unsigned int i, const std::vector< Tensor< 2, dim > > &) |
template<class ITERATOR , class ENDITERATOR , class CELLINFO , class FACEINFO , class LOCALWORKER > | |
void | loop (ITERATOR begin, ENDITERATOR end, CELLINFO &cellinfo, FACEINFO &bdryinfo, FACEINFO &faceinfo, FACEINFO &subfaceinfo, FACEINFO &ngbrinfo, LOCALWORKER &localworker, bool cells_first=true) |
The main work function of this namespace. | |
template<int dim, class ITERATOR , class ENDITERATOR , class LOCALWORKER > | |
void | integration_loop (ITERATOR begin, ENDITERATOR end, InfoObjects::IntegrationInfoBox< dim > &box, LOCALWORKER &localworker, bool cells_first=true) |
Simplified interface for loop() if specialized for integration. | |
A collection of functions and classes for the mesh loops that are an ubiquitous part of each finite element program.
The workhorse of this namespace is the loop() function, which implements a completely generic loop over all mesh entities (cells and faces).
The loop() depends on certain objects handed to it as arguments. These objects can be structured into categories corresponding to the namespaces where they are defined.
They can be considered as an extension of mesh Iterators in the sense that they are updated for each mesh cell or face, and provide additional data on these mesh entities.
The workhorse of this namespace is the loop() function, which implements a completely generic loop over all mesh entities (cells and faces).
The loop() depends on certain objects handed to it as arguments. These objects can be structured into categories corresponding to the namespaces where they are defined.
void MeshWorker::integration_loop | ( | ITERATOR | begin, |
ENDITERATOR | end, | ||
InfoObjects::IntegrationInfoBox< dim > & | box, | ||
LOCALWORKER & | localworker, | ||
bool | cells_first = true |
||
) |
Simplified interface for loop() if specialized for integration.
References MeshWorker::InfoObjects::IntegrationInfoBox< dim >::bdry_info, MeshWorker::InfoObjects::IntegrationInfoBox< dim >::cell_info, MeshWorker::InfoObjects::IntegrationInfoBox< dim >::face_info, loop(), MeshWorker::InfoObjects::IntegrationInfoBox< dim >::neighbor_info, and MeshWorker::InfoObjects::IntegrationInfoBox< dim >::subface_info.
void MeshWorker::loop | ( | ITERATOR | begin, |
ENDITERATOR | end, | ||
CELLINFO & | cellinfo, | ||
FACEINFO & | bdryinfo, | ||
FACEINFO & | faceinfo, | ||
FACEINFO & | subfaceinfo, | ||
FACEINFO & | ngbrinfo, | ||
LOCALWORKER & | localworker, | ||
bool | cells_first = true |
||
) |
The main work function of this namespace.
Its action consists of two loops.
First, a loop over all cells in the iterator range is performed, in each step updating the CellInfo object, then calling LocalWorker::cell() with this object.
In the second loop, we work through all the faces of cells in the iterator range. The functions LocalWorker::bdry() and LocalWorker::face() are called for each boundary and interior face, respectively. Unilaterally refined interior faces are handled automatically by the loop.
The extend of the second loop will be determined by the two control variables LocalWorker::boundary_fluxes and LocalWorker::interior_fluxes.
References MeshWorker::internal::is_active_iterator().
Referenced by integration_loop().
|
inline |
References MeshWorker::VectorSelector::value_index().
Referenced by MeshWorker::InfoObjects::IntegrationInfo< dim, FEVALUESBASE >::fill_local_data().
|
inline |
|
inline |
|
inline |
Additionally to the VectorSelector class we collect some helper functions that choose the right access functions in the VectorSelector class itself depending on the data type being used.
Note that the last argument of these helper functions is never used. It is there just for the type identification.
References MeshWorker::VectorSelector::n_values().
Referenced by MeshWorker::InfoObjects::IntegrationInfo< dim, FEVALUESBASE >::fill_local_data().
|
inline |
|
inline |