Skip to content

Create objects inside a mesh via a level set function #2021

@prudhomm

Description

@prudhomm

It can be interesting to create objects inside a meshed geometry whose CAO discretization is not available.
In order to do so, we rely on the MMG functionalities described in http://www.mmgtools.org/mmg-remesher-try-mmg/mmg-remesher-tutorials/mmg-remesher-mmg2d/implicit-domain-meshing, which create an interface from the 0-level set of a function.
The corresponding example can be found in the MMG repository in /libexamples/mmg2d/IsosurfDiscretization_lsOnly/main.c.

It is necessary to:

  • provide a .mesh file, containing the mesh where the function is defined
  • provide a .sol file, containing the function defining the interface

The steps are

  • create functions that write the .mesh and .sol files
  • create a circle on a square mesh using the function (x-x0)^2 + (y-y0)^2-R^2
  • create the level set associated to a generic body and place it in the meshed geometry (translation, rotation, scaling of the body coordinates & extension of the level set onto the meshed geometry)
  • add c++ API
  • add python API
  • add mesh generation tool

Metadata

Metadata

Type

No type

Projects

Status

Done

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions