Mmg
Simplicial remeshers (mesh adaptation, isovalue discretization, lagrangian movement)
|
API headers for the mmg2d library. More...
#include "mmg/common/libmmgtypes.h"
#include "mmg/mmg2d/mmg2d_export.h"
Go to the source code of this file.
Macros | |
#define | MMG2D_LMAX 1024 |
Variables | |
LIBMMG2D_EXPORT int(* | MMG2D_doSol )(MMG5_pMesh mesh, MMG5_pSol met) |
API headers for the mmg2d library.
Definition in file libmmg2d.h.
#define MMG2D_LMAX 1024 |
Maximum array size when storing adjacent points (or ball) of a vertex.
Definition at line 47 of file libmmg2d.h.
enum MMG2D_Param |
Input parameters for mmg library.
Input parameters for mmg library. Options prefixed by MMG2D_IPARAM asked for integers values ans options prefixed by MMG2D_DPARAM asked for real values.
Definition at line 58 of file libmmg2d.h.
LIBMMG2D_EXPORT int MMG2D_Chk_meshData | ( | MMG5_pMesh | mesh, |
MMG5_pSol | met | ||
) |
mesh | pointer toward the mesh structure. |
met | pointer toward the sol structure. |
Check if the number of given entities match with mesh and sol size (not mandatory) and check mesh datas.
SUBROUTINE MMG2D_Chk_meshData(mesh,met,retval)
MMG5_DATA_PTR_T,INTENT(INOUT) :: mesh,met
INTEGER, INTENT(OUT) :: retval
END SUBROUTINE
Definition at line 1846 of file API_functions_2d.c.
LIBMMG2D_EXPORT int MMG2D_Compute_eigenv | ( | double | m[3], |
double | lambda[2], | ||
double | vp[2][2] | ||
) |
m | upper part of a symetric matric diagonalizable in |R |
lambda | array of the metric eigenvalues |
vp | array of the metric eigenvectors |
Compute the real eigenvalues and eigenvectors of a symetric matrice m whose upper part is provided (m11, m12, m22, in this order). lambda[0] is the eigenvalue associated to the eigenvector ( v[0][0], v[0,1] ) 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] ) in C and to the eigenvector v(2,:) in fortran
SUBROUTINE MMG2D_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 960 of file libmmg2d_tools.c.
LIBMMG2D_EXPORT int MMG2D_defaultValues | ( | MMG5_pMesh | mesh | ) |
mesh | pointer toward the mesh structure. |
Print the default parameters values.
SUBROUTINE MMG2D_DEFAULTVALUES(mesh,retval)
MMG5_DATA_PTR_T, INTENT(INOUT) :: mesh
INTEGER, INTENT(OUT) :: retval
END SUBROUTINE
mesh | pointer toward the mesh structure. |
Print the default parameters values.
Definition at line 479 of file libmmg2d_tools.c.
LIBMMG2D_EXPORT int MMG2D_Free_all | ( | const int | starter, |
... | |||
) |
starter | dummy argument used to initialize the variadic argument list. |
... | variadic arguments that depend to the library function that you have call. |
For the MMG2D_mmg2dlib function, you need to call the MMG2D_Init_mesh function with the following arguments : MMG2D_Init_mesh(MMG5_ARG_start,MMG5_ARG_ppMesh, &your_mesh, MMG5_ARG_ppMet,&your_metric,MMG5_ARG_end).
For the MMG2D_mmg2dls function, you need to call the MMG2D_Init_mesh function with the following arguments : MMG2D_Init_mesh(MMG5_ARG_start,MMG5_ARG_ppMesh, &your_mesh, MMG5_ARG_ppLs, &your_level_set,MMG5_ARG_end).
For the MMG2D_mmg2dmov function, you must call : MMG2D_Init_mesh(MMG5_ARG_start,MMG5_ARG_ppMesh, &your_mesh, MMG5_ARG_ppMet,&empty_metric,MMG5_ARG_ppDisp, &your_displacement, MMG5_ARG_end).
Deallocations before return.
Definition at line 1897 of file API_functions_2d.c.
LIBMMG2D_EXPORT int MMG2D_Free_allSols | ( | MMG5_pMesh | mesh, |
MMG5_pSol * | sol | ||
) |
mesh | pointer toward the mesh structure. |
sol | pointer toward an array of solution structure (that stores solution fields). |
Deallocation of an array of solution fields
SUBROUTINE MMG2D_Free_allSols(mesh,sol,retval)
MMG5_DATA_PTR_T,INTENT(INOUT) :: mesh,sol
INTEGER, INTENT(OUT) :: retval
END SUBROUTINE
Definition at line 1891 of file API_functions_2d.c.
LIBMMG2D_EXPORT void MMG2D_Free_edges | ( | MMG5_pMesh | mesh | ) |
mesh | pointer toward the mesh structure |
Free the mesh edges (and the associated xpoints).
SUBROUTINE MMG2D_FREE_EDGES(mesh)
MMG5_DATA_PTR_T, INTENT(INOUT) :: mesh
END SUBROUTINE
Definition at line 991 of file libmmg2d_tools.c.
LIBMMG2D_EXPORT int MMG2D_Free_names | ( | const int | starter, |
... | |||
) |
starter | dummy argument used to initialize the variadic argument list. |
... | variadic arguments that depend to the library function that you have call. |
For the MMG2D_mmg2dlib function, you need to call the MMG2D_Init_mesh function with the following arguments : MMG2D_Init_mesh(MMG5_ARG_start,MMG5_ARG_ppMesh, &your_mesh, MMG5_ARG_ppMet,&your_metric,MMG5_ARG_end).
For the MMG2D_mmg2dls function, you need to call the MMG2D_Init_mesh function with the following arguments : MMG2D_Init_mesh(MMG5_ARG_start,MMG5_ARG_ppMesh, &your_mesh, MMG5_ARG_ppLs, &your_level_set,MMG5_ARG_end).
For the MMG2D_mmg2dmov function, you must call : MMG2D_Init_mesh(MMG5_ARG_start,MMG5_ARG_ppMesh, &your_mesh, MMG5_ARG_ppMet,&empty_metric,MMG5_ARG_ppDisp, &your_displacement, MMG5_ARG_end).
Structure deallocations before return.
Definition at line 1926 of file API_functions_2d.c.
LIBMMG2D_EXPORT void MMG2D_Free_solutions | ( | MMG5_pMesh | mesh, |
MMG5_pSol | sol | ||
) |
mesh | pointer toward the mesh structure |
sol | pointer toward the solution structure |
Free the solution.
SUBROUTINE MMG2D_FREE_SOLUTIONS(mesh,sol)
MMG5_DATA_PTR_T, INTENT(INOUT) :: mesh,sol
END SUBROUTINE
Definition at line 1008 of file libmmg2d_tools.c.
LIBMMG2D_EXPORT int MMG2D_Free_structures | ( | const int | starter, |
... | |||
) |
starter | dummy argument used to initialize the variadic argument list. |
... | variadic arguments that depend to the library function that you have call. |
For the MMG2D_mmg2dlib function, you need to call the MMG2D_Init_mesh function with the following arguments : MMG2D_Init_mesh(MMG5_ARG_start,MMG5_ARG_ppMesh, &your_mesh, MMG5_ARG_ppMet,&your_metric,MMG5_ARG_end).
For the MMG2D_mmg2dls function, you need to call the MMG2D_Init_mesh function with the following arguments : MMG2D_Init_mesh(MMG5_ARG_start,MMG5_ARG_ppMesh, &your_mesh, MMG5_ARG_ppLs, &your_level_set,MMG5_ARG_end).
For the MMG2D_mmg2dmov function, you must call : MMG2D_Init_mesh(MMG5_ARG_start,MMG5_ARG_ppMesh, &your_mesh, MMG5_ARG_ppMet,&empty_metric,MMG5_ARG_ppDisp, &your_displacement, MMG5_ARG_end).
Structure deallocations before return.
Definition at line 1911 of file API_functions_2d.c.
LIBMMG2D_EXPORT void MMG2D_Free_triangles | ( | MMG5_pMesh | mesh | ) |
mesh | pointer toward the mesh structure |
Free the mesh elements (and the adjacency).
SUBROUTINE MMG2D_FREE_TRIANGLES(mesh)
MMG5_DATA_PTR_T, INTENT(INOUT) :: mesh
END SUBROUTINE
Definition at line 976 of file libmmg2d_tools.c.
LIBMMG2D_EXPORT int MMG2D_Get_adjaTri | ( | MMG5_pMesh | mesh, |
MMG5_int | kel, | ||
MMG5_int | listri[3] | ||
) |
Return adjacent elements of a triangle.
mesh | pointer toward the mesh structure. |
kel | triangle index. |
listri | pointer toward the table of the indices of the three adjacent triangles of the elt kel (the index is 0 if there is no adjacent). |
Find the indices of the 3 adjacent elements of triangle kel. if the face has no adjacent element (so we are on a boundary face).
SUBROUTINE MMG2D_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
Definition at line 774 of file libmmg2d_tools.c.
LIBMMG2D_EXPORT MMG5_int MMG2D_Get_adjaVertices | ( | MMG5_pMesh | mesh, |
MMG5_int | ip, | ||
MMG5_int | lispoi[MMG2D_LMAX] | ||
) |
Return adjacent elements of a triangle.
mesh | pointer toward the mesh structure. |
ip | vertex index. |
lispoi | pointer toward an array of size MMG2D_LMAX that will contain the indices of adjacent vertices to the vertex ip. |
Find the indices of the adjacent vertices of the vertex ip.
SUBROUTINE MMG2D_GET_ADJAVERTICES(mesh,ip,lispoi,retval)
MMG5_DATA_PTR_T, INTENT(INOUT) :: mesh
INTEGER(MMG5F_INT), INTENT(IN) :: ip
INTEGER(MMG5F_INT), DIMENSION(MMG2D_LMAX), INTENT(OUT) :: lispoi
INTEGER(MMG5F_INT), INTENT(OUT) :: retval
END SUBROUTINE
Definition at line 788 of file libmmg2d_tools.c.
LIBMMG2D_EXPORT MMG5_int MMG2D_Get_adjaVerticesFast | ( | MMG5_pMesh | mesh, |
MMG5_int | ip, | ||
MMG5_int | start, | ||
MMG5_int | lispoi[MMG2D_LMAX] | ||
) |
Return adjacent elements of a triangle.
mesh | pointer toward the mesh structure. |
ip | vertex index. |
start | index of a triangle holding ip. |
lispoi | pointer toward an array of size MMG2D_LMAX that will contain the indices of adjacent vertices to the vertex ip. |
Find the indices of the adjacent vertices of the vertex ip of the triangle start.
SUBROUTINE MMG2D_GET_ADJAVERTICESFAST(mesh,ip,start,lispoi,retval)
MMG5_DATA_PTR_T, INTENT(INOUT) :: mesh
INTEGER(MMG5F_INT), INTENT(IN) :: ip,start
INTEGER(MMG5F_INT), DIMENSION(MMG2D_LMAX), INTENT(OUT) :: lispoi
INTEGER(MMG5F_INT), INTENT(OUT) :: retval
END SUBROUTINE
Definition at line 800 of file libmmg2d_tools.c.
LIBMMG2D_EXPORT int MMG2D_Get_edge | ( | MMG5_pMesh | mesh, |
MMG5_int * | e0, | ||
MMG5_int * | e1, | ||
MMG5_int * | ref, | ||
int * | isRidge, | ||
int * | isRequired | ||
) |
mesh | pointer toward the mesh structure. |
e0 | pointer toward the first extremity of the edge. |
e1 | pointer toward the second extremity of the edge. |
ref | pointer toward the edge reference. |
isRidge | pointer toward the flag saying if the edge is ridge. |
isRequired | pointer toward the flag saying if the edge is required. |
Get extremities e0, e1 and reference ref of next boundary edge of mesh. An edge is boundary if it is located at the interface of 2 domains witch different references, if it belongs to one triangle only or if it is a "special" edge (required).
SUBROUTINE MMG2D_GET_EDGE(mesh,e0,e1,ref,isRidge,isRequired,retval)
MMG5_DATA_PTR_T,INTENT(INOUT) :: mesh
INTEGER(MMG5F_INT), INTENT(OUT):: e0,e1
INTEGER(MMG5F_INT) :: ref
INTEGER :: isRidge,isRequired
INTEGER, INTENT(OUT) :: retval
END SUBROUTINE
Definition at line 1299 of file API_functions_2d.c.
LIBMMG2D_EXPORT int MMG2D_Get_edges | ( | MMG5_pMesh | mesh, |
MMG5_int * | edges, | ||
MMG5_int * | refs, | ||
int * | areRidges, | ||
int * | areRequired | ||
) |
mesh | pointer toward the mesh structure. |
edges | pointer toward the array of edges. Vertices of the edge are stored in edge[(i-1)*2]@2. |
refs | edges references. refs[i-1] is the ref of the edge. |
areRidges | 1 if the edge is a ridge, 0 otherwise. |
areRequired | 1 if the edge is required, 0 otherwise. |
Get vertices and references of the mesh edges.
! SUBROUTINE MMG2D_GET_EDGES(mesh,edges,refs,areRidges,areRequired,retval)
! MMG5_DATA_PTR_T,INTENT(INOUT) :: mesh
! INTEGER(MMG5F_INT), INTENT(IN) :: edges(*)
! INTEGER(MMG5F_INT), INTENT(OUT):: refs(*)
! INTEGER, INTENT(OUT) :: areRequired(*),areRidges(*)
! INTEGER, INTENT(OUT) :: retval
! END SUBROUTINE
Definition at line 1375 of file API_functions_2d.c.
LIBMMG2D_EXPORT int MMG2D_Get_ithSol_inSolsAtVertices | ( | MMG5_pSol | sol, |
int | i, | ||
double * | s, | ||
MMG5_int | pos | ||
) |
sol | pointer toward the array of solutions |
i | position of the solution field that we want to set. |
s | solution(s) at mesh vertex pos. |
pos | index of the vertex on which we get the solution. |
Get values of the ith field of the solution array at vertex pos. (pos from 1 to nb_vertices included and i from 1 to nb_sols).
SUBROUTINE MMG2D_GET_ITHSOL_INSOLSATVERTICES(sol,i,s,pos,retval)
MMG5_DATA_PTR_T,INTENT(INOUT) :: sol
INTEGER, INTENT(IN) :: i
INTEGER(MMG5F_INT), INTENT(IN) :: pos
REAL(KIND=8), DIMENSION(*),INTENT(OUT) :: s
INTEGER, INTENT(OUT) :: retval
END SUBROUTINE
Definition at line 1816 of file API_functions_2d.c.
LIBMMG2D_EXPORT int MMG2D_Get_ithSols_inSolsAtVertices | ( | MMG5_pSol | sol, |
int | i, | ||
double * | s | ||
) |
sol | pointer toward the array of solutions |
i | position of the solution field that we want to get. |
s | table of the solutions at mesh vertices. The solution at vertex k is given by s[k-1] for a scalar sol, s[2*(k-1)]@2 for a vectorial solution and s[3*(k-1)]@3 for a tensor solution. |
Get values of the solution at the ith field of the solution array. (i from 1 to nb_sols)
SUBROUTINE MMG2D_GET_ITHSOLS_INSOLSATVERTICES(sol,i,s,retval)
MMG5_DATA_PTR_T,INTENT(INOUT) :: sol
INTEGER, INTENT(IN) :: i
REAL(KIND=8), DIMENSION(*),INTENT(OUT) :: s
INTEGER, INTENT(OUT) :: retval
END SUBROUTINE
Definition at line 1761 of file API_functions_2d.c.
LIBMMG2D_EXPORT int MMG2D_Get_meshSize | ( | MMG5_pMesh | mesh, |
MMG5_int * | np, | ||
MMG5_int * | nt, | ||
MMG5_int * | nquad, | ||
MMG5_int * | na | ||
) |
recover datas
mesh | pointer toward the mesh structure. |
np | pointer toward the number of vertices. |
nt | pointer toward the number of triangles. |
nquad | pointer toward the number of quads. |
na | pointer toward the number of edges. |
Get the number of vertices, triangles and edges of the mesh.
SUBROUTINE MMG2D_GET_MESHSIZE(mesh,np,nt,nquad,na,retval)
MMG5_DATA_PTR_T,INTENT(INOUT) :: mesh
INTEGER(MMG5F_INT) :: np,nt,nquad,na
INTEGER, INTENT(OUT) :: retval
END SUBROUTINE
Definition at line 649 of file API_functions_2d.c.
LIBMMG2D_EXPORT int MMG2D_Get_nonBdyEdge | ( | MMG5_pMesh | mesh, |
MMG5_int * | e0, | ||
MMG5_int * | e1, | ||
MMG5_int * | ref, | ||
MMG5_int | idx | ||
) |
mesh | pointer toward the mesh structure. |
e0 | pointer toward the first extremity of the edge. |
e1 | pointer toward the second extremity of the edge. |
ref | pointer toward the edge reference. |
idx | index of the non boundary edge to get (between 1 and nb_edges) |
Get extremities e0, e1 and reference ref of the idx^th non boundary edge (for DG methods for example). An edge is boundary if it is located at the interface of 2 domains with different references, if it belongs to one triangle only or if it is a singular edge (ridge or required).
SUBROUTINE MMG2D_GET_NONBDYEDGE(mesh,e0,e1,ref,idx,retval)
MMG5_DATA_PTR_T,INTENT(INOUT) :: mesh
INTEGER(MMG5F_INT), INTENT(OUT):: e0,e1
INTEGER(MMG5F_INT) :: ref
INTEGER(MMG5F_INT), INTENT(IN) :: idx
INTEGER, INTENT(OUT) :: retval
END SUBROUTINE
Definition at line 730 of file libmmg2d_tools.c.
LIBMMG2D_EXPORT int MMG2D_Get_numberOfNonBdyEdges | ( | MMG5_pMesh | mesh, |
MMG5_int * | nb_edges | ||
) |
mesh | pointer toward the mesh structure. |
nb_edges | pointer toward the number of non boundary edges. |
Get the number of non boundary edges (for DG methods for example). An edge is boundary if it is located at the interface of 2 domains with different references, if it belongs to one triangle only or if it is a singular edge (ridge or required). Append these edges to the list of edge.
SUBROUTINE MMG2D_GET_NUMBEROFNONBDYEDGES(mesh,nb_edges,retval)
MMG5_DATA_PTR_T,INTENT(INOUT) :: mesh
INTEGER(MMG5F_INT), INTENT(OUT):: nb_edges
INTEGER, INTENT(OUT) :: retval
END SUBROUTINE
Definition at line 637 of file libmmg2d_tools.c.
LIBMMG2D_EXPORT int MMG2D_Get_quadrilateral | ( | MMG5_pMesh | mesh, |
MMG5_int * | v0, | ||
MMG5_int * | v1, | ||
MMG5_int * | v2, | ||
MMG5_int * | v3, | ||
MMG5_int * | ref, | ||
int * | isRequired | ||
) |
mesh | pointer toward the mesh structure. |
v0 | pointer toward the first vertex of quadrangle. |
v1 | pointer toward the second vertex of quadrangle. |
v2 | pointer toward the third vertex of quadrangle. |
v3 | pointer toward the fourth vertex of quadrangle. |
ref | pointer toward the quadrangle reference. |
isRequired | pointer toward the flag saying if quadrangle is required. |
Get vertices v0, v1, v2, v3 and reference ref of next quad of mesh.
SUBROUTINE MMG2D_GET_QUADRILATERAL(mesh,v0,v1,v2,v3,ref,isRequired,&
retval)
MMG5_DATA_PTR_T,INTENT(INOUT) :: mesh
INTEGER(MMG5F_INT), INTENT(OUT):: v0,v1,v2,v3
INTEGER(MMG5F_INT) :: ref
INTEGER :: isRequired
INTEGER, INTENT(OUT) :: retval
END SUBROUTINE
Definition at line 1125 of file API_functions_2d.c.
LIBMMG2D_EXPORT int MMG2D_Get_quadrilaterals | ( | MMG5_pMesh | mesh, |
MMG5_int * | quadra, | ||
MMG5_int * | refs, | ||
int * | areRequired | ||
) |
mesh | pointer toward the mesh structure. |
quadra | pointer toward the table of the quadrilaterals vertices. Vertices of the quadrangle are stored in quadra[(i-1)*4]@4. |
refs | pointer toward the table of the quadrlaterals references. References of the quad is stored in refs[i-1]. |
areRequired | pointer toward the table of the flags saying if the quadrilaterals are required. areRequired[i-1]=1 if the quad is required. |
Get vertices and references of the mesh quadrilaterals.
! SUBROUTINE MMG2D_GET_QUADRILATERALS(mesh,quadra,refs,areRequired,&
! retval)
! MMG5_DATA_PTR_T,INTENT(INOUT) :: mesh
! INTEGER(MMG5F_INT), DIMENSION(*),INTENT(OUT) :: quadra
! INTEGER(MMG5F_INT), DIMENSION(*) :: refs
! INTEGER, DIMENSION(*) :: areRequired
! INTEGER, INTENT(OUT) :: retval
! END SUBROUTINE
Definition at line 1196 of file API_functions_2d.c.
LIBMMG2D_EXPORT int MMG2D_Get_scalarSol | ( | MMG5_pSol | met, |
double * | s | ||
) |
met | pointer toward the sol structure. |
s | pointer toward the scalar solution value. |
Get solution s of next vertex of mesh.
SUBROUTINE MMG2D_GET_SCALARSOL(met,s,retval)
MMG5_DATA_PTR_T,INTENT(INOUT) :: met
REAL(KIND=8), INTENT(OUT) :: s
INTEGER, INTENT(OUT) :: retval
END SUBROUTINE
Definition at line 1459 of file API_functions_2d.c.
LIBMMG2D_EXPORT int MMG2D_Get_scalarSols | ( | MMG5_pSol | met, |
double * | s | ||
) |
met | pointer toward the sol structure. |
s | table of the scalar solutions at mesh vertices. s[i-1] is the solution at vertex i. |
Get solutions at mesh vertices.
SUBROUTINE MMG2D_GET_SCALARSOLS(met,s,retval)
MMG5_DATA_PTR_T,INTENT(INOUT) :: met
REAL(KIND=8), DIMENSION(*),INTENT(OUT) :: s
INTEGER, INTENT(OUT) :: retval
END SUBROUTINE
Definition at line 1507 of file API_functions_2d.c.
LIBMMG2D_EXPORT int MMG2D_Get_solsAtVerticesSize | ( | MMG5_pMesh | mesh, |
MMG5_pSol * | sol, | ||
int * | nsols, | ||
MMG5_int * | nentities, | ||
int * | typSol | ||
) |
mesh | pointer toward the mesh structure. |
sol | pointer toward an array of sol structure. |
nentities | pointer toward the number of entities. |
typSol | array of size MMG5_NSOL_MAX to store type of each solution (scalar, vector..). |
Get the solution number, dimension and type.
SUBROUTINE MMG2D_GET_SOLSATVERTICESSIZE(mesh,sol,nsols,nentities,typSol,retval)
MMG5_DATA_PTR_T,INTENT(INOUT) :: mesh,sol
INTEGER :: nsols
INTEGER(MMG5F_INT) :: nentities
INTEGER :: typSol(*)
INTEGER, INTENT(OUT) :: retval
END SUBROUTINE
Definition at line 620 of file API_functions_2d.c.
LIBMMG2D_EXPORT int MMG2D_Get_solSize | ( | MMG5_pMesh | mesh, |
MMG5_pSol | sol, | ||
int * | typEntity, | ||
MMG5_int * | np, | ||
int * | typSol | ||
) |
mesh | pointer toward the mesh structure. |
sol | pointer toward the sol structure. |
typEntity | pointer toward the type of entities to which solutions are applied. |
np | pointer toward the number of solutions. |
typSol | pointer toward the type of the solutions (scalar, vectorial...) |
Get the solution number, dimension and type.
SUBROUTINE MMG2D_GET_SOLSIZE(mesh,sol,typEntity,np,typSol,retval)
MMG5_DATA_PTR_T,INTENT(INOUT) :: mesh,sol
INTEGER :: typEntity,typSol
INTEGER(MMG5F_INT) :: np
INTEGER, INTENT(OUT) :: retval
END SUBROUTINE
Definition at line 595 of file API_functions_2d.c.
LIBMMG2D_EXPORT int MMG2D_Get_tensorSol | ( | MMG5_pSol | met, |
double * | m11, | ||
double * | m12, | ||
double * | m22 | ||
) |
met | pointer toward the sol structure. |
m11 | pointer toward the position (1,1) in the solution tensor. |
m12 | pointer toward the position (1,2) in the solution tensor. |
m22 | pointer toward the position (2,2) in the solution tensor. |
Get tensorial solution of next vertex of mesh.
SUBROUTINE MMG2D_GET_TENSORSOL(met,m11,m12,m22,retval)
MMG5_DATA_PTR_T,INTENT(INOUT) :: met
REAL(KIND=8), INTENT(OUT) :: m11,m12,m22
INTEGER, INTENT(OUT) :: retval
END SUBROUTINE
Definition at line 1660 of file API_functions_2d.c.
LIBMMG2D_EXPORT int MMG2D_Get_tensorSols | ( | MMG5_pSol | met, |
double * | sols | ||
) |
met | pointer toward the sol structure. |
sols | table of the solutions at mesh vertices. sols[3*(i-1)]@3 is the solution at vertex i. |
Get tensorial solutions at mesh vertices.
SUBROUTINE MMG2D_GET_TENSORSOLS(met,sols,retval)
MMG5_DATA_PTR_T,INTENT(INOUT) :: met
REAL(KIND=8), DIMENSION(*), INTENT(OUT) :: sols
INTEGER, INTENT(OUT) :: retval
END SUBROUTINE
Definition at line 1717 of file API_functions_2d.c.
LIBMMG2D_EXPORT int MMG2D_Get_triangle | ( | MMG5_pMesh | mesh, |
MMG5_int * | v0, | ||
MMG5_int * | v1, | ||
MMG5_int * | v2, | ||
MMG5_int * | ref, | ||
int * | isRequired | ||
) |
mesh | pointer toward the mesh structure. |
v0 | pointer toward the first vertex of triangle. |
v1 | pointer toward the second vertex of triangle. |
v2 | pointer toward the third vertex of triangle. |
ref | pointer toward the triangle reference. |
isRequired | pointer toward the flag saying if triangle is required. |
Get vertices v0,v1,v2 and reference ref of next triangle of mesh.
SUBROUTINE MMG2D_GET_TRIANGLE(mesh,v0,v1,v2,ref,isRequired,retval)
MMG5_DATA_PTR_T,INTENT(INOUT) :: mesh
INTEGER(MMG5F_INT), INTENT(OUT):: v0,v1,v2
INTEGER(MMG5F_INT) :: ref
INTEGER :: isRequired
INTEGER, INTENT(OUT) :: retval
END SUBROUTINE
Definition at line 962 of file API_functions_2d.c.
LIBMMG2D_EXPORT double MMG2D_Get_triangleQuality | ( | MMG5_pMesh | mesh, |
MMG5_pSol | met, | ||
MMG5_int | k | ||
) |
mesh | pointer toward the mesh structure. |
met | pointer toward the metric structure. |
k | index of the triangle for which we want to get the quality. |
Get quality of tria k.
SUBROUTINE MMG2D_GET_TRIANGLEQUALITY(mesh,met,k,retval)
MMG5_DATA_PTR_T,INTENT(INOUT) :: mesh,met
INTEGER(MMG5F_INT), INTENT(IN):: k
REAL(KIND=8), INTENT(OUT) :: retval
END SUBROUTINE
Definition at line 1405 of file API_functions_2d.c.
LIBMMG2D_EXPORT int MMG2D_Get_triangles | ( | MMG5_pMesh | mesh, |
MMG5_int * | tria, | ||
MMG5_int * | refs, | ||
int * | areRequired | ||
) |
mesh | pointer toward the mesh structure. |
tria | pointer toward the table of the triangles vertices Vertices of the tria are stored in tria[(i-1)*3]@3. |
refs | pointer toward the table of the triangles references. refs[i-1] is the ref of the tria. |
areRequired | pointer toward table of the flags saying if triangles are required. areRequired[i-1]=1 if the tria is required. |
Get vertices and references of the mesh triangles.
! SUBROUTINE MMG2D_GET_TRIANGLES(mesh,tria,refs,areRequired,retval)
! MMG5_DATA_PTR_T,INTENT(INOUT) :: mesh
! INTEGER(MMG5F_INT), DIMENSION(*),INTENT(OUT) :: tria
! INTEGER(MMG5F_INT), DIMENSION(*) :: refs
! INTEGER, DIMENSION(*) :: areRequired
! INTEGER, INTENT(OUT) :: retval
! END SUBROUTINE
Definition at line 1065 of file API_functions_2d.c.
LIBMMG2D_EXPORT int MMG2D_Get_triFromEdge | ( | MMG5_pMesh | mesh, |
MMG5_int | ked, | ||
MMG5_int * | ktri, | ||
int * | ied | ||
) |
mesh | pointer toward the mesh structure. |
ked | index of the boundary edge. |
ktri | pointer toward the index of the tri (filled by the function). |
ied | pointer toward the index of the edge of the triangle ktri that correspond to the boundary edge ked. |
Fill ktri by the index of the triangle to which belong a boundary edge and ied by the index of the edge of the triangle that correspond to the edge.
SUBROUTINE MMG2D_GET_TRIFROMEDGE(mesh,ked,ktri,ied,retval)
MMG5_DATA_PTR_T, INTENT(IN) :: mesh
INTEGER(MMG5F_INT), INTENT(IN) :: ked
INTEGER(MMG5F_INT), INTENT(OUT) :: ktri
INTEGER, INTENT(OUT) :: retval,ied
END SUBROUTINE
Definition at line 875 of file libmmg2d_tools.c.
LIBMMG2D_EXPORT int MMG2D_Get_trisFromEdge | ( | MMG5_pMesh | mesh, |
MMG5_int | ked, | ||
MMG5_int | ktri[2], | ||
int | ied[2] | ||
) |
mesh | pointer toward the mesh structure. |
ked | index of the boundary edge. |
ktri | pointer toward an array of size 2 to fill by the indices of the triangles that share the edge ked (filled by the function). |
ied | pointer toward an array of size two to fill by the indices of the edge in each triangle. |
Fill ktri by the indices of the triangles to which belong a boundary edge and ied by the indices of the matching edge in each triangle. If ked belongs to one triangle only, ktri[1] = ied[1] = 0.
SUBROUTINE MMG2D_GET_TRISFROMEDGE(mesh,ked,ktri,ied,retval)
MMG5_DATA_PTR_T, INTENT(IN) :: mesh
INTEGER(MMG5F_INT), INTENT(IN) :: ked
INTEGER(MMG5F_INT), DIMENSION(2),INTENT(OUT) :: ktri
INTEGER, INTENT(OUT) :: retval,ied
END SUBROUTINE
Definition at line 894 of file libmmg2d_tools.c.
LIBMMG2D_EXPORT int MMG2D_Get_vectorSol | ( | MMG5_pSol | met, |
double * | vx, | ||
double * | vy | ||
) |
met | pointer toward the sol structure. |
vx | x value of the vectorial solution. |
vy | y value of the vectorial solution. |
Get vectorial solution of next vertex of mesh.
SUBROUTINE MMG2D_GET_VECTORSOL(met,vx,vy,retval)
MMG5_DATA_PTR_T,INTENT(INOUT) :: met
REAL(KIND=8), INTENT(OUT) :: vx,vy
INTEGER, INTENT(OUT) :: retval
END SUBROUTINE
Definition at line 1557 of file API_functions_2d.c.
LIBMMG2D_EXPORT int MMG2D_Get_vectorSols | ( | MMG5_pSol | met, |
double * | sols | ||
) |
met | pointer toward the sol structure. |
sols | table of the solutions at mesh vertices. sols[2*(i-1)]@2 is the solution at vertex i. |
Get vectorial solutions at mesh vertices
SUBROUTINE MMG2D_GET_VECTORSOLS(met,sols,retval)
MMG5_DATA_PTR_T,INTENT(INOUT) :: met
REAL(KIND=8), DIMENSION(*),INTENT(OUT) :: sols
INTEGER, INTENT(OUT) :: retval
END SUBROUTINE
Definition at line 1610 of file API_functions_2d.c.
LIBMMG2D_EXPORT int MMG2D_Get_vertex | ( | MMG5_pMesh | mesh, |
double * | c0, | ||
double * | c1, | ||
MMG5_int * | ref, | ||
int * | isCorner, | ||
int * | isRequired | ||
) |
mesh | pointer toward the mesh structure. |
c0 | pointer toward the coordinate of the point along the first dimension. |
c1 | pointer toward the coordinate of the point along the second dimension. |
ref | pointer to the point reference. |
isCorner | pointer toward the flag saying if point is corner. |
isRequired | pointer toward the flag saying if point is required. |
Get coordinates c0, c1 and reference ref of vertex num of mesh.
SUBROUTINE MMG2D_GET_VERTEX(mesh,c0,c1,ref,isCorner,isRequired,retval)
MMG5_DATA_PTR_T,INTENT(INOUT) :: mesh
REAL(KIND=8), INTENT(OUT) :: c0,c1
INTEGER(MMG5F_INT) :: ref
INTEGER :: isCorner,isRequired
INTEGER, INTENT(OUT) :: retval
END SUBROUTINE
Definition at line 738 of file API_functions_2d.c.
LIBMMG2D_EXPORT int MMG2D_Get_vertices | ( | MMG5_pMesh | mesh, |
double * | vertices, | ||
MMG5_int * | refs, | ||
int * | areCorners, | ||
int * | areRequired | ||
) |
mesh | pointer toward the mesh structure. |
vertices | pointer toward the table of the points coordinates. The coordinates of the point are stored in vertices[(i-1)*2]@2. |
refs | pointer to the table of the point references. The ref of the point is stored in refs[i-1]. |
areCorners | pointer toward the table of the flags saying if points are corners. areCorners[i-1]=1 if the point is corner. |
areRequired | pointer toward the table of flags saying if points are required. areRequired[i-1]=1 if the point is required. |
Get the coordinates and references of the mesh vertices.
! SUBROUTINE MMG2D_GET_VERTICES(mesh,vertices,refs,areCorners,&
! areRequired,retval)
! MMG5_DATA_PTR_T,INTENT(INOUT) :: mesh
! REAL(KIND=8),DIMENSION(*), INTENT(OUT) :: vertices
! INTEGER(MMG5F_INT), DIMENSION(*) :: refs
! INTEGER, DIMENSION(*) :: areCorners,areRequired
! INTEGER, INTENT(OUT) :: retval
! END SUBROUTINE
Definition at line 825 of file API_functions_2d.c.
LIBMMG2D_EXPORT int MMG2D_GetByIdx_vertex | ( | MMG5_pMesh | mesh, |
double * | c0, | ||
double * | c1, | ||
MMG5_int * | ref, | ||
int * | isCorner, | ||
int * | isRequired, | ||
MMG5_int | idx | ||
) |
mesh | pointer toward the mesh structure. |
c0 | pointer toward the coordinate of the point along the first dimension. |
c1 | pointer toward the coordinate of the point along the second dimension. |
ref | pointer to the point reference. |
isCorner | pointer toward the flag saying if point is corner. |
isRequired | pointer toward the flag saying if point is required. |
idx | index of point to get. |
Get coordinates c0, c1 and reference ref of vertex idx of mesh.
SUBROUTINE MMG2D_GETBYIDX_VERTEX(mesh,c0,c1,ref,isCorner,isRequired,idx,retval)
MMG5_DATA_PTR_T,INTENT(INOUT) :: mesh
REAL(KIND=8), INTENT(OUT) :: c0,c1
INTEGER :: isCorner,isRequired
INTEGER(MMG5F_INT) :: ref,idx
INTEGER, INTENT(OUT) :: retval
END SUBROUTINE
Definition at line 765 of file API_functions_2d.c.
LIBMMG2D_EXPORT void MMG2D_Init_fileNames | ( | MMG5_pMesh | mesh, |
MMG5_pSol | sol | ||
) |
mesh | pointer toward the mesh structure. |
sol | pointer toward the sol structure. |
Initialize file names to their default values.
SUBROUTINE MMG2D_INIT_FILENAMES(mesh,sol)
MMG5_DATA_PTR_T,INTENT(INOUT) :: mesh,sol
END SUBROUTINE
Definition at line 56 of file API_functions_2d.c.
LIBMMG2D_EXPORT int MMG2D_Init_mesh | ( | const int | starter, |
... | |||
) |
starter | dummy argument used to initialize the variadic argument list |
... | variadic arguments. |
For the MMG2D_mmgslib function, you need to call the MMG2D_Init_mesh function with the following arguments : MMG2D_Init_mesh(MMG5_ARG_start,MMG5_ARG_ppMesh, &your_mesh, MMG5_ARG_ppMet, &your_metric,MMG5_ARG_end).
For the MMG2D_mmgsls function, you need to call the MMG2D_Init_mesh function with the following arguments : MMG2D_Init_mesh(MMG5_ARG_start,MMG5_ARG_ppMesh, &your_mesh, MMG5_ARG_ppLs, &your_level_set,MMG5_ARG_end).
Here,your_mesh is a MMG5_pMesh, your_metric and your_level_set are MMG5_pSol.
MMG structures allocation and initialization.
Definition at line 43 of file API_functions_2d.c.
LIBMMG2D_EXPORT void MMG2D_Init_parameters | ( | MMG5_pMesh | mesh | ) |
mesh | pointer toward the mesh structure. |
Initialization of the input parameters (stored in the Info structure).
SUBROUTINE MMG2D_INIT_PARAMETERS(mesh)
MMG5_DATA_PTR_T,INTENT(INOUT) :: mesh
END SUBROUTINE
Definition at line 81 of file API_functions_2d.c.
LIBMMG2D_EXPORT int MMG2D_loadAllSols | ( | MMG5_pMesh | mesh, |
MMG5_pSol * | sol, | ||
const char * | filename | ||
) |
mesh | pointer toward the mesh structure. |
sol | pointer toward the solutions array |
filename | name of file. |
Load 1 or more solutions in a solution file at medit file format
SUBROUTINE MMG2D_LOADALLSOLS(mesh,sol,filename,strlen0,retval)
MMG5_DATA_PTR_T, INTENT(INOUT) :: mesh,sol
CHARACTER(LEN=*), INTENT(IN) :: filename
INTEGER, INTENT(IN) :: strlen0
INTEGER, INTENT(OUT) :: retval
END SUBROUTINE
mesh | pointer toward the mesh structure. |
sol | pointer toward an allocatable sol structure. |
filename | name of file. |
Load a medit solution file containing 1 or more solutions.
Read the file header
Sol tab allocation
Definition at line 991 of file inout_2d.c.
LIBMMG2D_EXPORT int MMG2D_loadGenericMesh | ( | MMG5_pMesh | mesh, |
MMG5_pSol | sol, | ||
const char * | filename | ||
) |
mesh | pointer toward the mesh structure. |
filename | name of file. |
Read mesh data.
SUBROUTINE MMG2D_LOADGENERICMESH(mesh,sol,filename,strlen0,retval)
MMG5_DATA_PTR_T, INTENT(INOUT) :: mesh,sol
CHARACTER(LEN=*), INTENT(IN) :: filename
INTEGER, INTENT(IN) :: strlen0
INTEGER, INTENT(OUT) :: retval
END SUBROUTINE
Definition at line 592 of file inout_2d.c.
LIBMMG2D_EXPORT int MMG2D_loadMesh | ( | MMG5_pMesh | mesh, |
const char * | filename | ||
) |
mesh | pointer toward the mesh structure. |
filename | name of the readed file. |
Read mesh data.
SUBROUTINE MMG2D_LOADMESH(mesh,filename,strlen0,retval)
MMG5_DATA_PTR_T, INTENT(INOUT) :: mesh
CHARACTER(LEN=*), INTENT(IN) :: filename
INTEGER, INTENT(IN) :: strlen0
INTEGER, INTENT(OUT) :: retval
END SUBROUTINE
Definition at line 28 of file inout_2d.c.
LIBMMG2D_EXPORT int MMG2D_loadMshMesh | ( | MMG5_pMesh | mesh, |
MMG5_pSol | sol, | ||
const char * | filename | ||
) |
mesh | pointer toward the mesh structure. |
sol | pointer toward the solution structure. |
filename | name of file. |
Read mesh and 0 or 1 data at MSH file format (.msh extension). We read only low-order points, edges, tria, quadra.
SUBROUTINE MMG2D_LOADMSHMESH(mesh,sol,filename,strlen0,retval)
MMG5_DATA_PTR_T, INTENT(INOUT) :: mesh,sol
CHARACTER(LEN=*), INTENT(IN) :: filename
INTEGER, INTENT(IN) :: strlen0
INTEGER, INTENT(OUT) :: retval
END SUBROUTINE
Definition at line 701 of file inout_2d.c.
LIBMMG2D_EXPORT int MMG2D_loadMshMesh_and_allData | ( | MMG5_pMesh | mesh, |
MMG5_pSol * | sol, | ||
const char * | filename | ||
) |
mesh | pointer toward the mesh structure. |
sol | pointer toward a list of solution structures. |
filename | name of file. |
Read mesh and a list of data at MSH file format (.msh extension). We read only low-order points, edges, tria, quadra, tetra and prisms.
SUBROUTINE MMG2D_LOADMSHMESH_AND_ALLDATA(mesh,sol,filename,strlen0,retval)
MMG5_DATA_PTR_T, INTENT(INOUT) :: mesh,sol
CHARACTER(LEN=*), INTENT(IN) :: filename
INTEGER, INTENT(IN) :: strlen0
INTEGER, INTENT(OUT) :: retval
END SUBROUTINE
Definition at line 767 of file inout_2d.c.
LIBMMG2D_EXPORT int MMG2D_loadSol | ( | MMG5_pMesh | mesh, |
MMG5_pSol | sol, | ||
const char * | filename | ||
) |
mesh | pointer toward the mesh structure. |
sol | pointer toward the solution structure.. |
filename | name of the solution file. |
Load metric field. The file at medit file format must contains 1 solution: the metric.
SUBROUTINE MMG2D_LOADSOL(mesh,sol,filename,strlen0,retval)
MMG5_DATA_PTR_T, INTENT(INOUT) :: mesh,sol
CHARACTER(LEN=*), INTENT(IN) :: filename
INTEGER, INTENT(IN) :: strlen0
INTEGER, INTENT(OUT) :: retval
END SUBROUTINE
mesh | pointer toward the mesh structure. |
met | pointer toward the sol structure. |
filename | name of file. |
Load metric field.
Read the file header
Definition at line 900 of file inout_2d.c.
LIBMMG2D_EXPORT int MMG2D_loadVect | ( | MMG5_pMesh | , |
char * | |||
) |
LIBMMG2D_EXPORT int MMG2D_loadVtkMesh | ( | MMG5_pMesh | mesh, |
MMG5_pSol | sol, | ||
const char * | filename | ||
) |
mesh | pointer toward the mesh structure. |
sol | pointer toward the solution structure. |
filename | name of file. |
Read mesh and 0 or 1 data field at VTK vtk file format (.vtk extension). We read only low-order points, edges, tria and quad.
SUBROUTINE MMG2D_LOADVTKMESH(mesh,sol,filename,strlen0,retval)
MMG5_DATA_PTR_T, INTENT(INOUT) :: mesh,sol
CHARACTER(LEN=*), INTENT(IN) :: filename
INTEGER, INTENT(IN) :: strlen0
INTEGER, INTENT(OUT) :: retval
END SUBROUTINE
Definition at line 158 of file inoutcpp_2d.cpp.
LIBMMG2D_EXPORT int MMG2D_loadVtkMesh_and_allData | ( | MMG5_pMesh | mesh, |
MMG5_pSol * | sol, | ||
const char * | filename | ||
) |
mesh | pointer toward the mesh structure. |
sol | pointer toward the solution structure. |
filename | name of file. |
Read mesh and a list of data field at VTK vtk file format (.vtk extension). We read only low-order points, edges, tria and quad.
SUBROUTINE MMG2D_LOADVTKMESH_AND_ALLDATA(mesh,sol,filename,strlen0,retval)
MMG5_DATA_PTR_T, INTENT(INOUT) :: mesh,sol
CHARACTER(LEN=*), INTENT(IN) :: filename
INTEGER, INTENT(IN) :: strlen0
INTEGER, INTENT(OUT) :: retval
END SUBROUTINE
Definition at line 201 of file inoutcpp_2d.cpp.
LIBMMG2D_EXPORT int MMG2D_loadVtpMesh | ( | MMG5_pMesh | mesh, |
MMG5_pSol | sol, | ||
const char * | filename | ||
) |
mesh | pointer toward the mesh structure. |
sol | pointer toward the solution structure. |
filename | name of file. |
Read mesh and 0 or 1 data field at VTK vtp file format (.vtp extension). We read only low-order points, edges, tria and quad.
SUBROUTINE MMG2D_LOADVTPMESH(mesh,sol,filename,strlen0,retval)
MMG5_DATA_PTR_T, INTENT(INOUT) :: mesh,sol
CHARACTER(LEN=*), INTENT(IN) :: filename
INTEGER, INTENT(IN) :: strlen0
INTEGER, INTENT(OUT) :: retval
END SUBROUTINE
Definition at line 83 of file inoutcpp_2d.cpp.
LIBMMG2D_EXPORT int MMG2D_loadVtpMesh_and_allData | ( | MMG5_pMesh | mesh, |
MMG5_pSol * | sol, | ||
const char * | filename | ||
) |
mesh | pointer toward the mesh structure. |
sol | pointer toward the solution structure. |
filename | name of file. |
Read mesh and a list of data fields at VTK vtp file format (.vtp extension). We read only low-order points, edges, tria and quad.
SUBROUTINE MMG2D_LOADVTPMESH_AND_ALLDATA(mesh,sol,filename,strlen0,retval)
MMG5_DATA_PTR_T, INTENT(INOUT) :: mesh,sol
CHARACTER(LEN=*), INTENT(IN) :: filename
INTEGER, INTENT(IN) :: strlen0
INTEGER, INTENT(OUT) :: retval
END SUBROUTINE
Definition at line 126 of file inoutcpp_2d.cpp.
LIBMMG2D_EXPORT int MMG2D_loadVtuMesh | ( | MMG5_pMesh | mesh, |
MMG5_pSol | sol, | ||
const char * | filename | ||
) |
mesh | pointer toward the mesh structure. |
sol | pointer toward the solution structure. |
filename | name of file. |
Read mesh and 0 or 1 data field at VTK vtu file format (.vtu extension). We read only low-order points, edges, tria and quad.
SUBROUTINE MMG2D_LOADVTUMESH(mesh,sol,filename,strlen0,retval)
MMG5_DATA_PTR_T, INTENT(INOUT) :: mesh,sol
CHARACTER(LEN=*), INTENT(IN) :: filename
INTEGER, INTENT(IN) :: strlen0
INTEGER, INTENT(OUT) :: retval
END SUBROUTINE
Definition at line 233 of file inoutcpp_2d.cpp.
LIBMMG2D_EXPORT int MMG2D_loadVtuMesh_and_allData | ( | MMG5_pMesh | mesh, |
MMG5_pSol * | sol, | ||
const char * | filename | ||
) |
mesh | pointer toward the mesh structure. |
sol | pointer toward the solution structure. |
filename | name of file. |
Read mesh and a list of data field at VTK vtu file format (.vtu extension). We read only low-order points, edges, tria and quad.
SUBROUTINE MMG2D_LOADVTUMESH_AND_ALLDATA(mesh,sol,filename,strlen0,retval)
MMG5_DATA_PTR_T, INTENT(INOUT) :: mesh,sol
CHARACTER(LEN=*), INTENT(IN) :: filename
INTEGER, INTENT(IN) :: strlen0
INTEGER, INTENT(OUT) :: retval
END SUBROUTINE
Definition at line 276 of file inoutcpp_2d.cpp.
LIBMMG2D_EXPORT int MMG2D_mmg2dlib | ( | MMG5_pMesh | mesh, |
MMG5_pSol | sol | ||
) |
mesh | pointer toward the mesh structure. |
sol | pointer toward a sol structure (metric). |
Main program for the mesh adaptation library .
SUBROUTINE MMG2D_MMG2DLIB(mesh,sol,retval)
MMG5_DATA_PTR_T, INTENT(INOUT) :: mesh,sol
INTEGER, INTENT(OUT) :: retval
END SUBROUTINE
Definition at line 63 of file libmmg2d.c.
LIBMMG2D_EXPORT int MMG2D_mmg2dls | ( | MMG5_pMesh | mesh, |
MMG5_pSol | sol, | ||
MMG5_pSol | met | ||
) |
mesh | pointer toward the mesh structure. |
sol | pointer toward a sol structure (level-set). |
met | pointer toward a sol structure (metric). |
Main program for the level-set discretization library. If a metric met is provided, use it to adapt the mesh.
SUBROUTINE MMG2D_MMG2DLS(mesh,sol,met,retval)
MMG5_DATA_PTR_T, INTENT(INOUT) :: mesh,sol
MMG5_DATA_PTR_T :: met
INTEGER, INTENT(OUT) :: retval
END SUBROUTINE
Definition at line 526 of file libmmg2d.c.
LIBMMG2D_EXPORT int MMG2D_mmg2dmesh | ( | MMG5_pMesh | mesh, |
MMG5_pSol | sol | ||
) |
mesh | pointer toward the mesh structure. |
sol | pointer toward a sol structure (metric). |
Main program for the mesh generation library .
SUBROUTINE MMG2D_MMG2DMESH(mesh,sol,retval)
MMG5_DATA_PTR_T, INTENT(INOUT) :: mesh,sol
INTEGER, INTENT(OUT) :: retval
END SUBROUTINE
Definition at line 307 of file libmmg2d.c.
LIBMMG2D_EXPORT int MMG2D_mmg2dmov | ( | MMG5_pMesh | mesh, |
MMG5_pSol | met, | ||
MMG5_pSol | disp | ||
) |
mesh | pointer toward the mesh structure. |
sol | pointer toward a sol structure (displacement). |
disp | pointer toward a sol (displacement for the lagrangian motion mode) structure. |
Main program for the rigid body movement library .
SUBROUTINE MMG2D_MMG2DMOV(mesh,sol,disp,retval)
MMG5_DATA_PTR_T, INTENT(INOUT) :: mesh,sol,disp
INTEGER, INTENT(OUT) :: retval
END SUBROUTINE
Definition at line 822 of file libmmg2d.c.
LIBMMG2D_EXPORT int MMG2D_parsar | ( | int | argc, |
char * | argv[], | ||
MMG5_pMesh | mesh, | ||
MMG5_pSol | met, | ||
MMG5_pSol | sol | ||
) |
argc | number of command line arguments. |
argv | command line arguments. |
mesh | pointer toward the mesh structure. |
met | pointer toward a metric |
sol | pointer toward a level-set or displacement |
Store command line arguments.
check file names
Definition at line 102 of file libmmg2d_tools.c.
LIBMMG2D_EXPORT int MMG2D_parsop | ( | MMG5_pMesh | mesh, |
MMG5_pSol | met | ||
) |
mesh | pointer toward the mesh structure. |
met | pointer toward the sol structure. |
Read local parameters file. This file must have the same name as the mesh with the .mmg3d extension or must be named DEFAULT.mmg3d.
SUBROUTINE MMG2D_PARSOP(mesh,met,retval)
MMG5_DATA_PTR_T, INTENT(INOUT) :: mesh,met
INTEGER, INTENT(OUT) :: retval
END SUBROUTINE
mesh | pointer toward the mesh |
met | pointer toward the metric |
Read parameter file DEFAULT.mmg2d
Definition at line 497 of file libmmg2d_tools.c.
LIBMMG2D_EXPORT void MMG2D_Reset_verticestags | ( | MMG5_pMesh | mesh | ) |
mesh | pointer toward the mesh structure |
Reset the vertices tag (be careful all the tags are deleted).
SUBROUTINE MMG2D_RESET_VERTICESTAGS(mesh)
MMG5_DATA_PTR_T, INTENT(INOUT) :: mesh
END SUBROUTINE
Definition at line 967 of file libmmg2d_tools.c.
LIBMMG2D_EXPORT int MMG2D_saveAllSols | ( | MMG5_pMesh | mesh, |
MMG5_pSol * | sol, | ||
const char * | filename | ||
) |
mesh | pointer toward the mesh structure. |
sol | pointer toward the solutions array |
filename | name of the solution file. |
Save 1 or more solutions in a solution file at medit file format.
SUBROUTINE MMG2D_SAVEALLSOLS(mesh,sol,filename,strlen0,retval)
MMG5_DATA_PTR_T, INTENT(INOUT) :: mesh,sol
CHARACTER(LEN=*), INTENT(IN) :: filename
INTEGER, INTENT(IN) :: strlen0
INTEGER, INTENT(OUT) :: retval
END SUBROUTINE
mesh | pointer toward the mesh structure. |
sol | pointer toward the solutions array. |
filename | name of file. |
Write 1 or more solutions.
Definition at line 1673 of file inout_2d.c.
LIBMMG2D_EXPORT int MMG2D_saveGenericMesh | ( | MMG5_pMesh | mesh, |
MMG5_pSol | sol, | ||
const char * | filename | ||
) |
mesh | pointer toward the mesh structure. |
filename | name of file. |
Save mesh data in a file whose format depends on the filename extension.
SUBROUTINE MMG2D_SAVEGENERICMESH(mesh,sol,filename,strlen0,retval)
MMG5_DATA_PTR_T, INTENT(INOUT) :: mesh,sol
CHARACTER(LEN=*), INTENT(IN) :: filename
INTEGER, INTENT(IN) :: strlen0
INTEGER, INTENT(OUT) :: retval
END SUBROUTINE
Definition at line 2230 of file inout_2d.c.
LIBMMG2D_EXPORT int MMG2D_saveMesh | ( | MMG5_pMesh | mesh, |
const char * | filename | ||
) |
mesh | pointer toward the mesh structure. |
filename | name of the readed file. |
Save mesh data.
SUBROUTINE MMG2D_SAVEMESH(mesh,filename,strlen0,retval)
MMG5_DATA_PTR_T, INTENT(INOUT) :: mesh
CHARACTER(LEN=*), INTENT(IN) :: filename
INTEGER, INTENT(IN) :: strlen0
INTEGER, INTENT(OUT) :: retval
END SUBROUTINE
Definition at line 1096 of file inout_2d.c.
LIBMMG2D_EXPORT int MMG2D_saveMshMesh | ( | MMG5_pMesh | mesh, |
MMG5_pSol | sol, | ||
const char * | filename | ||
) |
mesh | pointer toward the mesh structure. |
sol | pointer toward the solution structure. |
filename | name of file. |
Write mesh and 0 or 1 data at MSH file format (.msh extension). Save file at ASCII format for .msh extension, at binary format for .msh one.
SUBROUTINE MMG2D_SAVEMSHMESH(mesh,sol,filename,strlen0,retval)
MMG5_DATA_PTR_T, INTENT(INOUT) :: mesh,sol
CHARACTER(LEN=*), INTENT(IN) :: filename
INTEGER, INTENT(IN) :: strlen0
INTEGER, INTENT(OUT) :: retval
END SUBROUTINE
Definition at line 1531 of file inout_2d.c.
LIBMMG2D_EXPORT int MMG2D_saveMshMesh_and_allData | ( | MMG5_pMesh | mesh, |
MMG5_pSol * | sol, | ||
const char * | filename | ||
) |
mesh | pointer toward the mesh structure. |
sol | pointer toward the solution structure. |
filename | name of file. |
Write mesh and a list of data fields at MSH file format (.msh extension). Save file at ASCII format for .msh extension, at binary format for .mshb one.
SUBROUTINE MMG2D_SAVEMSHMESH_AND_ALLDATA(mesh,sol,filename,strlen0,retval)
MMG5_DATA_PTR_T, INTENT(INOUT) :: mesh,sol
CHARACTER(LEN=*), INTENT(IN) :: filename
INTEGER, INTENT(IN) :: strlen0
INTEGER, INTENT(OUT) :: retval
END SUBROUTINE
Definition at line 1535 of file inout_2d.c.
LIBMMG2D_EXPORT int MMG2D_saveSol | ( | MMG5_pMesh | mesh, |
MMG5_pSol | sol, | ||
const char * | filename | ||
) |
mesh | pointer toward the mesh structure. |
sol | pointer toward the solution structure.. |
filename | name of the solution file. |
Save metric field at medit solution file format.
SUBROUTINE MMG2D_SAVESOL(mesh,sol,filename,strlen0,retval)
MMG5_DATA_PTR_T, INTENT(INOUT) :: mesh,sol
CHARACTER(LEN=*), INTENT(IN) :: filename
INTEGER, INTENT(IN) :: strlen0
INTEGER, INTENT(OUT) :: retval
END SUBROUTINE
mesh | pointer toward the mesh structure. |
met | pointer toward the sol structure. |
filename | name of file. |
Write isotropic or anisotropic metric.
Definition at line 1612 of file inout_2d.c.
LIBMMG2D_EXPORT int MMG2D_saveTetgenMesh | ( | MMG5_pMesh | mesh, |
const char * | filename | ||
) |
mesh | pointer toward the mesh structure. |
filename | name of the readed file. |
Save mesh data at Triangle (or equivalent to Tetgen in 2D) file format.
SUBROUTINE MMG2D_SAVETETGENMESH(mesh,filename,strlen0,retval)
MMG5_DATA_PTR_T, INTENT(INOUT) :: mesh
CHARACTER(LEN=*), INTENT(IN) :: filename
INTEGER, INTENT(IN) :: strlen0
INTEGER, INTENT(OUT) :: retval
END SUBROUTINE
Definition at line 2209 of file inout_2d.c.
LIBMMG2D_EXPORT int MMG2D_saveVect | ( | MMG5_pMesh | mesh, |
MMG5_pSol | sol, | ||
const char * | filename, | ||
double | lambda | ||
) |
LIBMMG2D_EXPORT int MMG2D_saveVtkMesh | ( | MMG5_pMesh | mesh, |
MMG5_pSol | sol, | ||
const char * | filename | ||
) |
mesh | pointer toward the mesh structure. |
sol | pointer toward the solution structure. |
filename | name of file. |
Write mesh and 0 or 1 data at Vtk file format (.vtk extension).
SUBROUTINE MMG2D_SAVEVTKMESH(mesh,sol,filename,strlen0,retval)
MMG5_DATA_PTR_T, INTENT(INOUT) :: mesh,sol
CHARACTER(LEN=*), INTENT(IN) :: filename
INTEGER, INTENT(IN) :: strlen0
INTEGER, INTENT(OUT) :: retval
END SUBROUTINE
Definition at line 345 of file inoutcpp_2d.cpp.
LIBMMG2D_EXPORT int MMG2D_saveVtkMesh_and_allData | ( | MMG5_pMesh | mesh, |
MMG5_pSol * | sol, | ||
const char * | filename | ||
) |
mesh | pointer toward the mesh structure. |
sol | pointer toward the solution structure. |
filename | name of file. |
Write mesh and a list of data fields at Vtk file format (.vtk extension).
SUBROUTINE MMG2D_SAVEVTKMESH_AND_ALLDATA(mesh,sol,filename,strlen0,retval)
MMG5_DATA_PTR_T, INTENT(INOUT) :: mesh,sol
CHARACTER(LEN=*), INTENT(IN) :: filename
INTEGER, INTENT(IN) :: strlen0
INTEGER, INTENT(OUT) :: retval
END SUBROUTINE
Definition at line 360 of file inoutcpp_2d.cpp.
LIBMMG2D_EXPORT int MMG2D_saveVtpMesh | ( | MMG5_pMesh | mesh, |
MMG5_pSol | sol, | ||
const char * | filename | ||
) |
mesh | pointer toward the mesh structure. |
sol | pointer toward the solution structure. |
filename | name of file. |
Write mesh and 0 or 1 data at polydata Vtk file format (.vtp extension).
SUBROUTINE MMG2D_SAVEVTPMESH(mesh,sol,filename,strlen0,retval)
MMG5_DATA_PTR_T, INTENT(INOUT) :: mesh,sol
CHARACTER(LEN=*), INTENT(IN) :: filename
INTEGER, INTENT(IN) :: strlen0
INTEGER, INTENT(OUT) :: retval
END SUBROUTINE
Definition at line 375 of file inoutcpp_2d.cpp.
LIBMMG2D_EXPORT int MMG2D_saveVtpMesh_and_allData | ( | MMG5_pMesh | mesh, |
MMG5_pSol * | sol, | ||
const char * | filename | ||
) |
mesh | pointer toward the mesh structure. |
sol | pointer toward the solution structure. |
filename | name of file. |
Write mesh and a list of data fields at polydata Vtk file format (.vtp extension).
SUBROUTINE MMG2D_SAVEVTPMESH_AND_ALLDATA(mesh,sol,filename,strlen0,retval)
MMG5_DATA_PTR_T, INTENT(INOUT) :: mesh,sol
CHARACTER(LEN=*), INTENT(IN) :: filename
INTEGER, INTENT(IN) :: strlen0
INTEGER, INTENT(OUT) :: retval
END SUBROUTINE
Definition at line 391 of file inoutcpp_2d.cpp.
LIBMMG2D_EXPORT int MMG2D_saveVtuMesh | ( | MMG5_pMesh | mesh, |
MMG5_pSol | sol, | ||
const char * | filename | ||
) |
mesh | pointer toward the mesh structure. |
sol | pointer toward the solution structure. |
filename | name of file. |
Write mesh and 0 or 1 data at vtu Vtk file format (.vtu extension).
SUBROUTINE MMG2D_SAVEVTUMESH(mesh,sol,filename,strlen0,retval)
MMG5_DATA_PTR_T, INTENT(INOUT) :: mesh,sol
CHARACTER(LEN=*), INTENT(IN) :: filename
INTEGER, INTENT(IN) :: strlen0
INTEGER, INTENT(OUT) :: retval
END SUBROUTINE
Definition at line 315 of file inoutcpp_2d.cpp.
LIBMMG2D_EXPORT int MMG2D_saveVtuMesh_and_allData | ( | MMG5_pMesh | mesh, |
MMG5_pSol * | sol, | ||
const char * | filename | ||
) |
mesh | pointer toward the mesh structure. |
sol | pointer toward the solution structure. |
filename | name of file. |
Write mesh and a list of data fields at vtu Vtk file format (.vtu extension).
SUBROUTINE MMG2D_SAVEVTUMESH_AND_ALLDATA(mesh,sol,filename,strlen0,retval)
MMG5_DATA_PTR_T, INTENT(INOUT) :: mesh,sol
CHARACTER(LEN=*), INTENT(IN) :: filename
INTEGER, INTENT(IN) :: strlen0
INTEGER, INTENT(OUT) :: retval
END SUBROUTINE
Definition at line 330 of file inoutcpp_2d.cpp.
LIBMMG2D_EXPORT int MMG2D_scaleMesh | ( | MMG5_pMesh | mesh, |
MMG5_pSol | met, | ||
MMG5_pSol | ls | ||
) |
mesh | pointer toward the mesh structure. |
met | pointer toward the metric structure. |
ls | pointer toward a solution structure (level-set or displacement). |
Scale the mesh and the size informations between 0 and 1. Compute a default value for the hmin/hmax parameters if needed.
SUBROUTINE MMG2D_SCALEMESH(mesh,met,ls,retval)
MMG5_DATA_PTR_T, INTENT(INOUT) :: mesh,met,ls
INTEGER, INTENT(OUT) :: retval
END SUBROUTINE
LIBMMG2D_EXPORT void MMG2D_Set_commonFunc | ( | void | ) |
Set common pointer functions between mmgs and mmg2d to the matching mmg2d functions.
Definition at line 52 of file libmmg2d.c.
LIBMMG2D_EXPORT int MMG2D_Set_constantSize | ( | MMG5_pMesh | mesh, |
MMG5_pSol | met | ||
) |
mesh | pointer toward the mesh structure |
met | pointer toward the sol structure |
Compute constant size map according to mesh->info.hsiz, mesh->info.hmin and mesh->info.hmax. Update this 3 value if not compatible.
SUBROUTINE MMG2D_SET_CONSTANTSIZE(mesh,met,retval)
MMG5_DATA_PTR_T, INTENT(INOUT) :: mesh,met
INTEGER, INTENT(OUT) :: retval
END SUBROUTINE
Definition at line 935 of file libmmg2d_tools.c.
LIBMMG2D_EXPORT int MMG2D_Set_corner | ( | MMG5_pMesh | mesh, |
MMG5_int | k | ||
) |
mesh | pointer toward the mesh structure. |
k | vertex index. |
Set corner at point pos (from 1 to nb_vertices included).
SUBROUTINE MMG2D_SET_CORNER(mesh,k,retval)
MMG5_DATA_PTR_T,INTENT(INOUT) :: mesh
INTEGER(MMG5F_INT), INTENT(IN):: k
INTEGER, INTENT(OUT) :: retval
END SUBROUTINE
Definition at line 713 of file API_functions_2d.c.
LIBMMG2D_EXPORT int MMG2D_Set_dparameter | ( | MMG5_pMesh | mesh, |
MMG5_pSol | sol, | ||
int | dparam, | ||
double | val | ||
) |
mesh | pointer toward the mesh structure. |
sol | pointer toward the sol structure. |
dparam | double parameter to set (see MMG2D_Param structure). |
val | value of the parameter. |
Set double parameter dparam at value val.
SUBROUTINE MMG2D_SET_DPARAMETER(mesh,sol,dparam,val,retval)
MMG5_DATA_PTR_T,INTENT(INOUT) :: mesh
MMG5_DATA_PTR_T :: sol
INTEGER, INTENT(IN) :: dparam
REAL(KIND=8), INTENT(IN) :: val
INTEGER, INTENT(OUT) :: retval
END SUBROUTINE
Definition at line 276 of file API_functions_2d.c.
LIBMMG2D_EXPORT int MMG2D_Set_edge | ( | MMG5_pMesh | mesh, |
MMG5_int | v0, | ||
MMG5_int | v1, | ||
MMG5_int | ref, | ||
MMG5_int | pos | ||
) |
mesh | pointer toward the mesh structure. |
v0 | first vertex of edge. |
v1 | second vertex of edge. |
ref | edge reference. |
pos | edge position in the mesh. |
Set edge of vertices v0, v1 and reference ref at position pos in mesh structure (pos from 1 to nb_edges included).
SUBROUTINE MMG2D_SET_EDGE(mesh,v0,v1,ref,pos,retval)
MMG5_DATA_PTR_T,INTENT(INOUT) :: mesh
INTEGER(MMG5F_INT), INTENT(IN):: v0,v1
INTEGER(MMG5F_INT), INTENT(IN):: pos,ref
INTEGER, INTENT(OUT) :: retval
END SUBROUTINE
Definition at line 1226 of file API_functions_2d.c.
LIBMMG2D_EXPORT int MMG2D_Set_edges | ( | MMG5_pMesh | mesh, |
MMG5_int * | edges, | ||
MMG5_int * | refs | ||
) |
mesh | pointer toward the mesh structure. |
edges | pointer toward the array of edges. Vertices of the edge are stored in edge[(i-1)*2]@2. |
refs | edges references. refs[i-1] is the ref of the edge. |
Set vertices and references of the mesh edges.
SUBROUTINE MMG2D_SET_EDGES(mesh,edges,refs,retval)
MMG5_DATA_PTR_T,INTENT(INOUT) :: mesh
INTEGER(MMG5F_INT), INTENT(IN):: edges(*),refs(*)
INTEGER, INTENT(OUT) :: retval
END SUBROUTINE
Definition at line 1355 of file API_functions_2d.c.
LIBMMG2D_EXPORT int MMG2D_Set_inputMeshName | ( | MMG5_pMesh | mesh, |
const char * | meshin | ||
) |
mesh | pointer toward the mesh structure. |
meshin | input mesh name. |
Set the name of input mesh.
SUBROUTINE MMG2D_SET_INPUTMESHNAME(mesh,meshin,strlen0,retval)
MMG5_DATA_PTR_T, INTENT(INOUT) :: mesh
CHARACTER(LEN=*), INTENT(IN) :: meshin
INTEGER, INTENT(IN) :: strlen0
INTEGER, INTENT(OUT) :: retval
END SUBROUTINE
Definition at line 63 of file API_functions_2d.c.
LIBMMG2D_EXPORT int MMG2D_Set_inputSolName | ( | MMG5_pMesh | mesh, |
MMG5_pSol | sol, | ||
const char * | solin | ||
) |
mesh | pointer toward the mesh structure. |
sol | pointer toward the sol structure. |
solin | name of the input solution file. |
Set the name of input solution file.
SUBROUTINE MMG2D_SET_INPUTSOLNAME(mesh,sol,solin,strlen0,retval)
MMG5_DATA_PTR_T, INTENT(INOUT) :: mesh,sol
CHARACTER(LEN=*), INTENT(IN) :: solin
INTEGER, INTENT(IN) :: strlen0
INTEGER, INTENT(OUT) :: retval
END SUBROUTINE
Definition at line 68 of file API_functions_2d.c.
LIBMMG2D_EXPORT int MMG2D_Set_iparameter | ( | MMG5_pMesh | mesh, |
MMG5_pSol | sol, | ||
int | iparam, | ||
MMG5_int | val | ||
) |
mesh | pointer toward the mesh structure. |
sol | pointer toward the sol structure (unused). |
iparam | integer parameter to set (see MMG2D_Param structure). |
val | value for the parameter. |
Set integer parameter iparam at value val.
SUBROUTINE MMG2D_SET_IPARAMETER(mesh,sol,iparam,val,retval)
MMG5_DATA_PTR_T,INTENT(INOUT) :: mesh
MMG5_DATA_PTR_T :: sol
INTEGER, INTENT(IN) :: iparam
INTEGER(MMG5F_INT), INTENT(IN):: val
INTEGER, INTENT(OUT) :: retval
END SUBROUTINE
Definition at line 107 of file API_functions_2d.c.
LIBMMG2D_EXPORT int MMG2D_Set_ithSol_inSolsAtVertices | ( | MMG5_pSol | sol, |
int | i, | ||
double * | s, | ||
MMG5_int | pos | ||
) |
sol | pointer toward the array of solutions |
i | position of the solution field that we want to set. |
s | solution(s) at mesh vertex pos. |
pos | index of the vertex on which we set the solution. |
Set values of the solution at the ith field of the solution array. (pos from 1 to nb_vertices included and i from 1 to nb_sols).
SUBROUTINE MMG2D_SET_ITHSOL_INSOLSATVERTICES(sol,i,s,pos,retval)
MMG5_DATA_PTR_T,INTENT(INOUT) :: sol
INTEGER, INTENT(IN) :: i
INTEGER(MMG5F_INT), INTENT(IN) :: pos
REAL(KIND=8), DIMENSION(*),INTENT(OUT) :: s
INTEGER, INTENT(OUT) :: retval
END SUBROUTINE
Definition at line 1789 of file API_functions_2d.c.
LIBMMG2D_EXPORT int MMG2D_Set_ithSols_inSolsAtVertices | ( | MMG5_pSol | sol, |
int | i, | ||
double * | s | ||
) |
sol | pointer toward the array of solutions |
i | position of the solution field that we want to set. |
s | table of the solutions at mesh vertices. The solution at vertex k is given by s[k-1] for a scalar sol, s[2*(k-1)]@2 for a vectorial solution and s[3*(k-1)]@3 for a tensor solution. |
Set values of the solution at the ith field of the solution array. (i from 1 to nb_sols)
SUBROUTINE MMG2D_SET_ITHSOLS_INSOLSATVERTICES(sol,i,s,retval)
MMG5_DATA_PTR_T,INTENT(INOUT) :: sol
INTEGER, INTENT(IN) :: i
REAL(KIND=8), DIMENSION(*),INTENT(OUT) :: s
INTEGER, INTENT(OUT) :: retval
END SUBROUTINE
Definition at line 1733 of file API_functions_2d.c.
LIBMMG2D_EXPORT int MMG2D_Set_localParameter | ( | MMG5_pMesh | mesh, |
MMG5_pSol | sol, | ||
int | typ, | ||
MMG5_int | ref, | ||
double | hmin, | ||
double | hmax, | ||
double | hausd | ||
) |
mesh | pointer toward the mesh structure. |
sol | pointer toward the sol structure. |
typ | type of entity (triangle, edge,...). |
ref | reference of the entity. |
hmin | minimal edge size. |
hmax | maximal edge size. |
hausd | value of the Hausdorff number. |
Set local parameters: set the hausdorff value at val for all elements of type typ and reference ref.
SUBROUTINE MMG2D_SET_LOCALPARAMETER(mesh,sol,typ,ref,&
hmin,hmax,hausd,retval)
MMG5_DATA_PTR_T,INTENT(INOUT) :: mesh,sol
INTEGER, INTENT(IN) :: typ
INTEGER(MMG5F_INT), INTENT(IN):: ref
REAL(KIND=8), INTENT(IN) :: hmin,hmax,hausd
INTEGER, INTENT(OUT) :: retval
END SUBROUTINE
Definition at line 366 of file API_functions_2d.c.
LIBMMG2D_EXPORT int MMG2D_Set_lsBaseReference | ( | MMG5_pMesh | mesh, |
MMG5_pSol | sol, | ||
MMG5_int | br | ||
) |
mesh | pointer toward the mesh structure. |
sol | pointer toward the sol structure. |
br | new level-set base reference. |
Set a new level-set base reference of ref br in ls discretization mode. Based references are boundary conditions to which implicit domain can be attached. All implicit volumes that are not attached to listed base references are deleted as spurious volumes by the rmc option.
SUBROUTINE MMG2D_SET_LSBASEREFERENCE(mesh,sol,br,retval)
MMG5_DATA_PTR_T,INTENT(INOUT) :: mesh,sol
INTEGER(MMG5F_INT), INTENT(IN):: br
INTEGER, INTENT(OUT) :: retval
END SUBROUTINE
Definition at line 459 of file API_functions_2d.c.
LIBMMG2D_EXPORT int MMG2D_Set_meshSize | ( | MMG5_pMesh | mesh, |
MMG5_int | np, | ||
MMG5_int | nt, | ||
MMG5_int | nquad, | ||
MMG5_int | na | ||
) |
mesh | pointer toward the mesh structure. |
np | number of vertices. |
nt | number of triangles. |
nquad | number of quads. |
na | number of edges. |
Set the number of vertices, triangles, quadrilaterals and edges of the mesh and allocate the associated tables. If call twice, reset the whole mesh to realloc it at the new size
SUBROUTINE MMG2D_SET_MESHSIZE(mesh,np,nt,nquad,na,retval)
MMG5_DATA_PTR_T,INTENT(INOUT) :: mesh
INTEGER(MMG5F_INT) :: np,nt,nquad,na
INTEGER, INTENT(OUT) :: retval
END SUBROUTINE
Definition at line 464 of file API_functions_2d.c.
LIBMMG2D_EXPORT int MMG2D_Set_multiMat | ( | MMG5_pMesh | mesh, |
MMG5_pSol | sol, | ||
MMG5_int | ref, | ||
int | split, | ||
MMG5_int | rin, | ||
MMG5_int | rex | ||
) |
mesh | pointer toward the mesh structure. |
sol | pointer toward the sol structure. |
ref | input tetra reference. |
split | MMG5_MMAT_NoSplit if the entity must not be splitted, MMG5_MMAT_Split otherwise |
rin | internal reference after ls discretization |
rex | external reference after ls discretization |
Set the reference mapping for the elements of ref ref in ls discretization mode.
SUBROUTINE MMG2D_SET_MULTIMAT(mesh,sol,ref,split,rin,rex,retval)
MMG5_DATA_PTR_T,INTENT(INOUT) :: mesh,sol
INTEGER(MMG5F_INT), INTENT(IN):: ref,rin,rex
INTEGER, INTENT(IN) :: split
INTEGER, INTENT(OUT) :: retval
END SUBROUTINE
Definition at line 454 of file API_functions_2d.c.
LIBMMG2D_EXPORT int MMG2D_Set_outputMeshName | ( | MMG5_pMesh | mesh, |
const char * | meshout | ||
) |
mesh | pointer toward the mesh structure. |
meshout | name of the output mesh file. |
Set the name of output mesh file.
SUBROUTINE MMG2D_SET_OUTPUTMESHNAME(mesh,meshout,strlen0,retval)
MMG5_DATA_PTR_T, INTENT(INOUT) :: mesh
CHARACTER(LEN=*), INTENT(IN) :: meshout
INTEGER, INTENT(IN) :: strlen0
INTEGER, INTENT(OUT) :: retval
END SUBROUTINE
Definition at line 72 of file API_functions_2d.c.
LIBMMG2D_EXPORT int MMG2D_Set_outputSolName | ( | MMG5_pMesh | mesh, |
MMG5_pSol | sol, | ||
const char * | solout | ||
) |
mesh | pointer toward the mesh structure. |
sol | pointer toward the sol structure. |
solout | name of the output solution file. |
Set the name of output solution file.
SUBROUTINE MMG2D_SET_OUTPUTSOLNAME(mesh,sol,solout,strlen0,retval)
MMG5_DATA_PTR_T, INTENT(INOUT) :: mesh,sol
CHARACTER(LEN=*), INTENT(IN) :: solout
INTEGER, INTENT(IN) :: strlen0
INTEGER, INTENT(OUT) :: retval
END SUBROUTINE
Definition at line 77 of file API_functions_2d.c.
LIBMMG2D_EXPORT int MMG2D_Set_parallelEdge | ( | MMG5_pMesh | mesh, |
MMG5_int | k | ||
) |
mesh | pointer toward the mesh structure. |
k | edge index. |
Set edge k as parallel.
SUBROUTINE MMG2D_SET_PARALLELEDGE(mesh,k,retval)
MMG5_DATA_PTR_T,INTENT(INOUT) :: mesh
INTEGER(MMG5F_INT), INTENT(IN):: k
INTEGER, INTENT(OUT) :: retval
END SUBROUTINE
Definition at line 1281 of file API_functions_2d.c.
LIBMMG2D_EXPORT int MMG2D_Set_quadrilateral | ( | MMG5_pMesh | mesh, |
MMG5_int | v0, | ||
MMG5_int | v1, | ||
MMG5_int | v2, | ||
MMG5_int | v3, | ||
MMG5_int | ref, | ||
MMG5_int | pos | ||
) |
mesh | pointer toward the mesh structure. |
v0 | first vertex of quadrilateral. |
v1 | second vertex of quadrilateral. |
v2 | third vertex of quadrilateral. |
v3 | fourth vertex of quadrilateral. |
ref | quadrilateral reference. |
pos | quadrilateral position in the mesh. |
Set quadrangle of vertices v0, v1,v2,v3 and reference ref at position pos in mesh structure (from 1 to nb_quad included).
SUBROUTINE MMG2D_SET_QUADRILATERAL(mesh,v0,v1,v2,v3,ref,pos,retval)
MMG5_DATA_PTR_T,INTENT(INOUT) :: mesh
INTEGER(MMG5F_INT), INTENT(IN):: v0,v1,v2,v3,ref,pos
INTEGER, INTENT(OUT) :: retval
END SUBROUTINE
Definition at line 1091 of file API_functions_2d.c.
LIBMMG2D_EXPORT int MMG2D_Set_quadrilaterals | ( | MMG5_pMesh | mesh, |
MMG5_int * | quadra, | ||
MMG5_int * | refs | ||
) |
mesh | pointer toward the mesh structure. |
quadra | vertices of the quadrilaterals of the mesh Vertices of the quadrilateral are stored in quadra[(i-1)*4]@4. |
refs | table of the quadrangles references. References of the quad is stored in refs[i-1]. |
Set vertices and references of the mesh quadrilaterals.
! SUBROUTINE MMG2D_SET_QUADRILATERALS(mesh,quadra,refs,retval)
! MMG5_DATA_PTR_T,INTENT(INOUT) :: mesh
! INTEGER(MMG5F_INT), DIMENSION(*), INTENT(IN) :: quadra,refs
! INTEGER, INTENT(OUT) :: retval
! END SUBROUTINE
Definition at line 1171 of file API_functions_2d.c.
LIBMMG2D_EXPORT int MMG2D_Set_requiredEdge | ( | MMG5_pMesh | mesh, |
MMG5_int | k | ||
) |
mesh | pointer toward the mesh structure. |
k | edge index. |
Set edge k as required.
SUBROUTINE MMG2D_SET_REQUIREDEDGE(mesh,k,retval)
MMG5_DATA_PTR_T,INTENT(INOUT) :: mesh
INTEGER(MMG5F_INT), INTENT(IN):: k
INTEGER, INTENT(OUT) :: retval
END SUBROUTINE
Definition at line 1257 of file API_functions_2d.c.
LIBMMG2D_EXPORT int MMG2D_Set_requiredTriangle | ( | MMG5_pMesh | mesh, |
MMG5_int | k | ||
) |
mesh | pointer toward the mesh structure. |
k | triangle index. |
Set triangle k as required.
SUBROUTINE MMG2D_SET_REQUIREDTRIANGLE(mesh,k,retval)
MMG5_DATA_PTR_T,INTENT(INOUT) :: mesh
INTEGER(MMG5F_INT), INTENT(IN):: k
INTEGER, INTENT(OUT) :: retval
END SUBROUTINE
Definition at line 936 of file API_functions_2d.c.
LIBMMG2D_EXPORT int MMG2D_Set_requiredVertex | ( | MMG5_pMesh | mesh, |
MMG5_int | k | ||
) |
mesh | pointer toward the mesh structure. |
k | vertex index. |
Set point k as required.
SUBROUTINE MMG2D_SET_REQUIREDVERTEX(mesh,k,retval)
MMG5_DATA_PTR_T,INTENT(INOUT) :: mesh
INTEGER(MMG5F_INT), INTENT(IN):: k
INTEGER, INTENT(OUT) :: retval
END SUBROUTINE
Definition at line 725 of file API_functions_2d.c.
LIBMMG2D_EXPORT int MMG2D_Set_scalarSol | ( | MMG5_pSol | met, |
double | s, | ||
MMG5_int | pos | ||
) |
met | pointer toward the sol structure. |
s | solution scalar value. |
pos | position of the solution in the mesh. |
Set scalar value s at position pos in solution structure. (pos from 1 to nb_vertices included).
SUBROUTINE MMG2D_SET_SCALARSOL(met,s,pos,retval)
MMG5_DATA_PTR_T,INTENT(INOUT) :: met
REAL(KIND=8), INTENT(IN) :: s
INTEGER(MMG5F_INT), INTENT(IN):: pos
INTEGER, INTENT(OUT) :: retval
END SUBROUTINE
Definition at line 1429 of file API_functions_2d.c.
LIBMMG2D_EXPORT int MMG2D_Set_scalarSols | ( | MMG5_pSol | met, |
double * | s | ||
) |
met | pointer toward the sol structure. |
s | table of the scalar solutions values. s[i-1] is the solution at vertex i. |
Set scalar solutions at mesh vertices.
SUBROUTINE MMG2D_SET_SCALARSOLS(met,s,retval)
MMG5_DATA_PTR_T,INTENT(INOUT) :: met
REAL(KIND=8),DIMENSION(*), INTENT(IN) :: s
INTEGER, INTENT(OUT) :: retval
END SUBROUTINE
Definition at line 1490 of file API_functions_2d.c.
LIBMMG2D_EXPORT int MMG2D_Set_solsAtVerticesSize | ( | MMG5_pMesh | mesh, |
MMG5_pSol * | sol, | ||
int | nsols, | ||
MMG5_int | nentities, | ||
int * | typSol | ||
) |
mesh | pointer toward the mesh structure. |
sol | pointer toward an allocatable sol structure. |
nsols | number of solutions per entity |
nentities | number of entities |
typSol | Array of size nsol listing the type of the solutions (scalar, vectorial...). |
Initialize an array of solutions field defined at vertices: set dimension, types and number of data. To use to initialize an array of solution fields (not used by Mmg itself).
SUBROUTINE MMG2D_SET_SOLSATVERTICESSIZE(mesh,sol,nsols,nentities,typSol,retval)
MMG5_DATA_PTR_T,INTENT(INOUT) :: mesh,sol
INTEGER, INTENT(IN) :: nsols
INTEGER(MMG5F_INT), INTENT(IN):: nentities
INTEGER, INTENT(IN) :: typSol(*)
INTEGER, INTENT(OUT) :: retval
END SUBROUTINE
Sol tab allocation
Definition at line 550 of file API_functions_2d.c.
LIBMMG2D_EXPORT int MMG2D_Set_solSize | ( | MMG5_pMesh | mesh, |
MMG5_pSol | sol, | ||
int | typEntity, | ||
MMG5_int | np, | ||
int | typSol | ||
) |
mesh | pointer toward the mesh structure. |
sol | pointer toward the sol structure. |
typEntity | type of solutions entities (vertices, triangles...). |
np | number of solutions. |
typSol | type of solution (scalar, vectorial...). |
Initialize an array of solutions field: set dimension, types and number of data. To use to initialize an array of solution fields (not used by Mmg itself).
SUBROUTINE MMG2D_SET_SOLSIZE(mesh,sol,typEntity,np,typSol,retval)
MMG5_DATA_PTR_T,INTENT(INOUT) :: mesh,sol
INTEGER, INTENT(IN) :: typEntity
INTEGER(MMG5F_INT), INTENT(IN):: np
INTEGER, INTENT(IN) :: typSol
INTEGER, INTENT(OUT) :: retval
END SUBROUTINE
Definition at line 506 of file API_functions_2d.c.
LIBMMG2D_EXPORT int MMG2D_Set_tensorSol | ( | MMG5_pSol | met, |
double | m11, | ||
double | m12, | ||
double | m22, | ||
MMG5_int | pos | ||
) |
met | pointer toward the sol structure. |
m11 | value at position (1,1) in the solution tensor. |
m12 | value at position (1,2) in the solution tensor. |
m22 | value at position (2,2) in the solution tensor. |
pos | position of the solution in the mesh. |
Set tensor value s at position pos in solution structure (pos from 1 to nb_vertices included).
SUBROUTINE MMG2D_SET_TENSORSOL(met,m11,m12,m22,pos,retval)
MMG5_DATA_PTR_T,INTENT(INOUT) :: met
REAL(KIND=8), INTENT(IN) :: m11,m12,m22
INTEGER(MMG5F_INT), INTENT(IN):: pos
INTEGER, INTENT(OUT) :: retval
END SUBROUTINE
Definition at line 1626 of file API_functions_2d.c.
LIBMMG2D_EXPORT int MMG2D_Set_tensorSols | ( | MMG5_pSol | met, |
double * | sols | ||
) |
met | pointer toward the sol structure. |
sols | table of the tensorial solutions. sols[3*(i-1)]@3 is the solution at vertex i |
Set tensorial values at position pos in solution structure.
SUBROUTINE MMG2D_SET_TENSORSOLS(met,sols,retval)
MMG5_DATA_PTR_T,INTENT(INOUT) :: met
REAL(KIND=8),DIMENSION(*), INTENT(IN) :: sols
INTEGER, INTENT(OUT) :: retval
END SUBROUTINE
Definition at line 1694 of file API_functions_2d.c.
LIBMMG2D_EXPORT int MMG2D_Set_triangle | ( | MMG5_pMesh | mesh, |
MMG5_int | v0, | ||
MMG5_int | v1, | ||
MMG5_int | v2, | ||
MMG5_int | ref, | ||
MMG5_int | pos | ||
) |
mesh | pointer toward the mesh structure. |
v0 | first vertex of triangle. |
v1 | second vertex of triangle. |
v2 | third vertex of triangle. |
ref | triangle reference. |
pos | triangle position in the mesh. |
Set triangle of vertices v0, v1, v2 and reference ref at position pos in mesh structure (from 1 to nb_tria included).
SUBROUTINE MMG2D_SET_TRIANGLE(mesh,v0,v1,v2,ref,pos,retval)
MMG5_DATA_PTR_T,INTENT(INOUT) :: mesh
INTEGER(MMG5F_INT), INTENT(IN):: v0,v1,v2,ref,pos
INTEGER, INTENT(OUT) :: retval
END SUBROUTINE
Definition at line 860 of file API_functions_2d.c.
LIBMMG2D_EXPORT int MMG2D_Set_triangles | ( | MMG5_pMesh | mesh, |
MMG5_int * | tria, | ||
MMG5_int * | refs | ||
) |
mesh | pointer toward the mesh structure. |
tria | pointer toward the table of the tria vertices. Vertices of the tria are stored in tria[(i-1)*3]@3. |
refs | pointer toward the table of the triangle references. refs[i-1] is the ref of the tria. |
Set vertices and references of the mesh triangles.
! SUBROUTINE MMG2D_SET_TRIANGLES(mesh,tria,refs,retval)
! MMG5_DATA_PTR_T,INTENT(INOUT) :: mesh
! INTEGER(MMG5F_INT),DIMENSION(*), INTENT(IN) :: tria,refs
! INTEGER, INTENT(OUT) :: retval
! END SUBROUTINE
Definition at line 1007 of file API_functions_2d.c.
LIBMMG2D_EXPORT int MMG2D_Set_vectorSol | ( | MMG5_pSol | met, |
double | vx, | ||
double | vy, | ||
MMG5_int | pos | ||
) |
met | pointer toward the sol structure. |
vx | x value of the vectorial solution. |
vy | y value of the vectorial solution. |
pos | position of the solution in the mesh (begin to 1). |
Set vectorial value at position pos in solution structure. ( pos from 1 to nb_vertices included).
SUBROUTINE MMG2D_SET_VECTORSOL(met,vx,vy,pos,retval)
MMG5_DATA_PTR_T,INTENT(INOUT) :: met
REAL(KIND=8), INTENT(IN) :: vx,vy
INTEGER(MMG5F_INT), INTENT(IN):: pos
INTEGER, INTENT(OUT) :: retval
END SUBROUTINE
Definition at line 1516 of file API_functions_2d.c.
LIBMMG2D_EXPORT int MMG2D_Set_vectorSols | ( | MMG5_pSol | met, |
double * | sols | ||
) |
met | pointer toward the sol structure. |
sols | table of the vectorial solutions sols[2*(i-1)]@2 is the solution at vertex i |
Set vectorial solutions at mesh vertices
SUBROUTINE MMG2D_SET_VECTORSOLS(met,sols,retval)
MMG5_DATA_PTR_T,INTENT(INOUT) :: met
REAL(KIND=8),DIMENSION(*), INTENT(IN):: sols
INTEGER, INTENT(OUT) :: retval
END SUBROUTINE
Definition at line 1588 of file API_functions_2d.c.
LIBMMG2D_EXPORT int MMG2D_Set_vertex | ( | MMG5_pMesh | mesh, |
double | c0, | ||
double | c1, | ||
MMG5_int | ref, | ||
MMG5_int | pos | ||
) |
mesh | pointer toward the mesh structure. |
c0 | coordinate of the point along the first dimension. |
c1 | coordinate of the point along the second dimension. |
ref | point reference. |
pos | position of the point in the mesh. |
Set vertex of coordinates c0, c1 and reference ref at position pos in mesh structure (from 1 to nb_vertices included)..
SUBROUTINE MMG2D_SET_VERTEX(mesh,c0,c1,ref,pos,retval)
MMG5_DATA_PTR_T,INTENT(INOUT) :: mesh
REAL(KIND=8), INTENT(IN) :: c0,c1
INTEGER(MMG5F_INT), INTENT(IN):: ref,pos
INTEGER, INTENT(OUT) :: retval
END SUBROUTINE
Definition at line 673 of file API_functions_2d.c.
LIBMMG2D_EXPORT int MMG2D_Set_vertices | ( | MMG5_pMesh | mesh, |
double * | vertices, | ||
MMG5_int * | refs | ||
) |
mesh | pointer toward the mesh structure. |
vertices | table of the points coor. The coordinates of the point are stored in vertices[(i-1)*2]@2 |
refs | table of points references. The ref of the point is stored in refs[i-1]. |
Set vertices coordinates and references in mesh structure
! SUBROUTINE MMG2D_SET_VERTICES(mesh,vertices,refs,retval)
! MMG5_DATA_PTR_T,INTENT(INOUT) :: mesh
! REAL(KIND=8), DIMENSION(*),INTENT(IN) :: vertices
! INTEGER(MMG5F_INT),DIMENSION(*), INTENT(IN):: refs
! INTEGER, INTENT(OUT) :: retval
! END SUBROUTINE
Definition at line 797 of file API_functions_2d.c.
LIBMMG2D_EXPORT void MMG2D_setfunc | ( | MMG5_pMesh | mesh, |
MMG5_pSol | met | ||
) |
mesh | pointer toward the mesh structure. |
met | pointer toward a sol structure. |
Set function pointers for length, caltri... depending if case is iso or aniso
SUBROUTINE MMG2D_SETFUNC(mesh,met)
MMG5_DATA_PTR_T, INTENT(IN) :: mesh,met
END SUBROUTINE
Definition at line 38 of file libmmg2d_tools.c.
LIBMMG2D_EXPORT int MMG2D_Unset_corner | ( | MMG5_pMesh | mesh, |
MMG5_int | k | ||
) |
mesh | pointer toward the mesh structure. |
k | vertex index. |
Remove corner attribute at point pos (from 1 to nb_vertices included).
SUBROUTINE MMG2D_UNSET_CORNER(mesh,k,retval)
MMG5_DATA_PTR_T,INTENT(INOUT) :: mesh
INTEGER(MMG5F_INT), INTENT(IN):: k
INTEGER, INTENT(OUT) :: retval
END SUBROUTINE
Definition at line 719 of file API_functions_2d.c.
LIBMMG2D_EXPORT int MMG2D_Unset_requiredEdge | ( | MMG5_pMesh | mesh, |
MMG5_int | k | ||
) |
mesh | pointer toward the mesh structure. |
k | edge index. |
Remove required attribute from edge k.
SUBROUTINE MMG2D_UNSET_REQUIREDEDGE(mesh,k,retval)
MMG5_DATA_PTR_T,INTENT(INOUT) :: mesh
INTEGER(MMG5F_INT), INTENT(IN):: k
INTEGER, INTENT(OUT) :: retval
END SUBROUTINE
Definition at line 1269 of file API_functions_2d.c.
LIBMMG2D_EXPORT int MMG2D_Unset_requiredTriangle | ( | MMG5_pMesh | mesh, |
MMG5_int | k | ||
) |
mesh | pointer toward the mesh structure. |
k | triangle index. |
Remove required attribute from triangle k.
SUBROUTINE MMG2D_UNSET_REQUIREDTRIANGLE(mesh,k,retval)
MMG5_DATA_PTR_T,INTENT(INOUT) :: mesh
INTEGER(MMG5F_INT), INTENT(IN):: k
INTEGER, INTENT(OUT) :: retval
END SUBROUTINE
Definition at line 949 of file API_functions_2d.c.
LIBMMG2D_EXPORT int MMG2D_Unset_requiredVertex | ( | MMG5_pMesh | mesh, |
MMG5_int | k | ||
) |
mesh | pointer toward the mesh structure. |
k | vertex index. |
Remove required attribute from point k.
SUBROUTINE MMG2D_UNSET_REQUIREDVERTEX(mesh,k,retval)
MMG5_DATA_PTR_T,INTENT(INOUT) :: mesh
INTEGER(MMG5F_INT), INTENT(IN):: k
INTEGER, INTENT(OUT) :: retval
END SUBROUTINE
Definition at line 732 of file API_functions_2d.c.
LIBMMG2D_EXPORT int MMG2D_usage | ( | char * | prog | ) |
prog | pointer toward the program name. |
return | 1 if success, 0 if fail. |
Print help for mmg2d options.
SUBROUTINE MMG2D_USAGE(prog,strlen0,retval)
CHARACTER(LEN=*), INTENT(IN) :: prog
INTEGER, INTENT(IN) :: strlen0
INTEGER, INTENT(OUT) :: retval
END SUBROUTINE
Definition at line 68 of file libmmg2d_tools.c.
|
extern |
mesh | pointer toward the mesh structure |
met | pointer toward the sol structure |
Compute unit tensor according to the lengths of the edges passing through a point.
SUBROUTINE MMG2D_DOSOL(mesh,met,retval)
MMG5_DATA_PTR_T, INTENT(INOUT) :: mesh,met
INTEGER, INTENT(OUT) :: retval
END SUBROUTINE
Definition at line 9 of file mmg2dexterns.c.