Challenges meshing: Number of Nodes: 0
- Kimberly Stevens
- Posts: 15
- Joined: Mon Dec 03, 2018 12:06 pm
Challenges meshing: Number of Nodes: 0
Hello,
I'm trying to mesh a geometry from an .stl I created in MATLAB, but no matter how much I remesh, smooth, etc. I get the intersecting facet error unless I go to an extremely small mesh size (yields 12 million elements). When I do the Advanced Meshing option to check for intersecting facets, it finds the intersecting facets (usually tens to hundreds) and then SimVascular closes with no warning. I imported the geometry into ITK-Snap, segmented it, and exported the segmentation as an .stl and it seems to behave better, but when I mesh it produces a mesh with 0 elements, 0 nodes, and 0 facets with no error message I can see. The output is below. I uploaded what files I could, but the stl output from ITKSnap was too large to upload. I can email if that would be helpful.
Thanks,
Kim
Remeshing surface with MMG...
-- MMGS, Release 5.3.8 (Apr. 10, 2017)
Copyright (c) IMB-LJLL, 2004-
Dec 1 2019 01:11:48
-- MMGS: INPUT DATA
-- INPUT DATA COMPLETED. 0.000s
&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&
MODULE MMGS: IMB-LJLL : 5.3.8 (Apr. 10, 2017)
&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&
-- PHASE 1 : ANALYSIS
-- MESH QUALITY 346182
BEST 1.000000 AVRG. 0.927257 WRST. 0.000001 (282931)
-- PHASE 1 COMPLETED. 0.000s
-- PHASE 2 : ISOTROPIC MESHING
191 splitted, 151356 collapsed, 12071 swapped, 5 iter.
-- GRADATION : 1.300000
2 splitted, 0 collapsed, 3 swapped, 2 iter.
2381 splitted, 8327 collapsed, 3169 swapped, 335262 moved, 2 iter.
-- PHASE 2 COMPLETED. 2.000s
&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&
END OF MODULE MMGS: IMB-LJLL
&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&
-- MESH QUALITY 31774
BEST 0.999997 AVRG. 0.940584 WRST. 0.000002 (9892)
-- MESH PACKED UP
NUMBER OF VERTICES 15890 CORNERS 561
NUMBER OF TRIANGLES 31774
NUMBER OF EDGES 1149 RIDGES 1149
MMGSLIB: ELAPSED TIME 2.000s
Checking surface mesh
Regions: 1
Number of Free Edges on Surface: 766
Number of Non-Manifold Edges on Surface: 0
Iteration 1/10
Iteration 2/10
Iteration 3/10
Iteration 4/10
Iteration 5/10
Iteration 6/10
Iteration 7/10
Iteration 8/10
Iteration 9/10
Iteration 10/10
Final mesh improvement
Converting to TetGen...
Adding Facet Markers...
TetGen Meshing Started...
Delaunizing vertices...
Delaunay seconds: 0.097
Creating surface mesh ...
Surface mesh seconds: 0.042
Recovering boundaries...
Boundary recovery seconds: 0.077
Removing exterior tetrahedra ...
Exterior tets removal seconds: 0.033
Recovering Delaunayness...
Delaunay recovery seconds: 0.004
Refining mesh...
Refinement seconds: 0.002
Optimizing mesh...
Optimization seconds: 0.002
Jettisoning redundant points.
Writing nodes.
Writing edges.
Writing neighbors.
Output seconds: 0.013
Total running seconds: 0.274
Statistics:
Input points: 15588
Input facets: 31171
Input holes: 0
Input regions: 0
Mesh points: 0
Mesh tetrahedra: 0
Mesh faces: 0
Mesh faces on facets: 0
Mesh edges on segments: 0
TetGen Meshing Finished...
I'm trying to mesh a geometry from an .stl I created in MATLAB, but no matter how much I remesh, smooth, etc. I get the intersecting facet error unless I go to an extremely small mesh size (yields 12 million elements). When I do the Advanced Meshing option to check for intersecting facets, it finds the intersecting facets (usually tens to hundreds) and then SimVascular closes with no warning. I imported the geometry into ITK-Snap, segmented it, and exported the segmentation as an .stl and it seems to behave better, but when I mesh it produces a mesh with 0 elements, 0 nodes, and 0 facets with no error message I can see. The output is below. I uploaded what files I could, but the stl output from ITKSnap was too large to upload. I can email if that would be helpful.
Thanks,
Kim
Remeshing surface with MMG...
-- MMGS, Release 5.3.8 (Apr. 10, 2017)
Copyright (c) IMB-LJLL, 2004-
Dec 1 2019 01:11:48
-- MMGS: INPUT DATA
-- INPUT DATA COMPLETED. 0.000s
&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&
MODULE MMGS: IMB-LJLL : 5.3.8 (Apr. 10, 2017)
&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&
-- PHASE 1 : ANALYSIS
-- MESH QUALITY 346182
BEST 1.000000 AVRG. 0.927257 WRST. 0.000001 (282931)
-- PHASE 1 COMPLETED. 0.000s
-- PHASE 2 : ISOTROPIC MESHING
191 splitted, 151356 collapsed, 12071 swapped, 5 iter.
-- GRADATION : 1.300000
2 splitted, 0 collapsed, 3 swapped, 2 iter.
2381 splitted, 8327 collapsed, 3169 swapped, 335262 moved, 2 iter.
-- PHASE 2 COMPLETED. 2.000s
&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&
END OF MODULE MMGS: IMB-LJLL
&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&
-- MESH QUALITY 31774
BEST 0.999997 AVRG. 0.940584 WRST. 0.000002 (9892)
-- MESH PACKED UP
NUMBER OF VERTICES 15890 CORNERS 561
NUMBER OF TRIANGLES 31774
NUMBER OF EDGES 1149 RIDGES 1149
MMGSLIB: ELAPSED TIME 2.000s
Checking surface mesh
Regions: 1
Number of Free Edges on Surface: 766
Number of Non-Manifold Edges on Surface: 0
Iteration 1/10
Iteration 2/10
Iteration 3/10
Iteration 4/10
Iteration 5/10
Iteration 6/10
Iteration 7/10
Iteration 8/10
Iteration 9/10
Iteration 10/10
Final mesh improvement
Converting to TetGen...
Adding Facet Markers...
TetGen Meshing Started...
Delaunizing vertices...
Delaunay seconds: 0.097
Creating surface mesh ...
Surface mesh seconds: 0.042
Recovering boundaries...
Boundary recovery seconds: 0.077
Removing exterior tetrahedra ...
Exterior tets removal seconds: 0.033
Recovering Delaunayness...
Delaunay recovery seconds: 0.004
Refining mesh...
Refinement seconds: 0.002
Optimizing mesh...
Optimization seconds: 0.002
Jettisoning redundant points.
Writing nodes.
Writing edges.
Writing neighbors.
Output seconds: 0.013
Total running seconds: 0.274
Statistics:
Input points: 15588
Input facets: 31171
Input holes: 0
Input regions: 0
Mesh points: 0
Mesh tetrahedra: 0
Mesh faces: 0
Mesh faces on facets: 0
Mesh edges on segments: 0
TetGen Meshing Finished...
- Attachments
-
- Models_fromMatlab.zip
- The models I created in SimVascular after importing the .stl
- (540.73 KiB) Downloaded 7 times
-
- Meshes.zip
- Output from Meshing with 0 Nodes, etc
- (1.84 KiB) Downloaded 4 times
- David Parker
- Posts: 1677
- Joined: Tue Aug 23, 2005 2:43 pm
Re: Challenges meshing: Number of Nodes: 0
Hi Kim,
Your MATLAB model is not smooth, contains many ridges. The mesh generator will try to mesh each of these ridges which is something you don't want to do. The mesh generator is failing most likely by the poor triangulation of the caps.
I had hoped that you could remesh the model with a large edge size but that did not work, SV does not seem to correctly resample the model surface.
Upload your ITK-Snap model someplace I can download it and I'll have a look.
Cheers,
Dave
Your MATLAB model is not smooth, contains many ridges. The mesh generator will try to mesh each of these ridges which is something you don't want to do. The mesh generator is failing most likely by the poor triangulation of the caps.
I had hoped that you could remesh the model with a large edge size but that did not work, SV does not seem to correctly resample the model surface.
Upload your ITK-Snap model someplace I can download it and I'll have a look.
Cheers,
Dave
- Ilham Essafri
- Posts: 4
- Joined: Sat May 07, 2022 12:44 pm
Re: Challenges meshing: Number of Nodes: 0
Hi David,
I am having the same issue, can you please advise me how can I fix this issue ? Thank you.
Kind regards,
Ilham
I am having the same issue, can you please advise me how can I fix this issue ? Thank you.
Kind regards,
Ilham
- David Parker
- Posts: 1677
- Joined: Tue Aug 23, 2005 2:43 pm
Re: Challenges meshing: Number of Nodes: 0
Hi Ilham,
It can be challenging to create a model that is good enough for meshing. Note that even in industry meshing a CAD model for CFD often takes a significant amount of time.
Put your model someplace I can download and I'll have a look.
Cheers,
Dave
It can be challenging to create a model that is good enough for meshing. Note that even in industry meshing a CAD model for CFD often takes a significant amount of time.
Put your model someplace I can download and I'll have a look.
Cheers,
Dave
- Ilham Essafri
- Posts: 4
- Joined: Sat May 07, 2022 12:44 pm
Re: Challenges meshing: Number of Nodes: 0
Hello David,
Thank you for your response. It is indeed difficult to identify the specific solid model elements that are causing errors or occasionally preventing SimVascular from creating meshes.
Please follow the link to my Solid Model below. Let me know if you require any additional files.
My models are also created from a Matlab code that segments and generated the solid model from a series of Tif images.
The link:
https://drive.google.com/file/d/18QhqHm ... sp=sharing
Best regards,
Ilham
Thank you for your response. It is indeed difficult to identify the specific solid model elements that are causing errors or occasionally preventing SimVascular from creating meshes.
Please follow the link to my Solid Model below. Let me know if you require any additional files.
My models are also created from a Matlab code that segments and generated the solid model from a series of Tif images.
The link:
https://drive.google.com/file/d/18QhqHm ... sp=sharing
Best regards,
Ilham
- David Parker
- Posts: 1677
- Joined: Tue Aug 23, 2005 2:43 pm
Re: Challenges meshing: Number of Nodes: 0
Hi Ilham,
I had a look at your model. Most of the caps look OK but cap #9 has some features at the edges that could cause problems when meshing.
The model needs to have a well-defined surface: triangles of about the same size with a large aspect ration. Small features (long thin triangles) will cause the meshing to fail.
You might could clean up your model using the MeshMixer program.
Cheers,
Dave
I had a look at your model. Most of the caps look OK but cap #9 has some features at the edges that could cause problems when meshing.
The model needs to have a well-defined surface: triangles of about the same size with a large aspect ration. Small features (long thin triangles) will cause the meshing to fail.
You might could clean up your model using the MeshMixer program.
Cheers,
Dave
- Ilham Essafri
- Posts: 4
- Joined: Sat May 07, 2022 12:44 pm
Re: Challenges meshing: Number of Nodes: 0
Hi David,
Thank you for your help; I just tried the Meshmixer as you suggested and correct everything and that works ! I was able to generate the meshes.
Thank you.
Best;
Ilham
Thank you for your help; I just tried the Meshmixer as you suggested and correct everything and that works ! I was able to generate the meshes.
Thank you.
Best;
Ilham
- David Parker
- Posts: 1677
- Joined: Tue Aug 23, 2005 2:43 pm
Re: Challenges meshing: Number of Nodes: 0
Hi Ilham,
Good job!
Please post here what you did in MeshMixer so other users can see how they might fix their meshes.
Cheers,
Dave
Good job!
Please post here what you did in MeshMixer so other users can see how they might fix their meshes.
Cheers,
Dave
- Ilham Essafri
- Posts: 4
- Joined: Sat May 07, 2022 12:44 pm
Re: Challenges meshing: Number of Nodes: 0
Hi David,
Sure, here are the steps I took in the MeshMixer.
Steps:
1. Load solid model to Meshmixer, View -> show wireframe, to visualize the triangles on your surface)
2. Analysis -> Inspector (will highlight all the imperfections) -> Auto Repair All (with Flat fill mode) -> click on "DONE"
3. Ctrl+A (select all) -> Edit -> Remesh -> Remesh Mode (Adaptive density); Density (Adjust it as you desire); select smooth Group Boundaries; Boundary Mode (Fixed Boundary); click on "ACCEPT"
4. Convert to -> Convert to solid part -> No preference -> click on "ACCEPT"
Export the mesh file.
Hope that will help.
Best,
Ilham
Sure, here are the steps I took in the MeshMixer.
Steps:
1. Load solid model to Meshmixer, View -> show wireframe, to visualize the triangles on your surface)
2. Analysis -> Inspector (will highlight all the imperfections) -> Auto Repair All (with Flat fill mode) -> click on "DONE"
3. Ctrl+A (select all) -> Edit -> Remesh -> Remesh Mode (Adaptive density); Density (Adjust it as you desire); select smooth Group Boundaries; Boundary Mode (Fixed Boundary); click on "ACCEPT"
4. Convert to -> Convert to solid part -> No preference -> click on "ACCEPT"
Export the mesh file.
Hope that will help.
Best,
Ilham
- David Parker
- Posts: 1677
- Joined: Tue Aug 23, 2005 2:43 pm
Re: Challenges meshing: Number of Nodes: 0
Hi Ilham,
Thanks for posting the MeshMixer steps you took to correct a mesh. I'm sure this will be useful to other users.
Cheers,
Dave
Thanks for posting the MeshMixer steps you took to correct a mesh. I'm sure this will be useful to other users.
Cheers,
Dave