CFD Online Discussion Forums

CFD Online Discussion Forums (https://www.cfd-online.com/Forums/)
-   OpenFOAM Meshing & Mesh Conversion (https://www.cfd-online.com/Forums/openfoam-meshing/)
-   -   [mesh manipulation] How to create patch after snappyHexMesh? (https://www.cfd-online.com/Forums/openfoam-meshing/231615-how-create-patch-after-snappyhexmesh.html)

sunagra27 November 11, 2020 23:37

How to create patch after snappyHexMesh?
 
2 Attachment(s)
Dear All,


I have a sphere created using snappyHexmesh, Now, I am trying to create a cylinder which has a inlet from sphere base and outlet inside the sphere. I am trying to create this using topoSet and createPatchDict. The cylinder is entered into snappyHexMeshDict using stl file.


The problem I am facing here is that once the snappyHexMesh is created after blockMesh, I am getting a cut in the portion of the cylinder inlet which can be seen clearly in the sphere base. I have attached the image for reference. I need that cut portion as closed and use as inlet for cylinder.


How do I get the cut portion as inlet using topoSet..? All I am getting is the surrounding wall as inlet. I have attached the photo for reference.


Image: Inlet_for_cylinder: You can see that after snappyHexMesh for cylinder, the portion is cut, where I need it as a patch for inlet.



Attachment 81025






Image: Inlet after topoSet: After using topoSet, I am getting inlet as the surrounding wall. How to get the cut portion as inlet..?





Attachment 81026




Any leads will be helpful,


Regards,


Sunag R A.

otaolafr November 14, 2020 15:02

1 Attachment(s)
hello,

from what i get, you want to study the following geometry:
a demi sphere that has a small cylinder interesected to it, and you want the flat face of the cylinder as the inlet to the geometry?

either way, if I understood you correctly and thats what you want,
I would recommend using salome to define the different boundaries by groups, then creating surface mesh for the complete body and then it will inherit the groups faces from the geometry to the surface mesh and then export each mesh separatly in a stl.
then you combine all the stls with:
cat *.stl >> combined.stl (command in bash that will combine all the different stls in the current folder)

and then you will have a stl with boundaries pre defined! so you can use it in snappyHex :)

i addded a attached study from salome with a similar geometry to the one you want so you have a base, also here you have a complete guide from tobias https://www.youtube.com/watch?v=_uom_JPs45I

Attachment 81061

sunagra27 November 25, 2020 00:53

Dear Franco,


Thank you very much for the suggestion and the example file.


With respect to salome, I did download from the salome platform and try to run after extraction. I am getting an error related to libGLX.so file.



I tried to install this file by first finding the library using apt-file find. The file is present in the right directory but during installation it is unable to locate it and so it stopped the salome installation.


Error:


[runSalome running on sharat-lenovo-ideapad-y700-14isk
Searching for a free port for naming service: 2812 - OK
Searching Naming Service + found in 0.1 seconds
Searching /Kernel/Session in Naming Service +SALOME_Session_Server: error while loading shared libraries: libGLX.so.0: cannot open shared object file: No such file or directory
Traceback (most recent call last):
File "/media/sharat/DATA/Sunag/Niramai/SALOME-9.5.0/BINARIES-CO7/KERNEL/bin/salome/orbmodule.py", line 181, in waitNSPID
os.kill(thePID,0)
ProcessLookupError: [Errno 3] No such process

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
File "/media/sharat/DATA/Sunag/Niramai/SALOME-9.5.0/BINARIES-CO7/KERNEL/bin/salome/runSalome.py", line 680, in useSalome
clt = startSalome(args, modules_list, modules_root_dir)
File "/media/sharat/DATA/Sunag/Niramai/SALOME-9.5.0/BINARIES-CO7/KERNEL/bin/salome/runSalome.py", line 625, in startSalome
session=clt.waitNSPID("/Kernel/Session",mySessionServ.PID,SALOME.Session)
File "/media/sharat/DATA/Sunag/Niramai/SALOME-9.5.0/BINARIES-CO7/KERNEL/bin/salome/orbmodule.py", line 183, in waitNSPID
raise RuntimeError("Process %d for %s not found" % (thePID,theName))
RuntimeError: Process 9726 for /Kernel/Session not found


--- Error during Salome launch ---
➜ SALOME-9.5.0 Warning, no type found for resource "localhost", using default value "single_machine"][/Error]




Could you provide me any light on this error?


Regards,


Sunag R A.

otaolafr November 25, 2020 06:08

Quote:

Originally Posted by sunagra27 (Post 788759)
Dear Franco,


Thank you very much for the suggestion and the example file.


With respect to salome, I did download from the salome platform and try to run after extraction. I am getting an error related to libGLX.so file.



I tried to install this file by first finding the library using apt-file find. The file is present in the right directory but during installation it is unable to locate it and so it stopped the salome installation.


Error:


[runSalome running on sharat-lenovo-ideapad-y700-14isk
Searching for a free port for naming service: 2812 - OK
Searching Naming Service + found in 0.1 seconds
Searching /Kernel/Session in Naming Service +SALOME_Session_Server: error while loading shared libraries: libGLX.so.0: cannot open shared object file: No such file or directory
Traceback (most recent call last):
File "/media/sharat/DATA/Sunag/Niramai/SALOME-9.5.0/BINARIES-CO7/KERNEL/bin/salome/orbmodule.py", line 181, in waitNSPID
os.kill(thePID,0)
ProcessLookupError: [Errno 3] No such process

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
File "/media/sharat/DATA/Sunag/Niramai/SALOME-9.5.0/BINARIES-CO7/KERNEL/bin/salome/runSalome.py", line 680, in useSalome
clt = startSalome(args, modules_list, modules_root_dir)
File "/media/sharat/DATA/Sunag/Niramai/SALOME-9.5.0/BINARIES-CO7/KERNEL/bin/salome/runSalome.py", line 625, in startSalome
session=clt.waitNSPID("/Kernel/Session",mySessionServ.PID,SALOME.Session)
File "/media/sharat/DATA/Sunag/Niramai/SALOME-9.5.0/BINARIES-CO7/KERNEL/bin/salome/orbmodule.py", line 183, in waitNSPID
raise RuntimeError("Process %d for %s not found" % (thePID,theName))
RuntimeError: Process 9726 for /Kernel/Session not found


--- Error during Salome launch ---
➜ SALOME-9.5.0 Warning, no type found for resource "localhost", using default value "single_machine"][/Error]




Could you provide me any light on this error?


Regards,


Sunag R A.

LOL, I was going to send you the link to a post in salome forum until I saw that it was your post ahahah.
emm... sorry, I am using salome in windows, but I would have a look at this guy, as he installed in linux mint and had to trouble shoot the problems... that I think are similar to yours, also you have a big explanation on how salome can be used (in case that it is not understandable from my file when you will be able to open...).
https://www.youtube.com/watch?v=mhzbiZ-wy68
one last coment about salome. you will have two different modules SHAPER and GEOMETRY almost all of us are using GEOMETRY to create the boundaries, as you dont know how to use any of the two I would recomend you to go with the SHAPER module as GEOMETRY will disapear in 2021.

good luck, and happy foaming :)

sunagra27 January 6, 2021 01:24

Thank you for the reply Franco..I did check the video of the link you sent tried to install Salome. But failed with same error.


I am still unable to clear the error and install Salome. I am in touch with Salome group and Linux forum. Hopefully, it will be solved asap.


Let me know if you get any leads.


Thanks and Regards,
Sunag R A.

otaolafr January 6, 2021 03:24

Quote:

Originally Posted by sunagra27 (Post 792543)
Thank you for the reply Franco..I did check the video of the link you sent tried to install Salome. But failed with same error.


I am still unable to clear the error and install Salome. I am in touch with Salome group and Linux forum. Hopefully, it will be solved asap.


Let me know if you get any leads.


Thanks and Regards,
Sunag R A.

what linux distribution are you using?
if ubuntu (or any debian distribution),
try from the terminal,
Code:

sudo apt-get update
sudo apt-get install net-tools
sudo apt-get install libtbb

best regards


All times are GMT -4. The time now is 07:08.