-
-
September 16, 2023 at 2:51 pmMichael ConnollySubscriber
Hi All,
Is there a simple few commands to use to generate a surface mesh that is identical to that that would be created using the fluent meshing workflow button "generate the surface mesh"?
I would ideally like to use the GUI version of fluent meshing on my desktop to import the cad from Spaceclaim, and also complete the local sizings. Once done I would want to export the mesh, then reimport it on a HPC and execute the commands to generate the surface mesh and volume mesh.Â
Kind regards,
Michael.
-
September 19, 2023 at 8:38 amLars GoellnitzAnsys Employee
Hi Michael,
I think the easiest way to achieve that, is to record a journal while you're clicking through the workflow on your Windows machine. Your starting point can be the reading of the mesh file with the already imported geometry. In the journal file you will find all your setting within Python commands.
If you want to start from the CAD import, please kind in mind that SpaceClaim (.scdoc) is not supported in Linux. You have to start from a pmdb, which can be created in SpaceClaim or you get after the import of the .scdoc on your Windows machine.Thanks,
Lars -
September 19, 2023 at 3:15 pmMichael ConnollySubscriber
Hi Lars,
Â
Yes I already know the commands for importing that CAD and setting the local sizings. What I need to know is the TUI commands used to replicate the "Generate the Surface Mesh" button in the GUI.
Â
Kind regards,
Michael.
-
September 20, 2023 at 6:59 amLars GoellnitzAnsys Employee
Hi Michael,
the journal I wrote while running the watertight setting, looks like this (until the point of creating the surface mesh):
/file/set-tui-version "23.2"
;;; Selecting watertight workflow
(%py-exec "workflow.InitializeWorkflow(WorkflowType=r'Watertight Geometry')")
;;; Import a pmdb file
(%py-exec "meshing.GlobalSettings.LengthUnit.set_state(r'mm')")
(%py-exec "meshing.GlobalSettings.AreaUnit.set_state(r'mm^2')")
(%py-exec "meshing.GlobalSettings.VolumeUnit.set_state(r'mm^3')")
(%py-exec "workflow.TaskObject['Import Geometry'].Arguments.set_state({r'FileName': r'D:/3-ServiceRequest/Testgeometrie/Cylinder.pmdb',})")
(%py-exec "workflow.TaskObject['Import Geometry'].Execute()")
(newline)Â
;;; No addition of Local Sizes
(%py-exec "workflow.TaskObject['Add Local Sizing'].AddChildAndUpdate()")
;;; Run Generate the Surface Mesh with min=0.1, max=1.6, Cells per Gap=2
(%py-exec "workflow.TaskObject['Generate the Surface Mesh'].Arguments.set_state({r'CFDSurfaceMeshControls': {r'CellsPerGap': 2,r'MaxSize': 1.6,r'MinSize': 0.1,},})")
(%py-exec "workflow.TaskObject['Generate the Surface Mesh'].Execute()")
(%py-exec "workflow.TaskObject['Describe Geometry'].UpdateChildTasks(SetupTypeChanged=False)")I added some comments afterwards to understand the action of the python script better. For all the python commands there are more option available.
How your commands look like?
In addition I know that there are TUI commands to generate a surface mesh (let me call it the old style) but the watertight workflow uses Python instead of the TUI commands. Sometimes a python command calls a series of action that is nearly impossible to reproduce with TUI commands.
Thanks,
Lars -
September 25, 2023 at 12:43 pmMichael ConnollySubscriber
Hi Lara,
Thank you for the reply. I will try to use the Python fluent commands to realise what I want to do when meshing, yes I had the feeling that the TUI commands did not effectively do all that was being done by the "Gen surface mesh button" in the workflow.
Kind regards,
Michael.
-
- The topic ‘How to generate a surface mesh using fluent TUI commands:’ is closed to new replies.
- Non-Intersected faces found for matching interface periodic-walls
- Script error Code: 800a000d
- Unburnt Hydrocarbons contour in ANSYS FORTE for sector mesh
- Help: About the expression of turbulent viscosity in Realizable k-e model
- Fluent fails with Intel MPI protocol on 2 nodes
- Cyclone (Stairmand) simulation using RSM
- error udf
- Diesel with Ammonia/Hydrogen blend combustion
- Mass Conservation Issue in Methane Pyrolysis Shock Tube Simulation
- Script Error
-
1301
-
591
-
544
-
524
-
366
© 2025 Copyright ANSYS, Inc. All rights reserved.