CFD Online Logo CFD Online URL
www.cfd-online.com
[Sponsors]
Home > Forums > Software User Forums > ANSYS > ANSYS Meshing & Geometry

[ANSYS Meshing] how to rename face zone labels automatically in fluent meshing in journal file

Register Blogs Community New Posts Updated Threads Search

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   November 10, 2023, 11:56
Exclamation how to rename face zone labels automatically in fluent meshing in journal file
  #1
New Member
 
ahlaam
Join Date: Oct 2023
Posts: 1
Rep Power: 0
ahlaam is on a distinguished road
Hello all,

I have a question and hopefully someone can help me. In spaceclaim I created a 3D geometry that consists of a tube with 6 spherss which are cut out on the inside with combine tool. Those cavities are dead zones and contain no volume, but each hole has a wall. Named selections have been created: inlet, outlet, wall_tube, wall_sphere1, wall_sphere2, wall_sphere3, wall_sphere4, wall_sphere5 and wall_sphere6. I saved this as an .x_t instead of .scdoc, because when importing .scdoc into Snellius (when the journal file is read) it is not supported by the Linux system.

Then I want to import this geometry in fluent meshing and start meshing the tube. However, the named selections are not included, so the face zone labels have completely different names that are very random. These are the new names for the face zone labels which can be seen in the console:

Meshing/objects/labels>
face-zone-label cell-zone-type underlying-objects face-zones
-------------------- --------------- --------------- ----- ------------------------------------------
tube solid () (2 3 4 5 6 7 8 9 10)
zone0:181 solid () (2)
zone0:184 solid () (3)
zone0:187 solid () (4)
zone0:960 solid () (5)
zone0:846 solid () (6)
zone0:732 solid () (7)
zone0:789 solid () (8)
zone0:903 solid () (9)
zone0:1017 solid () (10)

In a journal file I want to automatically rename these face zone labels with a command line to inlet, outlet, wall_tube, wall_sphere1, wall_sphere2, wall_sphere3, wall_sphere4, wall_sphere5 and wall_sphere6. I can do it with these command lines:

/objects/labels/rename "tube" zone0:187 "inlet"
/objects/labels/rename "tube" zone0:184 "outlet"
/objects/labels/rename "tube" zone0:181 "wall_tube"
/objects/labels/rename "tube" zone0:1017 "sphere_wall1"
/objects/labels/rename "tube" zone0:732 "sphere_wall2"
/objects/labels/rename "tube" zone0:789 "sphere_wall3"
/objects/labels/rename "tube" zone0:846 "sphere_wall4"
/objects/labels/rename "tube" zone0:903 "sphere_wall5"
/objects/labels/rename "tube" zone0:960 "sphere_wall6".

However, I always have to typewrite the name of the face zone labels manually. And if I have 30 spheres, for example, I want this to be done automatically. Can someone help me with this? OR maybe someone can help me with a solution where the named selections which are defined in spaceclaim are included when the x_t file is imported in fluent meshing?

I really appreciate your help, because I want to run simulations with hundreds of spheres that are cut out, but I cannot do this manually in a journal file.
ahlaam is offline   Reply With Quote

Old   November 16, 2023, 16:57
Default Use a script, but in SpaceClaim
  #2
Member
 
Join Date: Jul 2013
Posts: 98
Rep Power: 13
HHOS is on a distinguished road
Hello!


I am not sure I got your question, but when I had to name many different zones in fluent meshing I would just do it in SpaceClaim.


What I did was select the first surface(s), press Ctrl+G, click in a white area to quit the selection and go to the next surface(s).


The Ctrl+G will create a label that eventually will show up in fluent. By default takes the name "GroupXX", with XX being the number.



Now, let's say you have made 100 selections. Now you want to change their names. The best way for that is to create a script in SpaceClaim. You click on "File->New->Script" and you will get on the right side an extra pannel for the code. Click on the record button, and manually change the name of the first label. That will show you how the code must look like. Modify it accordingly with the correct label names and run it. You will happily see how all are changed in a second


You don't need to convert the spaceclaim file into x_t for fluent mesher. Just read the .scdoc directly.


Hope it helps.


Regards.
HHOS is offline   Reply With Quote

Reply


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
OpenFoam "Permission denied" and "command not found" problems. iyidaniel@yahoo.co.uk OpenFOAM Running, Solving & CFD 11 January 2, 2018 07:47
Problem compiling a custom Lagrangian library brbbhatti OpenFOAM Programming & Development 2 July 7, 2014 12:32
"parabolicVelocity" in OpenFoam 2.1.0 ? sawyer86 OpenFOAM Running, Solving & CFD 21 February 7, 2012 12:44
[blockMesh] BlockMeshmergePatchPairs hjasak OpenFOAM Meshing & Mesh Conversion 11 August 15, 2008 08:36
DecomposePar links against liblamso0 with OpenMPI jens_klostermann OpenFOAM Bugs 11 June 28, 2007 18:51


All times are GMT -4. The time now is 01:04.