Skip to content

Commit

Permalink
Merge branch 'main' into maint/0.5.0.dev2
Browse files Browse the repository at this point in the history
  • Loading branch information
ninad-kamat authored Jul 14, 2023
2 parents 4594894 + 03df57c commit ba306eb
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 19 deletions.
34 changes: 16 additions & 18 deletions doc/source/user_guide/automesh.rst
Original file line number Diff line number Diff line change
Expand Up @@ -191,7 +191,7 @@ Thin volume mesh controls

The :class:`ThinVolumeControl <ansys.meshing.prime.ThinVolumeControl>` class creates prisms from a source face mesh projecting to a target with the specified number of layers.

..Note::
.. note::
Thin volume controls can only be applied on the meshed surfaces.

Some guidelines for the thin volume mesh controls:
Expand All @@ -212,31 +212,29 @@ The below example shows how to:

.. code-block:: python
auto_mesh_params = prime.AutoMeshParams(model=model)
thin_vol_ctrls_ids = []
thin_vol_ctrl = model.control_data.create_thin_volume_control()
thin_vol_ctrl.set_source_scope(
prime.ScopeDefinition(model, label_expression="thin_src")
)
thin_vol_ctrl.set_target_scope(
prime.ScopeDefinition(model, label_expression="thin_trg")
)
.. code-block:: python
part = model.get_part_by_name("pipe")
thin_vol_ctrls_ids = []
thin_vol_ctrl = model.control_data.create_thin_volume_control()
thin_vol_ctrl.set_source_scope(
prime.ScopeDefinition(model, label_expression="thin_src")
)
thin_vol_ctrl.set_target_scope(
prime.ScopeDefinition(model, label_expression="thin_trg")
)
thin_vol_ctrl.set_thin_volume_mesh_params(
prime.ThinVolumeMeshParams(
model=model,
n_layers=3,
)
)
thin_vol_ctrls_ids.append(thin_vol_ctrl.id)
auto_mesh_params.thin_volume_control_ids = thin_vol_ctrls_ids
part = model.get_part_by_name("pipe2")
prime.AutoMesh(model).mesh(part.id, auto_mesh_params)
part_summary_res = part.get_summary(
prime.PartSummaryParams(model=model, print_id=False, print_mesh=True)
# Volume mesh
auto_mesh_params = prime.AutoMeshParams(
model=model,
thin_volume_control_ids=thin_vol_ctrls_ids,
)
prime.AutoMesh(model).mesh(part.id, auto_mesh_params)
Layers of thin volume mesh created between the source and target surfaces.

Expand Down
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ doc = [
"jupyter-sphinx==0.4.0",
"numpydoc==1.5.0",
"Sphinx==7.0.1",
"pyvista==0.39.1",
"pyvista==0.40.1",
"sphinx-autodoc-typehints==1.23.3",
"sphinx-copybutton==0.5.2",
"sphinx-gallery==0.13.0",
Expand Down

0 comments on commit ba306eb

Please sign in to comment.