Home › Forum › SOFA › Using SOFA › [SOLVED] Creating models of Arteries and Veins with sofa
- This topic has 6 replies, 3 voices, and was last updated 6 years ago by
Wong.
-
AuthorPosts
-
13 July 2017 at 23:54 #9791
Garibalde
BlockedHow would i create an efficient stable model of arteries and veins in SOFA. Is there a special type of model to use. Tetrahedron models are too expensive. I have tried to use stiff spring linked together…however these have been unstable when constrained.
Any other suggestions or ideas?
Thanks
Vinay7 August 2017 at 18:35 #9909Hugo
KeymasterHi @vmenon,
To represent blood vessels:
- triangular surfaces are usually used when modeling endovascular catheter navigation, see this paper
- or beams when modeling the vessels as a mechanical structure, see this paper
For the first point, the centerline of vessels can be semi-automatically extracted from medical images, and the triangular mesh can be generated. A plugin will soon be available for licensing or research collaboration on the SOFA marketplace.
Hope this helps,Hugo
8 August 2017 at 17:30 #9911Garibalde
BlockedI was looking for a simple representation. I have used a simulated chain of spheres connected via JointSpringForceField to produce a representation of a segment or an artery or vein. I used SkinningMapping for the visual node. This seems to work in general however i do have stability issues at times when the end point of the segment are constrained.
So in summary this is my layout of the segment.
<MechanicalObject template=”Rigid” name=”DOFs” restScale=”1″ position=”Insert here positions”> <UniformMass template=”Rigid” name=”mass” mass=”1 1 [1 0 0,0 1 0,0 0 1]” /> <FixedConstraint template=”Rigid” name=”fixOrigin” indices=”0 10″ /> <UncoupledConstraintCorrection compliance=”0.01″/> <Node name=”Seg_Test_Vinay.subnode”> <MechanicalObject template=”Rigid” name=”attaches” restScale=”1″ position=”Insert here positions”> <RigidRigidMapping template=”MechanicalMapping<Rigid,Rigid>” name=”default6″ repartition=”1 2 2 2 2 2 2 2 2 2 1″ input=”@../DOFs” output=”@attaches”/> <JointSpringForceField template=”Rigid” name=”joints” spring=”Define spring between nodes”> <Node name=”Visu” tags=”Visual”> <OgreVisualModel name=”VisualModel” fileMesh=”mesh/Seg_Cut_Test.obj” /> <SkinningMapping name=”visual mapping” input=”@../../DOFs” output=”@VisualModel” /> </Node> <Node name=”Surf”> <SphereLoader filename=”mesh/Seg_Cut_Test.sph”/> <MechanicalObject name=”spheres” translation=”0.0 0.0 0.0″ rotation=”0.0 0.0 0.0″ position=”@[-1].position” /> <TSphereModel name=”CollisionModel” listRadius=”@[-2].listRadius” collisionBodyId=”96″/> <SkinningMapping name=”sphere mapping” input=”@../../DOFs” output=”@spheres” /> </Node>
Something like this would work for my use. I need it to be simple, computationally friendly and contactable (collision possible). Do you ahve something that is more efficient or better in SOFA currently that i could use?
Thanks
Vinay11 August 2017 at 17:53 #9914Hugo
KeymasterDid you take a look at the example : examples/Components/forcefield/BeamFEMForceField.scn ?
Hugo
31 August 2018 at 10:41 #11776Wong
BlockedHello @hugo,
1)I have read the paper and the paper mentions a mapping between a tetrahedron and a 6DoF-beam node. Does such a mapping exist in current Sofa version?2)I have read the BeamFEMForceField.scn and it runs fine. But when I add the FreeMotionAnimationLoop component into this scene, as shown below, the collision model behaves unnormally.
<Node name="root" dt="0.005"> <RequiredPlugin pluginName="SofaMiscCollision" /> <VisualStyle displayFlags="showBehaviorModels showForceFields showCollisionModels" /> <CollisionPipeline depth="6" verbose="0" draw="0" /> <BruteForceDetection name="N2" /> <CollisionResponse name="response" response="FrictionContact" /> <LocalMinDistance name="proximity" alarmDistance="0.15" contactDistance="0.05" angleCone="0.0" /> <FreeMotionAnimationLoop/> <LCPConstraintSolver tolerance="0.001" maxIt="1000"/> <!--<CollisionGroup name="Group" />--> <Node name="beam"> <EulerImplicit rayleighStiffness="0" printLog="false" rayleighMass="0.1" /> <BTDLinearSolver template="BTDMatrix6d" printLog="false" verbose="false" /> <MechanicalObject template="Rigid" name="DOFs" size="8" position="0 0 0 0 0 0 1 1 0 0 0 0 0 1 2 0 0 0 0 0 1 3 0 0 0 0 0 1 4 0 0 0 0 0 1 5 0 0 0 0 0 1 6 0 0 0 0 0 1 7 0 0 0 0 0 1" /> <Mesh name="lines" lines="0 1 1 2 2 3 3 4 4 5 5 6 6 7" /> <FixedConstraint name="FixedConstraint" indices="0" /> <UniformMass mass="1 1 0.01 0 0 0 0.1 0 0 0 0.1" printLog="false" /> <BeamFEMForceField name="FEM" radius="0.1" youngModulus="20000000" poissonRatio="0.49"/> <PrecomputedConstraintCorrection recompute="1"/> <Node name="Collision"> <!-- <CubeTopology nx="115" ny="4" nz="4" xmin="0" xmax="7" ymin="-0.1" ymax="0.1" zmin="-0.1" zmax="0.1" /> --> <CubeTopology nx="15" ny="2" nz="2" min="0 -0.1 -0.1" max="7 0.1 0.1" /> <MechanicalObject /> <BeamLinearMapping isMechanical="true" /> <Triangle /> </Node> </Node> </Node>
3) The blood vessel I want to represent is not an ordinary one. It is an artery with an aneurysm. So what is the best way to simulate such a blood vessel?
2 September 2018 at 21:31 #11794Hugo
KeymasterHi @outtt,
1) I guess the mapping used was the BarycentricMapping, but not being one of the authors, I can’t tell for sure
2) after a short investigation, it appears that the PrecomputedConstraintCorrection is responsible for the instability that you noticed. I am no expert from this code, but it seems the case recompute=”0″, is not really handled. Since you use a UniformMass (constant and diagonal mass matrix), I would rather go for a UncoupledConstraintCorrection
3) it depends on what you expect from your artery model. What is your targeted simulation?Best
Hugo
3 September 2018 at 04:11 #11800 -
AuthorPosts
- You must be logged in to reply to this topic.