![]() |
Dune-Fufem 2.11-git
|
A discrete coordinate function for Dune::GeometryGrid. More...
#include <dune/fufem/functions/deformationfunction.hh>

Public Types | |
| using | HostGrid = HG |
| using | Domain = typename HostGrid::template Codim< dim >::Geometry::GlobalCoordinate |
| using | ctype = ct |
| using | Range = Dune::FieldVector< ct, deformedDim > |
| using | Basis = Dune::Functions::DefaultGlobalBasis< PreBasis > |
| using | CoefficientVector = Dune::BlockVector< Range > |
| typedef Base::RangeVector | RangeVector |
| typedef This | Interface |
| typedef Impl | Implementation |
Public Member Functions | |
| DeformationFunction (const HostGrid &hostGrid, Dune::index_constant< deformedDim > deformedDimConstant={}) | |
| Create a deformation function on given HostGrid. | |
| template<class F > | |
| DeformationFunction (const HostGrid &hostGrid, const F &f, Dune::index_constant< deformedDim > deformedDimConstant={}) | |
| Create a deformation function on given HostGrid from given function. | |
| virtual | ~DeformationFunction () |
| virtual void | evaluate (const typename HostGrid::template Codim< 0 >::Entity &entity, unsigned int corner, Range &y) const |
| Evaluate function at a host vertex (corner param is redundant but prescribed by the interface...) | |
| virtual void | evaluate (const typename HostGrid::template Codim< dim >::Entity &entity, unsigned int corner, Range &y) const |
| Evaluate function at a corner of a host element. | |
| void | adapt () |
| Adapt to changes in the host grid. | |
| const Basis & | basis () const |
| Access basis for deformation function. | |
| CoefficientVector & | coefficients () |
| Mutable access to coefficient vector. | |
| const CoefficientVector & | coefficients () const |
| Const access to coefficient vector. | |
| template<class F > | |
| void | interpolate (const F &f) |
| Reset the deformation to the interpolate of the given function. | |
| void | evaluate (const HostEntity &hostEntity, unsigned int corner, RangeVector &y) const |
Static Public Attributes | |
| static const unsigned int | dimRange |
Protected Member Functions | |
| void | setupLeafIndices () |
| const Implementation & | asImp () const |
| Implementation & | asImp () |
Protected Attributes | |
| std::vector< std::vector< std::size_t > > | leafIndices_ |
| const HostGrid * | hostGrid_ |
| Basis | basis_ |
| CoefficientVector | coefficients_ |
Detailed Description
class Dune::Fufem::Experimental::DeformationFunction< HG, deformedDim, ct >
A discrete coordinate function for Dune::GeometryGrid.
This class implements the interface of a Dune::DiscreteCoordFunction which can be used as coordinate function for a Dune::GeometryGrid.
- Template Parameters
-
HG Type of the grid that should be deformed deformedDim World dimension of the defomed grid ct Global coordinate type of the defomed grid
Member Typedef Documentation
◆ Basis
| using Dune::Fufem::Experimental::DeformationFunction< HG, deformedDim, ct >::Basis = Dune::Functions::DefaultGlobalBasis<PreBasis> |
◆ CoefficientVector
| using Dune::Fufem::Experimental::DeformationFunction< HG, deformedDim, ct >::CoefficientVector = Dune::BlockVector<Range> |
◆ ctype
| using Dune::Fufem::Experimental::DeformationFunction< HG, deformedDim, ct >::ctype = ct |
◆ Domain
| using Dune::Fufem::Experimental::DeformationFunction< HG, deformedDim, ct >::Domain = typename HostGrid::template Codim<dim>::Geometry::GlobalCoordinate |
◆ HostGrid
| using Dune::Fufem::Experimental::DeformationFunction< HG, deformedDim, ct >::HostGrid = HG |
◆ Range
| using Dune::Fufem::Experimental::DeformationFunction< HG, deformedDim, ct >::Range = Dune::FieldVector<ct, deformedDim> |
Constructor & Destructor Documentation
◆ DeformationFunction() [1/2]
|
inline |
Create a deformation function on given HostGrid.
- Parameters
-
hostGrid The underlying HostGrid that should be deformed
◆ DeformationFunction() [2/2]
|
inline |
Create a deformation function on given HostGrid from given function.
- Parameters
-
hostGrid The underlying HostGrid that should be deformed f The function to interpolate
◆ ~DeformationFunction()
|
inlinevirtual |
Member Function Documentation
◆ adapt()
|
inline |
Adapt to changes in the host grid.
◆ basis()
|
inline |
Access basis for deformation function.
The deformation is a function from the space spanned by this basis.
◆ coefficients() [1/2]
|
inline |
Mutable access to coefficient vector.
This provides access to the coefficient vector storing the coefficient of the deformation function with respect to the basis.
◆ coefficients() [2/2]
|
inline |
Const access to coefficient vector.
This provides access to the coefficient vector storing the coefficient of the deformation function with respect to the basis.
◆ evaluate() [1/2]
|
inlinevirtual |
Evaluate function at a host vertex (corner param is redundant but prescribed by the interface...)
◆ evaluate() [2/2]
|
inlinevirtual |
Evaluate function at a corner of a host element.
◆ interpolate()
|
inline |
Reset the deformation to the interpolate of the given function.
- Parameters
-
f The function to interpolate
This method will interpolate the given function with respect to the basis and store the respective coefficient vector. Hence the given function should be defined on the LeafGridView of the HostGrid and have the range type Range.
◆ setupLeafIndices()
|
inlineprotected |
Member Data Documentation
◆ basis_
|
protected |
◆ coefficients_
|
protected |
◆ hostGrid_
|
protected |
◆ leafIndices_
|
protected |
The documentation for this class was generated from the following file:
