Sie sind auf Seite 1von 2

[ p, t ] = mesh2d ( vertices, edge, hdata, options ); where:

vertices, required input, a V by 2 list of (X,Y) coordinates of vertices of the boundary. If vertices is the only input argument, then it must be the case that the vertices are listed consecutively. Otherwise, assuming edge is supplied, the vertices can be given in any order. edge, optional input, a V by 2 list of pairs of indices in the vertices array that constitute the edges of the polygonal boundary. If vertices is actually already in order, then edge, if specified, would contain the values [1,2; 2,3; 3,4; ... ; V,1]. hdata, optional input, a structure containing element size information (see below). options, optional input that allows the user to modify the default behavior of the solver (see below). p, (output), an N by 2 list of node coordinates. The number of nodes generated, N, is determined in part by the size of the edges along the boundary, and by other user input such as the maximum element size, and the user size function, if supplied. t, (output), an M by 3 list of node indices, forming counterclockwise triangles. The number of triangles created depends on the number of nodes created.

hdata, the element size information. This structure, if supplied, can include the following information:

hdata.hmax, the maximum allowable global element size. hdata.edgeh, an array of element sizes on specified geometry edges, where e1 is an index into the edge array. The edgeh component would have the form [e1,h1; e2,h2; ...], where the user has specified a certain number of sizes. hdata.fun, the name of a function preceded by an AT sign, which is the user-defined size function. fun must have the form h = fun ( x, y, args{} ) where x and y are vectors of point coordinates, and args is an optional addition set of input set in hdata.args. The function returns the user-desired elementsize at the given points.

hdata.args = {arg1, arg2, ...} contains additional arguments, if any, for hdata.fun.

options allows the user to modify the default behavior of the solver. This structure, if supplied, can include the following information:

options.mlim is the convergence tolerance. The maximum relative change in edge length per iteration must be less than this value, which defaults to 0.02. options.maxit, the maximum allowable number of iterations, which defaults to 20. options.dhmax, the maximum allowable (relative) gradient in the size function, which defaults to 0.3. options.output, a "logical" variable which displays the mesh and the mesh statistics upon completion, and defaults to "TRUE", that is, 1.

Das könnte Ihnen auch gefallen