19 #ifndef itkFEMLoadLandmark_h
20 #define itkFEMLoadLandmark_h
23 #include "ITKFEMExport.h"
25 #include "vnl/vnl_vector.h"
50 itkSimpleNewMacro(
Self);
57 virtual::itk::LightObject::Pointer CreateAnother(
void) const ITK_OVERRIDE;
72 return m_Solution->GetSolutionValue(i, v);
123 if( m_Force.size() != force.size() )
125 m_Force.set_size( force.size() );
127 for(
unsigned int i = 0; i < force.size(); i++ )
129 m_Force[i] = force[i];
139 if( m_Source.size() != source.size() )
141 m_Source.set_size( source.size() );
143 for(
unsigned int i = 0; i < source.size(); i++ )
145 m_Source[i] = source[i];
168 if( m_Target.size() != target.size() )
170 m_Target.set_size( target.size() );
172 for(
unsigned int i = 0; i < target.size(); i++ )
174 m_Target[i] = target[i];
181 for(
unsigned int i = 0; i < m_Target.size(); i++ )
183 m_Target[i] /= spacing[i];
184 m_Source[i] /= spacing[i];
194 this->m_Element[0] =
e;
202 return this->m_Element[0];
222 m_Solution(ITK_NULLPTR)
227 void SetEta(
double e);
229 double GetEta()
const;
236 virtual void PrintSelf(std::ostream& os,
Indent indent)
const ITK_OVERRIDE;
272 #endif // #ifndef itkFEMLoadLandmark_h
Light weight base class for most itk classes.
Element::VectorType & GetTarget()
virtual Solution::ConstPointer GetSolution() override
vnl_vector< Float > m_Point
void SetSource(const vnl_vector< Float > &source)
void ScalePointAndForce(double *spacing, double fwt)
vnl_vector< Float > m_Force
Element::VectorType & GetPoint()
Provides functions to access the values of the solution vector.
This load is derived from the motion of a specific landmark.
Float GetSolution(unsigned int i, unsigned int v=0)
Solution::ConstPointer m_Solution
vnl_vector< Float > VectorType
Virtual element load base class.
void SetTarget(const vnl_vector< Float > &target)
void SetContainedElement(const Element *e)
void SetPoint(const vnl_vector< Float > &pt)
const Element::VectorType & GetTarget() const
Abstract base element class.
void SetForce(const vnl_vector< Float > &force)
vnl_vector< Float > m_Source
SmartPointer< Self > Pointer
Element::VectorType & GetSource()
Control indentation during Print() invocation.
const Element * GetContainedElement() const
SmartPointer< const Self > ConstPointer
vnl_vector< Float > m_Target
static ITK_CONSTEXPR_VAR double e
The base of the natural logarithm or Euler's number
const Element::VectorType & GetSource() const
const Element::VectorType & GetForce() const
Element::VectorType & GetForce()