33 #ifndef __usNeedleInsertionModelRayleighRitzSpline_h
34 #define __usNeedleInsertionModelRayleighRitzSpline_h
39 #include <visp3/core/vpColVector.h>
40 #include <visp3/core/vpHomogeneousMatrix.h>
41 #include <visp3/core/vpImage.h>
43 #include <visp3/ustk_needle_modeling/usNeedleTip.h>
44 #include <visp3/ustk_needle_modeling/usNeedleTipActuated.h>
45 #include <visp3/ustk_needle_modeling/usNeedleTipBeveled.h>
46 #include <visp3/ustk_needle_modeling/usNeedleTipPrebent.h>
47 #include <visp3/ustk_needle_modeling/usNeedleTipSymmetric.h>
49 #include <visp3/ustk_needle_modeling/usNeedleInsertionModelInterface.h>
50 #include <visp3/ustk_needle_modeling/usNeedleModelSpline.h>
51 #include <visp3/ustk_needle_modeling/usTissueModelSpline.h>
61 MisraRSRO10_PlastisolA,
69 enum class PathUpdateType : int { NoUpdate, WithTipPosition, WithTipDirection, WithTipMix };
70 enum class NeedleTipType : int { SymmetricTip, BeveledTip, PrebentTip, ActuatedTip };
135 bool addTissueLayer(
double K,
double l);
137 bool setStiffnessPerUnitLength(
int i,
double K);
138 bool setStiffnessPerUnitLength(
double K);
139 double getStiffnessPerUnitLength(
int i = 0)
const;
141 bool setLayerLength(
int i,
double l);
142 double getLayerLength(
int i)
const;
144 int getNbLayers()
const;
145 int getNbCurrentLayers()
const;
150 void setPathUpdateLengthThreshold(
double length);
151 void setPathUpdateMixCoefficient(
double coef);
158 bool IsNeedleInserted()
const;
159 double getNeedleFreeLength(
int *seg =
nullptr,
double *param =
nullptr)
const;
160 double getInsertionDepth()
const;
161 vpColVector getNeedleInsertionPoint()
const;
162 vpColVector getTissueInsertionPoint()
const;
164 bool getCorrespondingPathPoint(
double l,
int &correspondingRestIndex,
double &correspondingRestParam)
const;
170 double getTissueDeformationEnergy()
const;
171 double getSurfaceTissueStretch()
const;
172 double getMaxTissueStretch(
double *lmax =
nullptr)
const;
173 double getMeanTissueStretch()
const;
187 void setSurfaceAtTip();
188 bool cutPathToPoint(
const vpColVector &P);
192 void solveSegmentsParametersSparseEigen();
194 void solveSegmentsParametersFullSparseEigen();
196 void solveSegmentsParametersFullSparseEigenFixedLength();
197 void solveSegmentsParametersDense();
200 void updateTipPose();
202 void solveSegmentsParameters();
203 virtual bool updateState();
virtual bool setBasePose(const vpPoseVector &pose)=0
The following methods should be redefined in the derived classes.
virtual vpPoseVector getBasePose() const =0
std::vector< double > m_stiffnessPerUnitLength
usTissueModelSpline m_tissue
Tissue.
usNeedleTip * m_needleTip
double m_pathUpdateLengthThreshold
usNeedleModelSpline m_needle
Model Parameters.
double m_pathUpdateMixCoefficient
PathUpdateType m_pathUpdateType
Path update.
SolvingMethod m_solvingMethod
Internal.
std::vector< double > m_layerLength
NeedleTipType m_needleTipType
std::vector< double > m_restDilatationFactor
double getCurvatureFromKinematics() const
Curvature.