segments are splitted)
in order to meet the imposed refinement conditions.refine.MESH.2D(mesh, minimum_angle, maximum_area, delaunay, verbosity)nodesnodesmarkersnodesattributestrianglesorder = 1) or #triangles-by-6 (when order = 2) matrix.
This option is used when a triangulation is already available. It specifies the triangles giving the row's indices in nodes of the triangles' vertices and (when nodes = 2) also if the triangles' edges midpoints. The triangles' vertices and midpoints are ordered as described
at
https://www.cs.cmu.edu/~quake/triangle.highorder.html.edgesedgesmarkersedge is a boundary edge;
an entry '0' indicates that the corresponding edge is not a boundary edge.neighborsholesorderorder = 1.create.MESH.2D, create.FEM.basis## Upload the Meuse data and a domain boundary for these data
data(MeuseData)
data(MeuseBorder)
## Create a Constrained Delaunay triangulation
mesh <- create.MESH.2D(nodes = MeuseData[,c(2,3)], segments = MeuseBorder, order = 1)
## Plot the mesh
plot(mesh)
## Refine the triangulation
mesh_refine <- refine.MESH.2D(mesh, minimum_angle = 30, maximum_area = 10000)
plot(mesh_refine)Run the code above in your browser using DataLab