DGtal  1.3.beta
Public Types | Public Member Functions | Private Attributes
DGtal::functors::IICurvatureFunctor< TSpace > Struct Template Reference

Aim: A functor Real -> Real that returns the 2d curvature by transforming the given volume. This functor is valid only in 2D space. More...

#include <DGtal/geometry/surfaces/estimation/IIGeometricFunctors.h>

Public Types

typedef IICurvatureFunctor< TSpace > Self
 
typedef TSpace Space
 
typedef Space::RealVector RealVector
 
typedef RealVector::Component Component
 
typedef Component Argument
 
typedef Component Quantity
 
typedef Quantity Value
 

Public Member Functions

 BOOST_CONCEPT_ASSERT ((concepts::CSpace< TSpace >))
 
 BOOST_STATIC_ASSERT ((Space::dimension==2))
 
Value operator() (const Argument &arg) const
 
void init (Component h, Component r)
 

Private Attributes

Quantity dh2
 
Quantity d3_r
 
Quantity dPI_2
 
Quantity d1_r2
 

Detailed Description

template<typename TSpace>
struct DGtal::functors::IICurvatureFunctor< TSpace >

Aim: A functor Real -> Real that returns the 2d curvature by transforming the given volume. This functor is valid only in 2D space.

Description of template class 'IICurvatureFunctor'

Template Parameters
TSpacea model of CSpace, for instance SpaceND.
See also
IntegralInvariantVolumeEstimator

Definition at line 539 of file IIGeometricFunctors.h.

Member Typedef Documentation

◆ Argument

template<typename TSpace >
typedef Component DGtal::functors::IICurvatureFunctor< TSpace >::Argument

Definition at line 547 of file IIGeometricFunctors.h.

◆ Component

template<typename TSpace >
typedef RealVector::Component DGtal::functors::IICurvatureFunctor< TSpace >::Component

Definition at line 546 of file IIGeometricFunctors.h.

◆ Quantity

template<typename TSpace >
typedef Component DGtal::functors::IICurvatureFunctor< TSpace >::Quantity

Definition at line 548 of file IIGeometricFunctors.h.

◆ RealVector

template<typename TSpace >
typedef Space::RealVector DGtal::functors::IICurvatureFunctor< TSpace >::RealVector

Definition at line 545 of file IIGeometricFunctors.h.

◆ Self

template<typename TSpace >
typedef IICurvatureFunctor<TSpace> DGtal::functors::IICurvatureFunctor< TSpace >::Self

Definition at line 543 of file IIGeometricFunctors.h.

◆ Space

template<typename TSpace >
typedef TSpace DGtal::functors::IICurvatureFunctor< TSpace >::Space

Definition at line 544 of file IIGeometricFunctors.h.

◆ Value

template<typename TSpace >
typedef Quantity DGtal::functors::IICurvatureFunctor< TSpace >::Value

Definition at line 549 of file IIGeometricFunctors.h.

Member Function Documentation

◆ BOOST_CONCEPT_ASSERT()

template<typename TSpace >
DGtal::functors::IICurvatureFunctor< TSpace >::BOOST_CONCEPT_ASSERT ( (concepts::CSpace< TSpace >)  )

◆ BOOST_STATIC_ASSERT()

template<typename TSpace >
DGtal::functors::IICurvatureFunctor< TSpace >::BOOST_STATIC_ASSERT ( (Space::dimension==2)  )

◆ init()

template<typename TSpace >
void DGtal::functors::IICurvatureFunctor< TSpace >::init ( Component  h,
Component  r 
)
inline

Initializes the functor with the gridstep and the ball Euclidean radius.

Parameters
hthe gridstep
rthe ball radius

Definition at line 573 of file IIGeometricFunctors.h.

574  {
575  d1_r2 = 1.0 / ( r * r );
576  dPI_2 = M_PI / 2.0;
577  d3_r = 3.0 / r;
578  dh2 = h * h;
579  }

References DGtal::functors::IICurvatureFunctor< TSpace >::d1_r2, DGtal::functors::IICurvatureFunctor< TSpace >::d3_r, DGtal::functors::IICurvatureFunctor< TSpace >::dh2, and DGtal::functors::IICurvatureFunctor< TSpace >::dPI_2.

◆ operator()()

template<typename TSpace >
Value DGtal::functors::IICurvatureFunctor< TSpace >::operator() ( const Argument arg) const
inline

Apply operator.

Parameters
argany symmetric positive matrix (covariance matrix
Returns
the curvature associated with the II area measurement.

Definition at line 560 of file IIGeometricFunctors.h.

561  {
562  Quantity cp_quantity = arg;
563  cp_quantity *= dh2;
564  return d3_r * ( dPI_2 - d1_r2 * cp_quantity );
565  }

References DGtal::functors::IICurvatureFunctor< TSpace >::d1_r2, DGtal::functors::IICurvatureFunctor< TSpace >::d3_r, DGtal::functors::IICurvatureFunctor< TSpace >::dh2, and DGtal::functors::IICurvatureFunctor< TSpace >::dPI_2.

Field Documentation

◆ d1_r2

template<typename TSpace >
Quantity DGtal::functors::IICurvatureFunctor< TSpace >::d1_r2
private

◆ d3_r

template<typename TSpace >
Quantity DGtal::functors::IICurvatureFunctor< TSpace >::d3_r
private

◆ dh2

template<typename TSpace >
Quantity DGtal::functors::IICurvatureFunctor< TSpace >::dh2
private

◆ dPI_2

template<typename TSpace >
Quantity DGtal::functors::IICurvatureFunctor< TSpace >::dPI_2
private

The documentation for this struct was generated from the following file:
DGtal::functors::IICurvatureFunctor::dh2
Quantity dh2
Definition: IIGeometricFunctors.h:582
DGtal::functors::IICurvatureFunctor::d3_r
Quantity d3_r
Definition: IIGeometricFunctors.h:583
DGtal::functors::IICurvatureFunctor::Quantity
Component Quantity
Definition: IIGeometricFunctors.h:548
DGtal::functors::IICurvatureFunctor::d1_r2
Quantity d1_r2
Definition: IIGeometricFunctors.h:585
DGtal::functors::IICurvatureFunctor::dPI_2
Quantity dPI_2
Definition: IIGeometricFunctors.h:584