DGtal 1.3.0
Loading...
Searching...
No Matches
Public Types | Public Member Functions | Static Public Member Functions | Static Protected Member Functions | Private Member Functions
DGtal::DiscreteExteriorCalculusFactory< TLinearAlgebraBackend, TInteger > Class Template Reference

Aim: This class provides static members to create DEC structures from various other DGtal structures. More...

#include <DGtal/dec/DiscreteExteriorCalculusFactory.h>

Public Types

typedef TLinearAlgebraBackend::DenseVector DenseVector
 
typedef TLinearAlgebraBackend::DenseMatrix DenseMatrix
 
typedef TLinearAlgebraBackend::SparseMatrix SparseMatrix
 

Public Member Functions

 BOOST_CONCEPT_ASSERT ((concepts::CInteger< TInteger >))
 
 BOOST_CONCEPT_ASSERT ((concepts::CDynamicVector< DenseVector >))
 
 BOOST_CONCEPT_ASSERT ((concepts::CDynamicMatrix< DenseMatrix >))
 
 BOOST_CONCEPT_ASSERT ((concepts::CDynamicMatrix< SparseMatrix >))
 
 BOOST_CONCEPT_ASSERT ((concepts::CLinearAlgebra< DenseVector, SparseMatrix >))
 
 BOOST_CONCEPT_ASSERT ((concepts::CLinearAlgebra< DenseVector, DenseMatrix >))
 

Static Public Member Functions

template<typename TDigitalSet >
static DiscreteExteriorCalculus< TDigitalSet::Point::dimension, TDigitalSet::Point::dimension, TLinearAlgebraBackend, TInteger > createFromDigitalSet (const TDigitalSet &set, const bool add_border=true)
 
template<Dimension dimEmbedded, typename TNSCellConstIterator >
static DiscreteExteriorCalculus< dimEmbedded, TNSCellConstIterator::value_type::Point::dimension, TLinearAlgebraBackend, TInteger > createFromNSCells (const TNSCellConstIterator &begin, const TNSCellConstIterator &end, const bool add_border=true)
 
template<DGtal::Dimension dimEmbedded, typename TNSCellConstIterator , typename TSCellMeasureFunctor >
static DiscreteExteriorCalculus< dimEmbedded, TNSCellConstIterator::value_type::Point::dimension, TLinearAlgebraBackend, TInteger > createFromNSCells (const TNSCellConstIterator &begin, const TNSCellConstIterator &end, const TSCellMeasureFunctor &normalFunctor, const double h, const bool add_border=true)
 

Static Protected Member Functions

template<typename KSpace , typename CellsSet >
static void insertAllLowerIncidentCells (const KSpace &kspace, const typename CellsSet::value_type &cell, CellsSet &cells_set)
 
template<typename KSpace , typename CellsAccum >
static void accumulateAllLowerIncidentCells (const KSpace &kspace, const typename CellsAccum::key_type &cell, CellsAccum &cells_accum)
 
template<typename KSpace , typename CellsAccum , typename MeasureAccum >
static void accumulateAllLowerIncidentCells (const KSpace &kspace, const typename CellsAccum::key_type &cell, CellsAccum &cells_accum, CellsAccum &local_accum, MeasureAccum &cell_to_measure, const double measure)
 

Private Member Functions

 DiscreteExteriorCalculusFactory ()
 
 DiscreteExteriorCalculusFactory (const DiscreteExteriorCalculusFactory &other)
 
DiscreteExteriorCalculusFactoryoperator= (const DiscreteExteriorCalculusFactory &other)
 

Detailed Description

template<typename TLinearAlgebraBackend, typename TInteger = DGtal::int32_t>
class DGtal::DiscreteExteriorCalculusFactory< TLinearAlgebraBackend, TInteger >

Aim: This class provides static members to create DEC structures from various other DGtal structures.

Description of class 'DiscreteExteriorCalculusFactory'

Template Parameters
TLinearAlgebraBackendlinear algebra backend used (i.e. EigenLinearAlgebraBackend).
TIntegerinteger type forwarded to khalimsky space.
Examples
dec/exampleDECSurface.cpp, dec/exampleDiscreteExteriorCalculusSolve.cpp, dec/exampleDiscreteExteriorCalculusUsage.cpp, dec/exampleHeatLaplace.cpp, and dec/examplePropagation.cpp.

Definition at line 61 of file DiscreteExteriorCalculusFactory.h.

Member Typedef Documentation

◆ DenseMatrix

template<typename TLinearAlgebraBackend , typename TInteger = DGtal::int32_t>
typedef TLinearAlgebraBackend::DenseMatrix DGtal::DiscreteExteriorCalculusFactory< TLinearAlgebraBackend, TInteger >::DenseMatrix

Definition at line 67 of file DiscreteExteriorCalculusFactory.h.

◆ DenseVector

template<typename TLinearAlgebraBackend , typename TInteger = DGtal::int32_t>
typedef TLinearAlgebraBackend::DenseVector DGtal::DiscreteExteriorCalculusFactory< TLinearAlgebraBackend, TInteger >::DenseVector

Definition at line 66 of file DiscreteExteriorCalculusFactory.h.

◆ SparseMatrix

template<typename TLinearAlgebraBackend , typename TInteger = DGtal::int32_t>
typedef TLinearAlgebraBackend::SparseMatrix DGtal::DiscreteExteriorCalculusFactory< TLinearAlgebraBackend, TInteger >::SparseMatrix

Definition at line 68 of file DiscreteExteriorCalculusFactory.h.

Constructor & Destructor Documentation

◆ DiscreteExteriorCalculusFactory() [1/2]

template<typename TLinearAlgebraBackend , typename TInteger = DGtal::int32_t>
DGtal::DiscreteExteriorCalculusFactory< TLinearAlgebraBackend, TInteger >::DiscreteExteriorCalculusFactory ( )
private

Constructor. Forbidden by default.

◆ DiscreteExteriorCalculusFactory() [2/2]

template<typename TLinearAlgebraBackend , typename TInteger = DGtal::int32_t>
DGtal::DiscreteExteriorCalculusFactory< TLinearAlgebraBackend, TInteger >::DiscreteExteriorCalculusFactory ( const DiscreteExteriorCalculusFactory< TLinearAlgebraBackend, TInteger > &  other)
private

Copy constructor.

Parameters
otherthe object to clone. Forbidden by default.

Member Function Documentation

◆ accumulateAllLowerIncidentCells() [1/2]

template<typename TLinearAlgebraBackend , typename TInteger = DGtal::int32_t>
template<typename KSpace , typename CellsAccum >
static void DGtal::DiscreteExteriorCalculusFactory< TLinearAlgebraBackend, TInteger >::accumulateAllLowerIncidentCells ( const KSpace kspace,
const typename CellsAccum::key_type &  cell,
CellsAccum &  cells_accum 
)
staticprotected

Insert and count recursively all lower incident cells into cells accumulator, starting from cell. Internal use only.

Template Parameters
KSpaceKhalimsky space type.
CellsAccumcells accumulator type, should be similar to std::map<KSpace::Cell, int> or std::map<KSpace::SCell, int>. Counts are stored as values, cells are stored as keys.
Parameters
kspaceKhalimsky space instance.
cellstarting cell.
cells_accumcells accumulator in which lower incident cells get inserted and counted.

◆ accumulateAllLowerIncidentCells() [2/2]

template<typename TLinearAlgebraBackend , typename TInteger = DGtal::int32_t>
template<typename KSpace , typename CellsAccum , typename MeasureAccum >
static void DGtal::DiscreteExteriorCalculusFactory< TLinearAlgebraBackend, TInteger >::accumulateAllLowerIncidentCells ( const KSpace kspace,
const typename CellsAccum::key_type &  cell,
CellsAccum &  cells_accum,
CellsAccum &  local_accum,
MeasureAccum &  cell_to_measure,
const double  measure 
)
staticprotected

Insert and count recursively all lower incident cells into cells accumulator, starting from cell embedding the measure of such cell. Internal use only.

Template Parameters
KSpaceKhalimsky space type.
CellsAccumcells accumulator type, should be similar to std::map<KSpace::Cell, int> or std::map<KSpace::SCell, int>. Counts are stored as values, cells are stored as keys.
Parameters
kspaceKhalimsky space instance.
cellstarting cell.
cells_accumcells accumulator in which lower incident cells get inserted and counted.
local_accumlocal cells accumulator for measure embedding
cell_to_measurea map from cell to its measure
measurethe current measure to be embedded

◆ BOOST_CONCEPT_ASSERT() [1/6]

template<typename TLinearAlgebraBackend , typename TInteger = DGtal::int32_t>
DGtal::DiscreteExteriorCalculusFactory< TLinearAlgebraBackend, TInteger >::BOOST_CONCEPT_ASSERT ( (concepts::CDynamicMatrix< DenseMatrix >)  )

◆ BOOST_CONCEPT_ASSERT() [2/6]

template<typename TLinearAlgebraBackend , typename TInteger = DGtal::int32_t>
DGtal::DiscreteExteriorCalculusFactory< TLinearAlgebraBackend, TInteger >::BOOST_CONCEPT_ASSERT ( (concepts::CDynamicMatrix< SparseMatrix >)  )

◆ BOOST_CONCEPT_ASSERT() [3/6]

template<typename TLinearAlgebraBackend , typename TInteger = DGtal::int32_t>
DGtal::DiscreteExteriorCalculusFactory< TLinearAlgebraBackend, TInteger >::BOOST_CONCEPT_ASSERT ( (concepts::CDynamicVector< DenseVector >)  )

◆ BOOST_CONCEPT_ASSERT() [4/6]

template<typename TLinearAlgebraBackend , typename TInteger = DGtal::int32_t>
DGtal::DiscreteExteriorCalculusFactory< TLinearAlgebraBackend, TInteger >::BOOST_CONCEPT_ASSERT ( (concepts::CInteger< TInteger >)  )

◆ BOOST_CONCEPT_ASSERT() [5/6]

template<typename TLinearAlgebraBackend , typename TInteger = DGtal::int32_t>
DGtal::DiscreteExteriorCalculusFactory< TLinearAlgebraBackend, TInteger >::BOOST_CONCEPT_ASSERT ( (concepts::CLinearAlgebra< DenseVector, DenseMatrix >)  )

◆ BOOST_CONCEPT_ASSERT() [6/6]

template<typename TLinearAlgebraBackend , typename TInteger = DGtal::int32_t>
DGtal::DiscreteExteriorCalculusFactory< TLinearAlgebraBackend, TInteger >::BOOST_CONCEPT_ASSERT ( (concepts::CLinearAlgebra< DenseVector, SparseMatrix >)  )

◆ createFromDigitalSet()

template<typename TLinearAlgebraBackend , typename TInteger = DGtal::int32_t>
template<typename TDigitalSet >
static DiscreteExteriorCalculus< TDigitalSet::Point::dimension, TDigitalSet::Point::dimension, TLinearAlgebraBackend, TInteger > DGtal::DiscreteExteriorCalculusFactory< TLinearAlgebraBackend, TInteger >::createFromDigitalSet ( const TDigitalSet &  set,
const bool  add_border = true 
)
static

Create a DEC structure from digital set. DEC embedded and ambient dimensions are equal to digital set point dimension. Points of the set get attached to primal n-cell <-> dual 0-cell.

Template Parameters
TDigitalSettype of digital set passed as argument. must be a model of concepts::CDigitalSet.
Parameters
setthe set from which to build to DEC structure.
add_borderadd border to the computed structure. For a precise definition see section Border definition.

◆ createFromNSCells() [1/2]

template<typename TLinearAlgebraBackend , typename TInteger = DGtal::int32_t>
template<Dimension dimEmbedded, typename TNSCellConstIterator >
static DiscreteExteriorCalculus< dimEmbedded, TNSCellConstIterator::value_type::Point::dimension, TLinearAlgebraBackend, TInteger > DGtal::DiscreteExteriorCalculusFactory< TLinearAlgebraBackend, TInteger >::createFromNSCells ( const TNSCellConstIterator &  begin,
const TNSCellConstIterator &  end,
const bool  add_border = true 
)
static

Create a DEC structure from a range of signed n-cells, where n is the embedded dimension. Signed n-cells may live in an ambient Khamlisky space with dimension greater than n. N-cells get attached to primal n-cell <-> dual 0-cell. See section Introduction for more information.

Template Parameters
dimEmbeddeddimension of emmbedded manifold. All input n-cells must have their dimension equal to dimEmbedded.
TNSCellConstIteratorsigned cells collection const iterator type.
Parameters
beginbeginning of iteration range.
endend of iteration range.
add_borderadd border to the computed structure. For a precise definition see section Border definition.

◆ createFromNSCells() [2/2]

template<typename TLinearAlgebraBackend , typename TInteger = DGtal::int32_t>
template<DGtal::Dimension dimEmbedded, typename TNSCellConstIterator , typename TSCellMeasureFunctor >
static DiscreteExteriorCalculus< dimEmbedded, TNSCellConstIterator::value_type::Point::dimension, TLinearAlgebraBackend, TInteger > DGtal::DiscreteExteriorCalculusFactory< TLinearAlgebraBackend, TInteger >::createFromNSCells ( const TNSCellConstIterator &  begin,
const TNSCellConstIterator &  end,
const TSCellMeasureFunctor &  normalFunctor,
const double  h,
const bool  add_border = true 
)
static

Create a DEC structure from a range of signed n-cells, where n is the embedded dimension. A functor from cell to its measure is given. Signed n-cells may live in an ambient Khamlisky space with dimension greater than n. N-cells get attached to primal n-cell <-> dual 0-cell. See section Introduction for more information.

Template Parameters
dimEmbeddeddimension of emmbedded manifold. All input n-cells must have their dimension equal to dimEmbedded.
TNSCellConstIteratorsigned cells collection const iterator type.
Parameters
beginbeginning of iteration range.
endend of iteration range.
normalFunctorfunctor from a cell to its normal
hthe grid step
add_borderadd border to the computed structure. For a precise definition see section Border definition.

◆ insertAllLowerIncidentCells()

template<typename TLinearAlgebraBackend , typename TInteger = DGtal::int32_t>
template<typename KSpace , typename CellsSet >
static void DGtal::DiscreteExteriorCalculusFactory< TLinearAlgebraBackend, TInteger >::insertAllLowerIncidentCells ( const KSpace kspace,
const typename CellsSet::value_type &  cell,
CellsSet &  cells_set 
)
staticprotected

Insert recursively all lower incident cells into cells set, starting from cell. Internal use only.

Template Parameters
KSpaceKhalimsky space type.
CellsSetcells set type, should be similar to std::set<KSpace::Cell> or std::set<KSpace::SCell>.
Parameters
kspaceKhalimsky space instance.
cellstarting cell.
cells_setcells set in which lower incident cells get inserted.

◆ operator=()

template<typename TLinearAlgebraBackend , typename TInteger = DGtal::int32_t>
DiscreteExteriorCalculusFactory & DGtal::DiscreteExteriorCalculusFactory< TLinearAlgebraBackend, TInteger >::operator= ( const DiscreteExteriorCalculusFactory< TLinearAlgebraBackend, TInteger > &  other)
private

Assignment.

Parameters
otherthe object to copy.
Returns
a reference on 'this'. Forbidden by default.

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