OpenLB 1.7
Loading...
Searching...
No Matches
Public Member Functions | Protected Attributes | List of all members
olb::IndicElongation< S, D > Class Template Reference

#include <indicMod.h>

+ Inheritance diagram for olb::IndicElongation< S, D >:
+ Collaboration diagram for olb::IndicElongation< S, D >:

Public Member Functions

 IndicElongation (FunctorPtr< IndicatorF< S, D > > f, const Vector< S, D > &elongation=Vector< S, D >(0.))
 
void setElongation (const Vector< S, D > &elongation)
 
Vector< S, D > getElongation ()
 
Vector< S, D > getEstimatedCenter ()
 
signedDistance (const Vector< S, D > &input)
 

Protected Attributes

FunctorPtr< IndicatorF< S, D > > _f
 
Vector< S, D > _elongation
 

Detailed Description

template<typename S, unsigned D>
class olb::IndicElongation< S, D >

Definition at line 59 of file indicMod.h.

Constructor & Destructor Documentation

◆ IndicElongation()

template<typename S , unsigned D>
olb::IndicElongation< S, D >::IndicElongation ( FunctorPtr< IndicatorF< S, D > > f,
const Vector< S, D > & elongation = Vector<S,D>(0.) )

Definition at line 100 of file indicMod.hh.

101 : _f(std::move(f))
102{
103 setElongation(elongation);
104}
void setElongation(const Vector< S, D > &elongation)
Definition indicMod.hh:107
FunctorPtr< IndicatorF< S, D > > _f
Definition indicMod.h:61

References olb::IndicElongation< S, D >::setElongation().

+ Here is the call graph for this function:

Member Function Documentation

◆ getElongation()

template<typename S , unsigned D>
Vector< S, D > olb::IndicElongation< S, D >::getElongation ( )

Definition at line 115 of file indicMod.hh.

116{
117 return _elongation;
118}
Vector< S, D > _elongation
Definition indicMod.h:62

◆ getEstimatedCenter()

template<typename S , unsigned D>
Vector< S, D > olb::IndicElongation< S, D >::getEstimatedCenter ( )

Definition at line 121 of file indicMod.hh.

122{
123 return 0.5 * (_f->getMin() + _f->getMax());
124}

◆ setElongation()

template<typename S , unsigned D>
void olb::IndicElongation< S, D >::setElongation ( const Vector< S, D > & elongation)

Definition at line 107 of file indicMod.hh.

108{
110 this->_myMin = _f->getMin() - elongation;
111 this->_myMax = _f->getMax() + elongation;
112}
T elongation(std::function< T(const Vector< T, 3 > &)> sdf, const Vector< T, 3 > &p, const Vector< T, 3 > &h, const Vector< T, 3 > &center=(T(0))) any_platform
Elongation splits the object in 2 (4 or 8) parts, moves them apart and connects them again The object...
Definition sdf.h:386
+ Here is the caller graph for this function:

◆ signedDistance()

template<typename S , unsigned D>
S olb::IndicElongation< S, D >::signedDistance ( const Vector< S, D > & input)

Definition at line 127 of file indicMod.hh.

128{
129 std::function<S(const Vector<S, D>&)> sdf =
130 [this](const Vector<S, D>& input) {
131 return this->_f->signedDistance(input);
132 };
133
134 return sdf::elongation(sdf, input, _elongation, getEstimatedCenter());
135}
Vector< S, D > getEstimatedCenter()
Definition indicMod.hh:121

References olb::sdf::elongation().

+ Here is the call graph for this function:

Member Data Documentation

◆ _elongation

template<typename S , unsigned D>
Vector<S,D> olb::IndicElongation< S, D >::_elongation
protected

Definition at line 62 of file indicMod.h.

◆ _f

template<typename S , unsigned D>
FunctorPtr<IndicatorF<S, D> > olb::IndicElongation< S, D >::_f
protected

Definition at line 61 of file indicMod.h.


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