Mesh quality ideas needed
4 Attachment(s)
Hi foamers,
Recently i was trying to mesh a car stl file using sHM. But it resulted in a mesh which looks pretty bad. I do not know the reason my mesh turned out like this. When i used 'checkMesh' it showed me that the mesh it OK. But I have attached some pictures with this thread. Please take a look and comment the reason for getting such a mesh. I was wondering if this is a problem with my stl file because i was not able to get a perfect square cell near the surface of the car. My checkmesh showed the following results. Code:
Create time Thanks Vicky |
Hi Vicky,
There are a couple of things that might cause this: - When you view the mesh in paraview it can have issues dealing with polyhedron cells by default. There is a box you can tick that will help with the rendering: 'use VTKpolyhedron' underneath 'update GUI'. -It also seems like the prism layers that you have added are very thin compared to the size of the cells close to the boundary; how are you defining them in the 'add layers' part of the SHM dict? -Also, the checkMesh is highlighting 292 cells which are severely non-orthogonal (probably relating to the cells on the boundary). Play around with the 'add layers' parameters, such as reducing the number of layers and making them larger, to see if you get a more sensible mesh. Charlie |
Hi Charlie,
Thank you for your reply. The mesh images that i posted are the ones where i tried to add layers. This might be the problem. My stl file is a 3d model of a car. But I was trying to do a 2D simulation from that. My idea was to do a sHM on the model and then finally do an extrudeMesh to convert that to a 2D mesh. In my blockmesh file i tried to choose a domain of thickness 0.1m. In this domain of 0.1m the model is not protruded straight but has an angle. This might be the reason why i got the problem on the interface between the surface and the mesh. Even if i add layers that is not properly applied on the surface. Can you suggest me a method to do a 2D simulation of that without this problem? Thanks |
Charlie,
As you suggested i tried to modify the layers to eliminate the non orthogonal faces. But first i switched off the add layers option in the beginning. Even then the number of orthogonal faces did not seem to decrease. Is there any reason behind it. Thanks |
The issue is likely due to how you are creating the '2D' slice - if there is variation in the third direction then the case isn't 2D and it sounds like that is the case. I recommend using a CAD package (SALOME might be able to do this) to take a slice through the car .stl file and then extruding that surface and saving it as a separate .stl.
There may be other ways to treat the CAD file using Snappy/blockMesh but I have not come across it myself! Keep the 'add layers' function disabled for now until you can get a decent quality surface mesh. Hope that helps! |
Hi Vickky,
I have just checked the CAD method in SALOME and it is fairly straight forward to create a 2D slice from and stl and then extrude it. SALOME is worth learning if you don't have access to commercial CAD software. |
Charlie,
I will look into salome but are there are any learning materials available for that specifically. And i wanted to tell that i increased the Max orthogonal value in the mesh quality control to 180 so that the sHM will ignore the non ortho faces and try to add layers. While doing that i was able to add layers and improve the mesh. I do not know if this is right. Thanks Vicky |
1 Attachment(s)
Quote:
Attachment 60065 |
All times are GMT -4. The time now is 10:15. |