Name

gf_mesh_fem — General constructor for mesh_fem objects (Finite Element basis functions on a mesh).

Calling Sequence

mesh_fem MF = gf_mesh_fem(mesh M [, int Qdim=1])
mesh_fem MF[,M] = gf_mesh_fem('load', string filename[,mesh M])
mesh_fem MF[,M] = gf_mesh_fem('from string', string S [,mesh M])
mesh_fem MF = gf_mesh_fem('clone', mesh_fem MF0)
mesh_fem MF = gf_mesh_fem('partial', mesh_fem mf, vec DOFs[, vec RCVs])
mesh_fem MF = gf_mesh_fem('global function', mesh m, level_set ls, [gl F1,...][, int Qdim_m])
    

Description

This function creates a mesh_fem object. These objects hold the finite element basis functions on a mesh : a finite element is assigned to each convex of the mesh, and the mesh_fem takes care of connecting them across the convexes and enumerating the degrees of freedom.

gf_mesh_fem(M,Qdim) creates a new mesh_fem object linked to the mesh M. mesh_fem objects can be used everywhere a const_mesh object is required (its linked mesh is automatically used). The argument Qdim specifies the dimension of the unknown on this mesh. If the unknown is a scalar field, then Qdim=1, if it is a 2D vector field then Qdim=2 etc...: this is independent of the mesh dimension.

The load command can restore a previously saved mesh_fem object. If you don't specify the mesh argument, it is assumed that the mesh was saved in the same file that the mesh_fem (with gf_mesh_fem_get(mf, 'save with mesh')). The 'from string' command is very similar, but loads the object from a string instead of a file.

And finally, it is possible to build a copy of a mesh_fem object with the gf_mesh_fem('clone', MF0) command (see also the gf_mesh('clone') command).

  • gf_mesh_fem('load', string fname[, Mesh m]) Load a MeshFem from a file. If the mesh m is not supplied (this kind of file does not store the mesh), then it is read from the file fname and its descriptor is returned as the second output argument.

  • gf_mesh_fem('from string', string [, mesh M]) Create a MeshFem object from its string description. See also gf_mesh_fem_get(mf,'char')

  • gf_mesh_fem('clone', MeshFem mf2) Create a copy of a MeshFem.

  • gf_mesh_fem('sum', MeshFem mf1, MeshFem mf2[, MeshFem mf3[, ...]]) Create a MeshFem that combines two (or more) MeshFem's. All MeshFem must share the same mesh (see gf_fem('interpolated_fem') to map a MeshFem onto another). After that, you should not modify the FEM of mf1, mf2 etc.

  • gf_mesh_fem('levelset', MeshFem mf, LevelSet ls) Create a MeshFem that is conformal to implicit surfaces defined by LevelSet's.

  • gf_mesh_fem('partial', MeshFem mf, vec DOFs[,vec RCVs]) Build a restricted MeshFem by keeping only a subset of the degrees of freedom of mf. If RCVs is given, no FEM will be put on the convexes listed in RCVs.

  • gf_mesh_fem('.mesh', Mesh m[, int Qdim=1]) Build a new MeshFem object. The Qdim parameter is optional.

  • gf_mesh_fem('partial', mesh_fem mf, vec DOFs[, vec RCVs]) creates a special restricted mesh_fem by keeping only a subset of the degrees of freedom of a pre-existing mesh_fem `mf`.

    If `RCVs` is given, no FEM will be put on the convexes listed in `RCVs`.

  • gf_mesh_fem('global function', mesh m, level_set ls, [gl F1,...][, int Qdim_m]) Create a mesh_fem whose base functions are global function given by the user.

See Also

gf_mesh_fem_set, gf_mesh_fem_get

Authors

Y. Collette