mmgs
libmmgs_tools.c File Reference

Tools functions for the mmgs library. More...

#include "mmgs.h"
#include "inlined_functions.h"
Include dependency graph for libmmgs_tools.c:

Functions

void MMGS_setfunc (MMG5_pMesh mesh, MMG5_pSol met)
 
int MMGS_usage (char *prog)
 
int MMGS_defaultValues (MMG5_pMesh mesh)
 
int MMGS_parsar (int argc, char *argv[], MMG5_pMesh mesh, MMG5_pSol met)
 
int MMGS_stockOptions (MMG5_pMesh mesh, MMG5_Info *info)
 
void MMGS_destockOptions (MMG5_pMesh mesh, MMG5_Info *info)
 
int MMGS_Get_adjaTri (MMG5_pMesh mesh, int kel, int listri[3])
 Return adjacent elements of a triangle. More...
 
int MMGS_Get_adjaVerticesFast (MMG5_pMesh mesh, int ip, int start, int lispoi[MMGS_LMAX])
 Return adjacent elements of a triangle. More...
 
int MMGS_Set_constantSize (MMG5_pMesh mesh, MMG5_pSol met)
 

Detailed Description

Tools functions for the mmgs library.

Author
Charles Dapogny (UPMC)
Cécile Dobrzynski (Bx INP/Inria/UBordeaux)
Pascal Frey (UPMC)
Algiane Froehly (Inria/UBordeaux)
Version
5
Todo:
Doxygen documentation

Function Documentation

◆ MMGS_defaultValues()

int MMGS_defaultValues ( MMG5_pMesh  mesh)
Parameters
meshpointer toward the mesh structure.
Returns
0 if fail, 1 if success.

Print the default parameters values.

Remarks
Fortran interface:

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

Here is the call graph for this function:

◆ MMGS_destockOptions()

void MMGS_destockOptions ( MMG5_pMesh  mesh,
MMG5_Info info 
)
Parameters
meshpointer toward the mesh structure.
infopointer toward the info structure.

Recover the info structure stored in the mesh structure.

Remarks
Fortran interface:

SUBROUTINE MMGS_DESTOCKOPTIONS(mesh,info)
MMG5_DATA_PTR_T, INTENT(INOUT) :: mesh,info
END SUBROUTINE

◆ MMGS_Get_adjaTri()

int MMGS_Get_adjaTri ( MMG5_pMesh  mesh,
int  kel,
int  listri[3] 
)

Return adjacent elements of a triangle.

Parameters
meshpointer toward the mesh structure.
keltriangle index.
listripointer toward the table of the indices of the three adjacent triangles of the elt kel (the index is 0 if there is no adjacent).
Returns
1.

Find the indices of the 3 adjacent elements of triangle kel. $v_i = 0$ if the $i^{th}$ face has no adjacent element (so we are on a boundary face).

Remarks
Fortran interface:

SUBROUTINE MMGS_GET_ADJATRI(mesh,kel,listri,retval)
MMG5_DATA_PTR_T, INTENT(INOUT) :: mesh
INTEGER, INTENT(IN) :: kel
INTEGER, DIMENSION(3), INTENT(OUT) :: listri
INTEGER, INTENT(OUT) :: retval
END SUBROUTINE

Here is the call graph for this function:

◆ MMGS_Get_adjaVerticesFast()

int MMGS_Get_adjaVerticesFast ( MMG5_pMesh  mesh,
int  ip,
int  start,
int  lispoi[MMGS_LMAX] 
)

Return adjacent elements of a triangle.

Parameters
meshpointer toward the mesh structure.
ipvertex index.
startindex of a triangle holding ip.
lispoipointer toward an array of size MMGS_LMAX that will contain the indices of adjacent vertices to the vertex ip.
Returns
nbpoi the number of adjacent points if success, 0 if fail.

Find the indices of the adjacent vertices of the vertex ip of the triangle start.

Remarks
Fortran interface:

SUBROUTINE MMGS_GET_ADJAVERTICESFAST(mesh,ip,start,lispoi,retval)
MMG5_DATA_PTR_T, INTENT(INOUT) :: mesh
INTEGER, INTENT(IN) :: ip,start
INTEGER, DIMENSION(MMGS_LMAX), INTENT(OUT) :: lispoi
INTEGER, INTENT(OUT) :: retval
END SUBROUTINE

◆ MMGS_parsar()

int MMGS_parsar ( int  argc,
char *  argv[],
MMG5_pMesh  mesh,
MMG5_pSol  met 
)
Parameters
argcnumber of command line arguments.
argvcommand line arguments.
meshpointer toward the mesh structure.
metpointer toward the sol structure.
Returns
1.

Store command line arguments.

Remarks
no matching fortran function.
Here is the call graph for this function:

◆ MMGS_Set_constantSize()

int MMGS_Set_constantSize ( MMG5_pMesh  mesh,
MMG5_pSol  met 
)
Parameters
meshpointer toward the mesh structure
metpointer toward the sol structure
Returns
1 if success

Compute constant size map according to mesh->info.hsiz, mesh->info.hmin and mesh->info.hmax. Update this 3 value if not compatible.

Remarks
Fortran interface:

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

Here is the call graph for this function:

◆ MMGS_setfunc()

void MMGS_setfunc ( MMG5_pMesh  mesh,
MMG5_pSol  met 
)

To associate function pointers without calling MMGS_mmgslib

Parameters
meshpointer toward the mesh structure (unused).
metpointer toward the sol structure (unused).

Set function pointers for caltet, lenedg, defsiz and gradsiz.

Remarks
Fortran interface:

SUBROUTINE MMGS_SETFUNC(mesh,met)
MMG5_DATA_PTR_T, INTENT(INOUT) :: mesh,met
END SUBROUTINE

Here is the call graph for this function:

◆ MMGS_stockOptions()

int MMGS_stockOptions ( MMG5_pMesh  mesh,
MMG5_Info info 
)
Parameters
meshpointer toward the mesh structure.
infopointer toward the info structure.
Returns
1.

Store the info structure in the mesh structure.

Remarks
Fortran interface:

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

Here is the call graph for this function:

◆ MMGS_usage()

int MMGS_usage ( char *  prog)
Parameters
progpointer toward the program name.

Print help for mmgs options.

Remarks
Fortran interface:

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

Here is the call graph for this function: