ansys / pyfluent

Pythonic interface to Ansys Fluent
https://fluent.docs.pyansys.com
MIT License
275 stars 40 forks source link

Meshing Workflows - why are old arguments required and is there any advice on how to set these #2414

Open spatel-23 opened 9 months ago

spatel-23 commented 9 months ago

πŸ” Before submitting the issue

🐞 Description of the bug

Why are old arguments required and is there any advice on how to set these?

Watertight Meshing Workflow

Update boundaries meshing.workflow.TaskObject["Update Boundaries"].Arguments = { "BoundaryLabelList": ["wall-inlet"], "BoundaryLabelTypeList": ["wall"], "OldBoundaryLabelList": ["wall-inlet"], "OldBoundaryLabelTypeList": ["velocity-inlet"],

Fault-Tolerant Meshing Workflow

Update regions settings "OldRegionLeakageSizeList": [""], "OldRegionMeshMethodList": ["wrap"], "OldRegionNameList": ["fluid-region-1"], "OldRegionOversetComponenList": ["no"], "OldRegionTypeList": ["fluid"], "OldRegionVolumeFillList": ["hexcore"]

πŸ“ Steps to reproduce

Watertight Meshing Workflow and Fault-Tolerant Meshing Workflow examples show these.

πŸ’» Which operating system are you using?

Windows

πŸ“€ Which ANSYS version are you using?

2024R1

🐍 Which Python version are you using?

3.8

πŸ“¦ Installed packages

NA
raph-luc commented 9 months ago

My understanding of the basics here is that you need a way to specify which boundaries/regions you are changing when providing the arguments for the task object.

For example, if your geometry initially has boundary labels ["wall-1", "wall-2", "inlet", "outlet"], respectively associated with types ["wall", "wall", "velocity-inlet","pressure-outlet"], and you want to change "wall-1" label to "mass-inlet" and its type from "wall" to "mass-flow-inlet", you'd provide the following:

meshing.workflow.TaskObject["Update Boundaries"].Arguments = {
  "BoundaryLabelList": ["mass-inlet"],
  "BoundaryLabelTypeList": ["mass-flow-inlet"],
  "OldBoundaryLabelList": ["wall-1"],
  "OldBoundaryLabelTypeList": ["wall"],
}

Similarly, in the Watertight Meshing Workflow example you shared above, those arguments are changing the type of the boundary labeled "wall-inlet" from "velocity-inlet" to "wall".

Does this explanation make sense?

spatel-23 commented 9 months ago

Thanks for quick answer - that's useful to know and makes sense, as you point out, to specify old values to identify boundaries/regions you want to change. But not sure if it makes sense to also specify the old type. The point I am trying to make is that inputting such old arguments can be tedious for large complex cases especially when they don't seem to be needed.

raph-luc commented 9 months ago

I fully agree with you. I don't personally like the way this is set up, and I don't know if it really needs to be this way. I will discuss this with the team, thanks for bringing this up.