Forum Replies Created
-
AuthorPosts
-
HugoKeymasterHugoKeymaster
hey @eaparra
When you do a sudo apt-get install, it really installs the software, so no need to compile cgal here.
I forgot to ask which version of SOFA are you using?
(I will reply to you tomorrow!)Best
Hugo
14 April 2020 at 22:35 in reply to: [SOLVED] Using beams when modeling the vessels as a mechanical structure #15756HugoKeymasterHi @matfit
What role should actually have the aorta part (if it is fixed)?
To get back (down) to the kidney, I would recommend the approach followed by Peterlik et al. in Modeling and real-time simulation of a vascularized liver tissue.
The method consists in having a 3D volumetric model for the kidney tissue mechanics, and a Beam 1D linear model for the blood vessels. The latter must actually be a child node of the former, in order to “rigidify” the volumetric model due to the presence of blood flow.Note that if bifurcation occurs, then each vessel section must be modeled separately and joint using a BilateralInteractionConstraint.
For your information, some people in the community worked on building beam hierarchy from medical images (from image to 3D model, then extracting centerlines and apply a mechanical model to it). If it is from interest, I can gather some further info.
I hope this helps.
Best,Hugo
HugoKeymasterHi @nicklj
I needed to look twice at your scene, but the problem is rather simple.
The rigid frame of your ProblemPotato (thanks for the nice names 😉 ) is no centered and even outside the potato itself! Take a look:
(see the left handside frame)So, when collision occurs, then, forces are applied on the collision model. The mapping projects these forces back to the rigid frame. But since this frame is not centered, and outside the ProblemPotato, it creates a momentum.
Best,
Hugo
HugoKeymasterhey @eaparra
What do you mean by”I could not find the CGAL”? Was the command
sudo apt-get install libcgal-dev
not working?The official webpage of CGAL should be the best help.
We have several CGAL (and SOFA-CGAL) users. No worries, we’ll make it work.Hugo
14 April 2020 at 20:58 in reply to: [SOLVED] Using beams when modeling the vessels as a mechanical structure #15751HugoKeymasterHi @matfit
If I understand you correctly you want to model a part of the arterial system: from the aorta to the kidney. Is it correct?
Let me know so that I can make a complete reply.Best
Hugo
HugoKeymasterThanks @damien-marchaluniv-lille1-fr and @roland-dreyfus !
Let’s see if @faichele can also provide us some updates about the plugin.Otherwise Python option looks nice!
BestHugo
13 April 2020 at 22:21 in reply to: [SOLVED] Using beams when modeling the vessels as a mechanical structure #15704HugoKeymasterDear @enxing,
I am sorry the forum spam detector blocked some of your posts. Could you please sharing your files again (if you did). Thanks.
1. To use the mesh vessel.stl that you created, you need first to load it in the scene using a MeshSTLLoader, then to share the topology in a EdgeSetTopologyContainer in the same node where your BeamFEMForceField is defined.
2. No. But if you blood vessel has bifurcations, this will make things a bit more complicated.
3. Not at my best knowledge.
4. Take a look at the associated documentation.Best wishes,
Hugo
HugoKeymasterHi @weibayang
1. I am sorry I do not understand the problem. Could you describe in more detail what you are aiming at and the problem you are facing, please?
2. Indices corresponds to the point Ids in each MechanicalObject that you want to attach. Point Ids can be made visible by activating the data showIndices (and adapting the data showIndicesScale) in the MechanicalObject. This will make point ids appear.
3. you can find an example in SOFA/examples/Components/constraint/AttachConstraint.scn
I hope this helps.
Best wishes,Hugo
HugoKeymasterHi @simon
Do it in the bwdInitGraph() Python function within the same file.
FYI all Python functions are displayed in the applications/plugins/SofaPython/examples/EmptyController.py exampleBest wishes,
Hugo
HugoKeymasterHi @simon
This is due to the fact you are calling the data before it is actually initialized.
The createScene() function is called before initialization to define what components are inside the graph. Then, initialization occurs and the simulation can be run.
If you call the same
findData('indices').value
orbox.indices
in the function onBeginAnimationStep() it will work fine.Best wishes,
Hugo
HugoKeymasterHi @eaparra
I answer your very last post.
Which version of CGAL did you use? and which version of SOFA?
Did the CGAL installation notice you that it was successful?
Before doing the make, what was the output of the configure and generate steps?Best.
Hugo
HugoKeymasterI am not familiar with Fabian’s code.
But this file clearly does not appear to be here.This must be an error. @faichele, do you confirm?
In the meantime @roland-dreyfus, comment the associated lines in the CMakeLists file. Could you let me know how it runs?
Best,
Hugo
HugoKeymasterHi @weibayang
Sorry if I made it unclear:
– anisotropic hyperelastic material on tetrahedra using the FEM exists in SOFA
– however, anisotropic elastic material on tetrahedra does not exist in the core of SOFA, only isotropic version exists.Regarding your point about the topology, the way we are usually handling 3D models in SOFA is the following:
– a loader, loading a 3D mesh from a file
– a SetTopologyContainer (Triangle/Tetrahedron/…) is the component in the scene getting all topological information, storing it for other components in the scenes (e.g. for FEM computation).I hope this helps.
Best,Hugo
4 April 2020 at 01:20 in reply to: [SOLVED] Insert Strain – Stress Curves of Material to describe mechanical properties #15644HugoKeymasterShall we close the topic @pasquale94 ?
Hugo
4 April 2020 at 01:12 in reply to: [SOLVED] BilateralInteractionConstraint reduces gravity by 100x #15643HugoKeymasterDear @joshuaf
Sorry for the delay of this reply. Your question got me stuck for some time and I needed to get to some constraint resolution experts. They actually did not get why at a first glance the forces were not balancing the gravity acceleration.
I think I just found the point.
In the UncoupledConstraintCorrection, it exist (in a galaxy far far away) a data named “useOdeSolverIntegrationFactors“. This data allows to use as factor to apply the corrective motion (coming from the lamda multipliers, solution of the constraint problem) either:
* (default) the correctionVelocityFactor and correctionPositionFactor (two other data in the UncoupledConstraintCorrection) –>
useOdeSolverIntegrationFactors=0
* the integration factors of the ODE solver (EulerImplicitSolver in your case) –>useOdeSolverIntegrationFactors=1
On the other hand, the LinearSolverConstraintCorrection offers only one solution for applying the corrective motion: it is using the integration factors of the ODE solver. Therefore, if you do not specify the data
useOdeSolverIntegrationFactors=1
in your UncoupledConstraintCorrection, the constraints won’t be applied in the same way on the rigid () and the deformable object.Your fix: just setting the data to true in the UncoupledConstraintCorrection.
Damned! all this just for a flag. I will investigate more what is the interest of using correctionVelocityFactor and correctionPositionFactor, provided by the user.
Best,Hugo
HugoKeymasterHi @eaparra
Do you get an error?
Could you share it with us?
Can you see where GMP and MPRF were installed?Best
Hugo
HugoKeymasterGreat to hear it solved your issue. I therefore close the topic!
Best wishes,Hugo
HugoKeymasterHi @weibayang
You are very welcome.
1. I am sorry I am not sure to understand your point.
2. In a scene, different models exist in SOFA. Each model is implemented in a different C++ class. Changing a FEMForceField component in the scene will therefore change the material: e.g. TetrahedronFEMForceField for linear elasticity and linearized strain, TetrahedronHyperelasticityFEMForceField for several hyperelastic models, StiffSpringForceField for a spring model, etc.In the case of the TetrahedronHyperelasticityFEMForceField, you can select the material as you can see in the example: examples/Components/forcefield/TetrahedronHyperelasticityFEMForceField.scn for instance:
<TetrahedronHyperelasticityFEMForceField name="FEM" ParameterSet="3448.2759 31034.483" materialName="StVenantKirchhoff"/>
where the first value of the data
ParameterSet
is mu and the second is lambda, the two Lamé’s coefficient.3. Bounding boxes in SOFA allows to select point as you want: see the orientedBox data in the example examples/Components/engine/BoxROI.scn
4. for the documentation, unfortunately, we are working every day on it but all is here.
Note that for the API description a full doxygen is available here.
Video tutorials are provided here.I hope this helps.
Hugo
1 April 2020 at 13:56 in reply to: [SOLVED] Geomagic plugin: Problem with reading position in cpp #15620HugoKeymasterOk! oO
Thanks for sharing your solution @bobiko!
I close the topic for now. Do not hesitate to reopen it if necessary!Good job!
HugoKeymasterLatest update @priya-vada4 : got a confirmation, updating XCode to its latest version should work. Let us know if it solves your case.
Best wishes,
Hugo
31 March 2020 at 19:08 in reply to: [SOLVED] Geomagic plugin: Problem with reading position in cpp #15611HugoKeymastercould you tell us what are your cmake and XCode versions please?
Hugo
-
AuthorPosts