Mmg
Simplicial remeshers (mesh adaptation, isovalue discretization, lagrangian movement)
Functions
libmmg3d_tools.c File Reference

Tools functions for the mmg3d library. More...

#include "libmmg3d.h"
#include "mmgcommon_private.h"
#include "inlined_functions_3d_private.h"
#include "mmgversion.h"
#include "mmg3dexterns_private.h"
#include "mmgexterns_private.h"
Include dependency graph for libmmg3d_tools.c:

Go to the source code of this file.

Functions

void MMG5_argv_cleanup (char **mmgArgv, int mmgArgc)
 
void MMG3D_setfunc (MMG5_pMesh mesh, MMG5_pSol met)
 Set function pointers for caltet, lenedg, lenedgCoor defsiz, gradsiz... depending if the metric that was read is anisotropic or isotropic.
 
int MMG3D_Get_adjaTet (MMG5_pMesh mesh, MMG5_int kel, MMG5_int listet[4])
 Return adjacent elements of a tetrahedron.
 
int MMG3D_usage (char *prog)
 Print help for mmg3d options.
 
int MMG3D_defaultValues (MMG5_pMesh mesh)
 Print the default parameters values.
 
int MMG3D_storeknownar (int argc, char *argv[], MMG5_pMesh mesh, MMG5_pSol met, MMG5_pSol sol, int *mmgArgc, char *mmgArgv[])
 
int MMG3D_parsar (int argc, char *argv[], MMG5_pMesh mesh, MMG5_pSol met, MMG5_pSol sol)
 Store command-line arguments.
 
int MMG3D_parsop (MMG5_pMesh mesh, MMG5_pSol met)
 Read a file containing Local parameters (.mmg3d extension)
 
int MMG3D_freeLocalPar (MMG5_pMesh mesh)
 
int MMG3D_Get_numberOfNonBdyTriangles (MMG5_pMesh mesh, MMG5_int *nb_tria)
 Get the number of non-boundary triangles.
 
int MMG3D_Get_nonBdyTriangle (MMG5_pMesh mesh, MMG5_int *v0, MMG5_int *v1, MMG5_int *v2, MMG5_int *ref, MMG5_int idx)
 Get vertices and reference of a non-boundary triangle.
 
int MMG3D_stockOptions (MMG5_pMesh mesh, MMG5_Info *info)
 Store the info structure in the mesh structure.
 
void MMG3D_destockOptions (MMG5_pMesh mesh, MMG5_Info *info)
 Recover the info structure stored in the mesh structure.
 
int MMG3D_mmg3dcheck (MMG5_pMesh mesh, MMG5_pSol met, MMG5_pSol sol, double critmin, double lmin, double lmax, MMG5_int *eltab, int8_t metRidTyp)
 Search invalid elements (in term of quality or edge length) in a mesh.
 
void MMG3D_searchqua (MMG5_pMesh mesh, MMG5_pSol met, double critmin, MMG5_int *eltab, int8_t metRidTyp)
 List bad elements.
 
int MMG3D_Get_tetFromTria (MMG5_pMesh mesh, MMG5_int ktri, MMG5_int *ktet, int *iface)
 Get a tetrahedron given one of its triangles and the index by which it refers to this triangle (DEPRECATED).
 
int MMG3D_Get_tetsFromTria (MMG5_pMesh mesh, MMG5_int ktri, MMG5_int ktet[2], int iface[2])
 Get two tetrahedra given a triangle and face indices.
 
int MMG3D_searchlen (MMG5_pMesh mesh, MMG5_pSol met, double lmin, double lmax, MMG5_int *eltab, int8_t metRidTyp)
 List edges that are too short or too long.
 
static int MMG3D_solTruncatureForOptim (MMG5_pMesh mesh, MMG5_pSol met, int ani)
 
int MMG3D_doSol_iso (MMG5_pMesh mesh, MMG5_pSol met)
 
int MMG3D_doSol_ani (MMG5_pMesh mesh, MMG5_pSol met)
 
int MMG3D_Set_constantSize (MMG5_pMesh mesh, MMG5_pSol met)
 Compute a constant size map according to the hsiz, hmin and hmax parameters.
 
int MMG3D_switch_metricStorage (MMG5_pMesh mesh, MMG5_pSol met)
 Swap the m22 and m23 values of the metric.
 
int MMG3D_Compute_eigenv (double m[6], double lambda[3], double vp[3][3])
 Compute the real eigenvalues and eigenvectors of a symmetric matrix.
 
void MMG3D_Free_solutions (MMG5_pMesh mesh, MMG5_pSol sol)
 Free the solution structure of a given mesh.
 
int MMG3D_Clean_isoSurf (MMG5_pMesh mesh)
 Clean data (triangles and edges) linked to isosurface.
 

Detailed Description

Tools functions for the mmg3d library.

Author
Algiane Froehly (Inria/UBordeaux)
Version
5
Date
01 2014

Definition in file libmmg3d_tools.c.

Function Documentation

◆ MMG3D_Clean_isoSurf()

int MMG3D_Clean_isoSurf ( MMG5_pMesh  mesh)

Clean data (triangles and edges) linked to isosurface.

Parameters
meshpointer to the mesh structure
Returns
1 if successful, 0 otherwise.
Remarks
Fortran interface:

‍ SUBROUTINE MMG3D_CLEAN_ISOSURF(mesh,retval)
MMG5_DATA_PTR_T, INTENT(IN) :: mesh
INTEGER, INTENT(OUT) :: retval
END SUBROUTINE

Step 1: a. deletion of triangles that belong to isosurf

Step 2: deletion of edges that belong to isosurf

Definition at line 1777 of file libmmg3d_tools.c.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ MMG3D_Compute_eigenv()

int MMG3D_Compute_eigenv ( double  m[6],
double  lambda[3],
double  vp[3][3] 
)

Compute the real eigenvalues and eigenvectors of a symmetric matrix.

Parameters
mupper part of a symmetric matrix diagonalizable in |R
lambdaarray of the metric eigenvalues
vparray of the metric eigenvectors
Returns
the order of the eigenvalues

Compute the real eigenvalues and eigenvectors of a symmetric matrix m whose upper part is provided (m11, m12, m13, m22, m23, m33 in this order).

lambda[0] is the eigenvalue associated to the eigenvector ( v[0][0], v[0,1], v[0,2] ) in C and to the eigenvector v(1,:) in fortran

lambda[1] is the eigenvalue associated to the eigenvector ( v[1][0], v[1,1], v[1,2] ) in C and to the eigenvector v(2,:) in fortran

lambda[2] is the eigenvalue associated to the eigenvector ( v[2][0], v[2,1], v[2,2] ) in C and to the eigenvector v(3,:) in fortran

Remarks
Fortran interface:

‍ SUBROUTINE MMG3D_COMPUTE_EIGENV(m,lambda,vp,retval)
REAL(KIND=8), INTENT(IN) :: m(*)
REAL(KIND=8), INTENT(OUT) :: lambda(*),vp(*)
INTEGER, INTENT(OUT) :: retval
END SUBROUTINE

Definition at line 1744 of file libmmg3d_tools.c.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ MMG3D_defaultValues()

int MMG3D_defaultValues ( MMG5_pMesh  mesh)

Print the default parameters values.

Tools for the library

Parameters
meshpointer to the mesh structure.
Returns
0 if fail, 1 if success.
Remarks
Fortran interface:

‍ SUBROUTINE MMG3D_DEFAULTVALUES(mesh,retval)
MMG5_DATA_PTR_T, INTENT(INOUT) :: mesh
INTEGER, INTENT(OUT) :: retval
END SUBROUTINE

Definition at line 205 of file libmmg3d_tools.c.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ MMG3D_destockOptions()

void MMG3D_destockOptions ( MMG5_pMesh  mesh,
MMG5_Info info 
)

Recover the info structure stored in the mesh structure.

Parameters
meshpointer to the mesh structure.
infopointer to the info structure.
Remarks
Fortran interface:

‍ SUBROUTINE MMG3D_DESTOCKOPTIONS(mesh,info)
MMG5_DATA_PTR_T, INTENT(INOUT) :: mesh,info
END SUBROUTINE

Definition at line 1190 of file libmmg3d_tools.c.

Here is the caller graph for this function:

◆ MMG3D_doSol_ani()

int MMG3D_doSol_ani ( MMG5_pMesh  mesh,
MMG5_pSol  met 
)
Parameters
meshpointer to the mesh
metpointer to the metric
Returns
1 if succeed, 0 if fail

Compute anisotropic size map according to the mean of the length of the edges passing through a point.

Definition at line 1589 of file libmmg3d_tools.c.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ MMG3D_doSol_iso()

int MMG3D_doSol_iso ( MMG5_pMesh  mesh,
MMG5_pSol  met 
)
Parameters
meshpointer to the mesh
metpointer to the metric
Returns
1 if succeed, 0 if fail

Compute isotropic size map according to the mean of the length of the edges passing through a point.

Definition at line 1514 of file libmmg3d_tools.c.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ MMG3D_Free_solutions()

void MMG3D_Free_solutions ( MMG5_pMesh  mesh,
MMG5_pSol  sol 
)

Free the solution structure of a given mesh.

Parameters
meshpointer to the mesh structure
solpointer to the solution structure
Remarks
Fortran interface:

‍ SUBROUTINE MMG3D_FREE_SOLUTIONS(mesh,sol)
MMG5_DATA_PTR_T, INTENT(INOUT) :: mesh,sol
END SUBROUTINE

Definition at line 1750 of file libmmg3d_tools.c.

Here is the caller graph for this function:

◆ MMG3D_freeLocalPar()

int MMG3D_freeLocalPar ( MMG5_pMesh  mesh)

Definition at line 908 of file libmmg3d_tools.c.

◆ MMG3D_Get_adjaTet()

int MMG3D_Get_adjaTet ( MMG5_pMesh  mesh,
MMG5_int  kel,
MMG5_int  listet[4] 
)

Return adjacent elements of a tetrahedron.

Utils

Parameters
meshpointer to the mesh structure.
keltetrahedron index.
listetpointer to the array of the 4 tetra adjacent to kel. (the index is 0 if there is no adjacent)
Returns
1.

Find the indices of the 4 adjacent elements of tetrahedron kel. \(listet[i] = 0\) if the \(i^{th}\) face has no adjacent element (so we are on a boundary face).

Remarks
Fortran interface:

‍ SUBROUTINE MMG3D_GET_ADJATET(mesh,kel,listet,retval)
MMG5_DATA_PTR_T, INTENT(INOUT) :: mesh
INTEGER(MMG5F_INT), INTENT(IN) :: kel
INTEGER(MMG5F_INT), DIMENSION(4), INTENT(OUT) :: listet
INTEGER, INTENT(OUT) :: retval
END SUBROUTINE

Definition at line 148 of file libmmg3d_tools.c.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ MMG3D_Get_nonBdyTriangle()

int MMG3D_Get_nonBdyTriangle ( MMG5_pMesh  mesh,
MMG5_int *  v0,
MMG5_int *  v1,
MMG5_int *  v2,
MMG5_int *  ref,
MMG5_int  idx 
)

Get vertices and reference of a non-boundary triangle.

Parameters
meshpointer to the mesh structure.
v0pointer to the firts vertex of the triangle
v1pointer to the second vertex of the triangle.
v2pointer to the third vertex of the triangle.
refpointer to the triangle reference.
idxindex of the non-boundary triangle to get (between 1 and nb_tria)
Returns
0 if failed, 1 otherwise.

Get vertices and reference ref of the idx^th non-boundary triangle (for DG methods for example). A tria is boundary if it is located at the interface of 2 domains with different references or if it belongs to one tetra only.

Remarks
Fortran interface:

‍ SUBROUTINE MMG3D_GET_NONBDYTRIANGLE(mesh,v0,v1,v2,ref,idx,retval)
MMG5_DATA_PTR_T,INTENT(INOUT) :: mesh
INTEGER(MMG5F_INT), INTENT(OUT):: v0,v1,v2
INTEGER(MMG5F_INT) :: ref
INTEGER(MMG5F_INT), INTENT(IN) :: idx
INTEGER, INTENT(OUT) :: retval
END SUBROUTINE

Definition at line 1131 of file libmmg3d_tools.c.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ MMG3D_Get_numberOfNonBdyTriangles()

int MMG3D_Get_numberOfNonBdyTriangles ( MMG5_pMesh  mesh,
MMG5_int *  nb_tria 
)

Get the number of non-boundary triangles.

Parameters
meshpointer to the mesh structure.
nb_triapointer to the number of non-boundary triangles.
Returns
0 if failed, 1 otherwise.

Get the number of non-boundary triangles (for DG methods for example). A triangle is boundary if it is located at the interface of 2 domains with different references or if it belongs to one tetra only. Append these triangles to the list of triangles.

Warning
reallocates the triangle array and appends the internal triangles. This may modify the behaviour of other functions.
Remarks
Fortran interface:

‍ SUBROUTINE MMG3D_GET_NUMBEROFNONBDYTRIANGLESS(mesh,nb_tria,retval)
MMG5_DATA_PTR_T,INTENT(INOUT) :: mesh
INTEGER(MMG5F_INT), INTENT(OUT) :: nb_tria
INTEGER, INTENT(OUT) :: retval
END SUBROUTINE

First step: Mesh analysis to detect the tetra/prisms boundary faces and to store the info in the xtetra/xprisms structures

Second step: Count the number of non boundary faces

Third step: Append the non boundary edges to the boundary edges array

Definition at line 916 of file libmmg3d_tools.c.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ MMG3D_Get_tetFromTria()

int MMG3D_Get_tetFromTria ( MMG5_pMesh  mesh,
MMG5_int  ktri,
MMG5_int *  ktet,
int *  iface 
)

Get a tetrahedron given one of its triangles and the index by which it refers to this triangle (DEPRECATED).

Parameters
meshpointer to the mesh structure.
ktriindex of the boundary triangle.
ktetpointer to an integer that will contains the tetra index.
ifacepointer to the triangle in ktet.
Returns
0 if fail, 1 otherwise

Fill ktet by the index of a tetrahedron to which belongs a boundary triangle and iface by the index of the triangle in the tetra.

Warning
will be deprecated in release 5.5
Remarks
Fortran interface:

‍ SUBROUTINE MMG3D_GET_TETFROMTRIA(mesh,ktri,ktet,iface,retval)
MMG5_DATA_PTR_T, INTENT(IN) :: mesh
INTEGER(MMG5F_INT), INTENT(IN) :: ktri
INTEGER(MMG5F_INT), INTENT(OUT) :: ktet
INTEGER, INTENT(OUT) :: iface
INTEGER, INTENT(OUT) :: retval
END SUBROUTINE

Definition at line 1323 of file libmmg3d_tools.c.

Here is the caller graph for this function:

◆ MMG3D_Get_tetsFromTria()

int MMG3D_Get_tetsFromTria ( MMG5_pMesh  mesh,
MMG5_int  ktri,
MMG5_int  ktet[2],
int  iface[2] 
)

Get two tetrahedra given a triangle and face indices.

Parameters
meshpointer to the mesh structure.
ktriindex of the boundary triangle.
ktetarray of size 2 that will contain the indices of the tetra (filled by the function).
ifacepointer to an array of size 2 that will contains the indices of the faces of the tetras ktet[i] that corresponds to the boundary tria ktri.
Returns
0 if fail, 1 otherwise

Fill ktet by the indices of the tetrahedra that have a boundary triangle and iface by the indices of the faces of the tetras that correspond to the triangle. Fill ktet[1] and iface[1] by 0 if the triangle belongs to 1 tetrahedron only.

Remarks
Fortran interface:

‍ SUBROUTINE MMG3D_GET_TETSFROMTRIA(mesh,ktri,ktet,iface,retval)
MMG5_DATA_PTR_T, INTENT(IN) :: mesh
INTEGER(MMG5F_INT), INTENT(IN) :: ktri
INTEGER(MMG5F_INT), DIMENSION(2), INTENT(OUT):: ktet
INTEGER, DIMENSION(2), INTENT(OUT) :: iface
INTEGER, INTENT(OUT) :: retval
END SUBROUTINE

Definition at line 1342 of file libmmg3d_tools.c.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ MMG3D_mmg3dcheck()

int MMG3D_mmg3dcheck ( MMG5_pMesh  mesh,
MMG5_pSol  met,
MMG5_pSol  sol,
double  critmin,
double  lmin,
double  lmax,
MMG5_int *  eltab,
int8_t  metRidTyp 
)

Search invalid elements (in term of quality or edge length) in a mesh.

Checks

Parameters
meshpointer to the mesh structure.
metpointer to the sol structure (metric).
solpointer to the sol structure (ls or displacement).
critminminimum quality for elements.
lminminimum edge length.
lmaxmaximum ede length.
eltabarray of invalid elements.
metRidTypType of storage of ridges metrics: 0 for classic storage (before the MMG5_defsiz call), 1 for special storage (after this call).
Remarks
Fortran interface:

‍ SUBROUTINE MMG3D_MMG3DCHECK(mesh,met,sol,critmin,lmin,lmax,eltab,&
metridtyp,retval)
MMG5_DATA_PTR_T, INTENT(INOUT) :: mesh,met,sol
REAL(KIND=8), INTENT(IN) :: critmin,lmin,lmax
INTEGER(MMG5F_INT),DIMENSION(*), INTENT(OUT) :: eltab
INTEGER, INTENT(IN) :: metridtyp
INTEGER, INTENT(OUT) :: retval
END SUBROUTINE

Free topologic tables (adja, xpoint, xtetra) resulting from a previous run

Definition at line 1196 of file libmmg3d_tools.c.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ MMG3D_parsar()

int MMG3D_parsar ( int  argc,
char *  argv[],
MMG5_pMesh  mesh,
MMG5_pSol  met,
MMG5_pSol  sol 
)

Store command-line arguments.

Parameters
argcnumber of command line arguments.
argvcommand line arguments.
meshpointer to the mesh structure.
metpointer to a metric
solpointer to a level-set or displacement
Returns
1 if we want to run Mmg after, 0 if not or if fail.
Remarks
no matching fortran function.

Definition at line 660 of file libmmg3d_tools.c.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ MMG3D_parsop()

int MMG3D_parsop ( MMG5_pMesh  mesh,
MMG5_pSol  met 
)

Read a file containing Local parameters (.mmg3d extension)

Parameters
meshpointer to the mesh structure.
metpointer to the sol structure.
Returns
1.

Read local parameters file. This file must have the same name as the mesh with the .mmg3d extension or must be named DEFAULT.mmg3d.

Remarks
Fortran interface:

‍ SUBROUTINE MMG3D_PARSOP(mesh,met,retval)
MMG5_DATA_PTR_T, INTENT(INOUT) :: mesh,met
INTEGER, INTENT(OUT) :: retval
END SUBROUTINE

Definition at line 768 of file libmmg3d_tools.c.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ MMG3D_searchlen()

int MMG3D_searchlen ( MMG5_pMesh  mesh,
MMG5_pSol  met,
double  lmin,
double  lmax,
MMG5_int *  eltab,
int8_t  metRidTyp 
)

List edges that are too short or too long.

Parameters
meshpointer to the mesh structure.
metpointer to the sol structure.
lminminimum edge length.
lmaxmaximum ede length.
eltabarray of invalid elements.
metRidTypType of storage of ridges metrics: 0 for classic storage (before the MMG5_defsiz call), 1 for special storage (after this call).
Returns
1 if success, 0 otherwise.

Store in eltab elements which have edge lengths shorter than lmin or longer than lmax, eltab is allocated and could contain mesh->ne elements.

Remarks
Fortran interface:

‍ SUBROUTINE MMG3D_SEARCHLEN(mesh,met,lmin,lmax,eltab,metridtyp,retval)
MMG5_DATA_PTR_T, INTENT(INOUT) :: mesh,met
REAL(KIND=8), INTENT(IN) :: lmin,lmax
INTEGER(MMG5F_INT),DIMENSION(*), INTENT(OUT) :: eltab
INTEGER, INTENT(IN) :: metridtyp
INTEGER, INTENT(OUT) :: retval
END SUBROUTINE

Definition at line 1387 of file libmmg3d_tools.c.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ MMG3D_searchqua()

void MMG3D_searchqua ( MMG5_pMesh  mesh,
MMG5_pSol  met,
double  critmin,
MMG5_int *  eltab,
int8_t  metRidTyp 
)

List bad elements.

Parameters
meshpointer to the mesh structure.
metpointer to the sol structure.
critminminimum quality for elements.
eltabpointer to the array of invalid elements.
metRidTypType of storage of ridges metrics: 0 for classic storage (before the MMG5_defsiz call), 1 for special storage (after this call).

Store elements which have worse quality than critmin in eltab, eltab is allocated and could contain mesh->ne elements.

Remarks
Fortran interface:

‍ SUBROUTINE MMG3D_SEARCHQUA(mesh,met,critmin,eltab,metridtyp)
MMG5_DATA_PTR_T, INTENT(INOUT) :: mesh,met
REAL(KIND=8), INTENT(IN) :: critmin
INTEGER(MMG5F_INT),DIMENSION(*), INTENT(OUT) :: eltab
INTEGER, INTENT(IN) :: metridtyp
END SUBROUTINE

Definition at line 1295 of file libmmg3d_tools.c.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ MMG3D_Set_constantSize()

int MMG3D_Set_constantSize ( MMG5_pMesh  mesh,
MMG5_pSol  met 
)

Compute a constant size map according to the hsiz, hmin and hmax parameters.

Parameters
meshpointer to the mesh structure
metpointer to the sol structure
Returns
1 if success

This function computes a constant size map according to mesh->info.hsiz, mesh->info.hmin and mesh->info.hmax. It updates these 3 values if not compatible.

Remarks
Fortran interface:

‍ SUBROUTINE MMG3D_SET_CONSTANTSIZE(mesh,met,retval)
MMG5_DATA_PTR_T, INTENT(INOUT) :: mesh,met
INTEGER, INTENT(OUT) :: retval
END SUBROUTINE

Definition at line 1699 of file libmmg3d_tools.c.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ MMG3D_setfunc()

void MMG3D_setfunc ( MMG5_pMesh  mesh,
MMG5_pSol  met 
)

Set function pointers for caltet, lenedg, lenedgCoor defsiz, gradsiz... depending if the metric that was read is anisotropic or isotropic.

To associate function pointers without calling MMG3D_mmg3dlib

Parameters
meshpointer to the mesh structure (unused).
metpointer to the sol structure (unused).
Remarks
Fortran interface:

‍ SUBROUTINE MMG3D_SETFUNC(mesh,met)
MMG5_DATA_PTR_T, INTENT(INOUT) :: mesh,met
END SUBROUTINE

Definition at line 48 of file libmmg3d_tools.c.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ MMG3D_solTruncatureForOptim()

static int MMG3D_solTruncatureForOptim ( MMG5_pMesh  mesh,
MMG5_pSol  met,
int  ani 
)
inlinestatic
Parameters
meshpointer to the mesh structure.
metpointer to the solution structure.
ani1 for aniso metric, 0 for iso one
Returns
0 if fail, 1 if succeed.

Truncate the metric computed by the DoSol function by hmax and hmin values (if setted by the user). Set hmin and hmax if they are not setted.

Definition at line 1466 of file libmmg3d_tools.c.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ MMG3D_stockOptions()

int MMG3D_stockOptions ( MMG5_pMesh  mesh,
MMG5_Info info 
)

Store the info structure in the mesh structure.

Parameters
meshpointer to the mesh structure.
infopointer to the info structure.
Returns
1.
Remarks
Fortran interface:

‍ SUBROUTINE MMG3D_STOCKOPTIONS(mesh,info,retval)
MMG5_DATA_PTR_T, INTENT(INOUT) :: mesh,info
INTEGER, INTENT(OUT) :: retval
END SUBROUTINE

Definition at line 1177 of file libmmg3d_tools.c.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ MMG3D_storeknownar()

int MMG3D_storeknownar ( int  argc,
char *  argv[],
MMG5_pMesh  mesh,
MMG5_pSol  met,
MMG5_pSol  sol,
int *  mmgArgc,
char *  mmgArgv[] 
)
Parameters
argcnumber of command line args
argvcommand line args
meshpointer to the mesh
metpointer to the metric
solpointer to the solution (level-set or displacement)
mmgArgcpointer to the number of appened unknown args (to fill)
mmgArgvpointer to the appened unknown args (to fill)
Returns
1 if success, 0 if fail (missing value for argument)

Store the values of command line arguments known by Mmg in suitable data structure and append unknown args in mmgArgv/mmgArgc.

Definition at line 238 of file libmmg3d_tools.c.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ MMG3D_switch_metricStorage()

int MMG3D_switch_metricStorage ( MMG5_pMesh  mesh,
MMG5_pSol  met 
)

Swap the m22 and m23 values of the metric.

Parameters
meshpointer to the mesh structure
metpointer to the sol structure
Returns
1 if success

Switch the m22 and m23 value of the metric to allow to pass from the API storage to the medit storage.

Remarks
Fortran interface:

‍ SUBROUTINE MMG3D_SWITCH_METRICSTORAGE(mesh,met,retval)
MMG5_DATA_PTR_T, INTENT(INOUT) :: mesh,met
INTEGER, INTENT(OUT) :: retval
END SUBROUTINE

Definition at line 1727 of file libmmg3d_tools.c.

Here is the caller graph for this function:

◆ MMG3D_usage()

int MMG3D_usage ( char *  prog)

Print help for mmg3d options.

Parameters
progpointer to the program name.
return1 if success, 0 if fail.
Remarks
Fortran interface:

‍ SUBROUTINE MMG3D_USAGE(prog,strlen0,retval)
CHARACTER(LEN=*), INTENT(IN) :: prog
INTEGER, INTENT(IN) :: strlen0
INTEGER, INTENT(OUT) :: retval
END SUBROUTINE

Definition at line 165 of file libmmg3d_tools.c.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ MMG5_argv_cleanup()

void MMG5_argv_cleanup ( char **  mmgArgv,
int  mmgArgc 
)

Definition at line 40 of file libmmg3d_tools.c.

Here is the caller graph for this function: