initial upload
This commit is contained in:
74
docs/pages/mstkla/GenRegion.md
Executable file
74
docs/pages/mstkla/GenRegion.md
Executable file
@@ -0,0 +1,74 @@
|
||||
---
|
||||
GENERATOR: 'Mozilla/4.05C-SGI [en] (X11; I; IRIX64 6.5 IP28) [Netscape]'
|
||||
---
|
||||
<img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/arrow2.gif">"30"
|
||||
"30"](mstkla.md#GENERIC%20MESH%20REGION%20QUERIES:) <img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/arrow3.gif">"30"
|
||||
"30"](MeshVertex.md) <img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/arrow4.gif">"30"
|
||||
"30"](Geom.md)
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
**GENERIC REGION TYPE OPERATORS**
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
*int* **RType\_NumVerts**(*ElType* type);
|
||||
|
||||
Number of vertices for a generic element of a particular type
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
*int* **RType\_NumEdges**(*ElType* type);
|
||||
|
||||
Number of edges for a generic element of a particular type
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
*int* **RType\_NumFaces**(*ElType* type);
|
||||
|
||||
Number of faces for a generic element of a particular type
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
*void* **RType\_EdgeVertMap**(*ElType* type, *int* ienum, *int*
|
||||
|
||||
*evnums);
|
||||
|
||||
Get the local vertex numbers for local edge 'ienum' of element type.
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
*void* **RType\_FaceVertMap**(*ElType* type, *int* ifnum, *int*
|
||||
*nfv,
|
||||
*int*
|
||||
*
|
||||
*fvnums);
|
||||
|
||||
Get the local vertex numbers for local facee 'ifnum' of element type.
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
*void* **RType\_FaceEdgeMap**(*ElType* type, *int* ifnum, *int*
|
||||
*nfe,
|
||||
*int*
|
||||
*
|
||||
*fenums);
|
||||
|
||||
Get the local edge numbers for local face 'ifnum' of element type.
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
*void* **RType\_EdgeVertMap**(*ElType* type, *int* ienum, *int*
|
||||
|
||||
*evnums);
|
||||
|
||||
Get the local vertex numbers for local edge 'ienum' of element type.
|
||||
|
||||
|
||||
|
||||
<img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/arrow2.gif">"30"
|
||||
"30"](mstkla.md#GENERIC%20MESH%20REGION%20QUERIES:) <img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/arrow3.gif">"30"
|
||||
"30"](MeshVertex.md) <img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/arrow4.gif">"30"
|
||||
"30"](Geom.md)
|
||||
89
docs/pages/mstkla/Geom.md
Executable file
89
docs/pages/mstkla/Geom.md
Executable file
@@ -0,0 +1,89 @@
|
||||
---
|
||||
GENERATOR: 'Mozilla/4.05C-SGI [en] (X11; I; IRIX64 6.5 IP28) [Netscape]'
|
||||
---
|
||||
<img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/arrow2.gif">"30"
|
||||
"30"](mstkla.md#GMTKLA_Init) <img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/arrow3.gif">"30"
|
||||
"30"](GenRegion.md) <img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/arrow4.gif">"30"
|
||||
"30"](GeomEntity.md)
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
**GEOMETRIC MODEL INITIALIZATION:**
|
||||
|
||||
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
*void* **GMTKLA\_Init**(*void*);
|
||||
|
||||
Initialize the geometric model interface (does nothing for now but
|
||||
|
||||
include it for completeness sake).
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
**MODEL OPERATORS:**
|
||||
|
||||
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
*int* **GM\_NumRegions**(*void*);
|
||||
|
||||
Number of model regions. Note this has nothing to do with number of
|
||||
|
||||
material attributes. That is the analysis preprocessing concern not
|
||||
|
||||
the mesh generator's or the geometric modeler's. The number of model
|
||||
|
||||
regions refers to the number of distinct volumes in the geometric
|
||||
|
||||
model.
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
*int* **GM\_NumFaces**(*void*);
|
||||
|
||||
Number of model faces. For now, this just returns the number of
|
||||
|
||||
surfaces in the geometric model although they are strictly not the
|
||||
|
||||
same.
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
*PGeomRegn* **GM\_Region**(*int* i);
|
||||
|
||||
Return the i'th geometric model region
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
*PGeomFace* **GM\_Face**(*int* i);
|
||||
|
||||
Return the i'th geometric model face
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
*void* **GM\_Regions**(*int*
|
||||
*nr, *PGeomRegn*
|
||||
*
|
||||
*gregs);
|
||||
|
||||
Get all the model regions
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
*void* **GM\_Faces**(*int*
|
||||
*nf, *PGeomFace*
|
||||
*
|
||||
*gfaces);
|
||||
|
||||
Get all the model faces
|
||||
<img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/arrow2.gif">"30"
|
||||
"30"](mstkla.md#GMTKLA_Init) <img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/arrow3.gif">"30"
|
||||
"30"](GenRegion.md) <img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/arrow4.gif">"30"
|
||||
"30"](GeomEntity.md)
|
||||
46
docs/pages/mstkla/GeomEdge.md
Executable file
46
docs/pages/mstkla/GeomEdge.md
Executable file
@@ -0,0 +1,46 @@
|
||||
---
|
||||
GENERATOR: 'Mozilla/4.05C-SGI [en] (X11; I; IRIX64 6.5 IP28) [Netscape]'
|
||||
---
|
||||
<img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/arrow2.gif">"30"
|
||||
"30"](mstkla.md#MODEL%20EDGE:) <img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/arrow3.gif">"30"
|
||||
"30"](GeomFace.md) <img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/arrow4.gif">"30"
|
||||
"30"](GeomVertex.md)
|
||||
|
||||
<img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/construction14.gif">"169" "131"
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
*int* **GEs\_AreSame**(*PGeomEdge* pe1, *PGeomEdge* pe2)
|
||||
|
||||
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
*void* **GE\_Faces**(*PGeomEdge* pe, *int*
|
||||
*nf, *PGeomFace*
|
||||
*
|
||||
*faces)
|
||||
|
||||
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
*void* **GE\_Regions**(*PGeomEdge* pe, *int*
|
||||
*nr, *PGeomRegn*
|
||||
|
||||
*
|
||||
*regns)
|
||||
|
||||
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
*int* **GE\_OnBoundary**(*PGeomEdge* pe, *PGeomEntity* gent)
|
||||
|
||||
|
||||
|
||||
|
||||
<img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/arrow2.gif">"30"
|
||||
"30"](mstkla.md#MODEL%20EDGE:) <img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/arrow3.gif">"30"
|
||||
"30"](GeomFace.md) <img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/arrow4.gif">"30"
|
||||
"30"](GeomVertex.md)
|
||||
88
docs/pages/mstkla/GeomEntity.md
Executable file
88
docs/pages/mstkla/GeomEntity.md
Executable file
@@ -0,0 +1,88 @@
|
||||
---
|
||||
GENERATOR: 'Mozilla/4.05C-SGI [en] (X11; I; IRIX64 6.5 IP28) [Netscape]'
|
||||
---
|
||||
<img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/arrow2.gif">"30"
|
||||
"30"](mstkla.md#MODEL%20ENTITY:) <img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/arrow3.gif">"30"
|
||||
"30"](Geom.md) <img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/arrow4.gif">"30"
|
||||
"30"](GeomRegion.md)
|
||||
|
||||
<img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/construction14.gif">"169" "131"
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
**MODEL ENTITY OPERATORS:**
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
*GType* **GEnt\_Type**(*PGeomEntity* gent);
|
||||
|
||||
Type of a geometric model entity (GREGION, GFACE, GEDGE, GVERTEX,
|
||||
|
||||
GUNKNOWN). Typically can be used in conjunction with the operator to
|
||||
|
||||
get mesh entity classification. So one can get the model entity a mesh
|
||||
|
||||
vertex is on, query what type it is and do something based on the
|
||||
|
||||
response (e.g. reposition the vertex only if it is classified in a
|
||||
|
||||
model region).
|
||||
|
||||
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
*int* **GEnt\_Number**(*PGeomEntity* gent);
|
||||
|
||||
ID Number of geometric model entity. Can be called instead of
|
||||
|
||||
GR\_Number, GF\_Number, GE\_Number and GV\_Number.
|
||||
|
||||
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
*int* **GEnt\_OnBoundary**(*PGeomEntity* g1, *PGeomEntity* g2);
|
||||
|
||||
Check if g2 is on the boundary of g1 (Check if a face is on the
|
||||
|
||||
boundary of a region, an edge is on the boundary of a face, a vertex
|
||||
|
||||
is on the boundary of a region)
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
*int* **GEnts\_Common**(*int* nent, *GType*
|
||||
*types, *PGeomEntity*
|
||||
|
||||
*gents, *int*
|
||||
*ncm, *GType*
|
||||
*ctypes, *PGeomEntity*
|
||||
*cgents)
|
||||
|
||||
Given *nent* entitities (the entity pointers given in *gents* and their
|
||||
types in *types*), find their common entities, *cgents*. The entities
|
||||
will be of the lowest order possible (but higher than the highest order
|
||||
of the input entities). For example, if we were given two model edges
|
||||
connected by one common face, the output would be this common face. On
|
||||
the other hand if these edges were not connected by a common face but
|
||||
the faces connected to them are on the boundary of the same model
|
||||
region, the model region would be returned as a common entity.
|
||||
Naturally, there may be more than one such common model entity in
|
||||
general geometric models.
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
*int* **GEnt\_OnExtBoundary**(*PGeomEntity* gent)
|
||||
|
||||
Check if model entity is on external boundary
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
|
||||
<img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/arrow2.gif">"30"
|
||||
"30"](mstkla.md#MODEL%20ENTITY:) <img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/arrow3.gif">"30"
|
||||
"30"](Geom.md) <img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/arrow4.gif">"30"
|
||||
"30"](GeomRegion.md)
|
||||
40
docs/pages/mstkla/GeomFace.md
Executable file
40
docs/pages/mstkla/GeomFace.md
Executable file
@@ -0,0 +1,40 @@
|
||||
---
|
||||
GENERATOR: 'Mozilla/4.05C-SGI [en] (X11; I; IRIX64 6.5 IP28) [Netscape]'
|
||||
---
|
||||
<img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/arrow2.gif">"30"
|
||||
"30"](mstkla.md#MODEL%20FACE:) <img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/arrow3.gif">"30"
|
||||
"30"](GeomRegion.md) <img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/arrow4.gif">"30"
|
||||
"30"](GeomEdge.md)
|
||||
|
||||
<img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/construction14.gif">"169" "131"
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
**MODEL FACE OPERATORS:**
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
*void* **GF\_Regions**(*PGeomFace* gf, *PGeomRegn* gr[2]);
|
||||
|
||||
Get the regions on either side of the face. gr[0] is the region on
|
||||
the
|
||||
|
||||
opposite side of the normal while gr[1] is the region on the same
|
||||
side
|
||||
|
||||
of the normal. In principle (not in LaGriT), both entries of gr may
|
||||
|
||||
be filled \_AND\_ gr[0] may be equal to gr[1]. Also in principle,
|
||||
both
|
||||
|
||||
entries of gr may be NULL.
|
||||
|
||||
|
||||
|
||||
|
||||
<img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/arrow2.gif">"30"
|
||||
"30"](mstkla.md#MODEL%20REGION:) <img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/arrow3.gif">"30"
|
||||
"30"](GeomRegion.md) <img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/arrow4.gif">"30"
|
||||
"30"](GeomEdge.md)
|
||||
60
docs/pages/mstkla/GeomRegion.md
Executable file
60
docs/pages/mstkla/GeomRegion.md
Executable file
@@ -0,0 +1,60 @@
|
||||
---
|
||||
GENERATOR: 'Mozilla/4.05C-SGI [en] (X11; I; IRIX64 6.5 IP28) [Netscape]'
|
||||
---
|
||||
<img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/arrow2.gif">"30"
|
||||
"30"](mstkla.md#MODEL%20REGION:) <img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/arrow3.gif">"30"
|
||||
"30"](GeomEntity.md) <img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/arrow4.gif">"30"
|
||||
"30"](GeomFace.md)
|
||||
|
||||
<img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/construction14.gif">"169" "131"
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
**MODEL REGION OPERATORS:**
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
*void* **GR\_Faces**(*PGeomRegn* gr, *int*
|
||||
*nf, *PGeomFace*
|
||||
*faces);
|
||||
|
||||
Get the model faces that form the boundary of a model region.
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
*int* **GR\_FaceDir**(*PGeomRegn* gr, *PGeomFace* gf);
|
||||
|
||||
Get the sense in which a model region is using a face, i.e., is the
|
||||
|
||||
face normal pointing into the region (return value 0), out of the
|
||||
|
||||
region (return value 1), both (return value 2) or none (return value
|
||||
|
||||
-1).
|
||||
*
|
||||
*
|
||||
*
|
||||
*
|
||||
* MUST VERIFY THiS WITH CODE VALUES
|
||||
*
|
||||
*
|
||||
*
|
||||
*
|
||||
*
|
||||
*
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
*int* **GR\_OnBoundary**(*PGeomRegn* this, *PGeomEntity* gent);
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
<img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/arrow2.gif">"30"
|
||||
"30"](mstkla.md#MODEL%20REGION:) <img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/arrow3.gif">"30"
|
||||
"30"](GeomEntity.md) <img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/arrow4.gif">"30"
|
||||
"30"](GeomFace.md)
|
||||
11
docs/pages/mstkla/GeomVertex.md
Executable file
11
docs/pages/mstkla/GeomVertex.md
Executable file
@@ -0,0 +1,11 @@
|
||||
---
|
||||
GENERATOR: 'Mozilla/4.05C-SGI [en] (X11; I; IRIX64 6.5 IP28) [Netscape]'
|
||||
---
|
||||
<img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/arrow2.gif">"30"
|
||||
"30"](mstkla.md#MODEL%20VERTEX) <img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/arrow3.gif">"30"
|
||||
"30"](GeomEdge.md) <img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/arrow4.gif">"30"
|
||||
"30"](utilities.md)
|
||||
<img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/construction14.gif">"169" "131"<img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/arrow2.gif">"30"
|
||||
"30"](mstkla.md#MODEL%20VERTEX) <img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/arrow3.gif">"30"
|
||||
"30"](GeomEdge.md) <img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/arrow4.gif">"30"
|
||||
"30"](utilities.md)
|
||||
308
docs/pages/mstkla/Mesh.md
Executable file
308
docs/pages/mstkla/Mesh.md
Executable file
@@ -0,0 +1,308 @@
|
||||
---
|
||||
GENERATOR: 'Mozilla/4.05C-SGI [en] (X11; I; IRIX64 6.5 IP28) [Netscape]'
|
||||
---
|
||||
<img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/arrow2.gif">"30"
|
||||
"30"](http://www.ees.lanl.gov/staff/rao/mstkla/mstkla.md#MSTKLA_Init) <img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/arrow3.gif">"30"
|
||||
"30"](http://www.ees.lanl.gov/staff/rao/mstkla/prelim.md) <img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/arrow4.gif">"30"
|
||||
"30"](http://www.ees.lanl.gov/staff/rao/mstkla/MeshRegion.md)
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
**MESH INITIALIZATION:**
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
|
||||
|
||||
*void* **MSTKLA\_Init**(*void*);
|
||||
|
||||
Initialize the mesh toolkit.
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
**MESH OPERATORS**
|
||||
|
||||
|
||||
|
||||
These operators work on variables of type *PMeshObj.*
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
*PMeshObj* **MESH\_Create**();
|
||||
|
||||
Creates a default mesh object and returns it - At this point all the
|
||||
info
|
||||
|
||||
in it is useless.
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
*void* **MESH\_InitFromFile**(*PMeshObj* mesh, *char
|
||||
**filename, *char
|
||||
|
||||
**format, *int* iotype, *char
|
||||
*
|
||||
**name);
|
||||
|
||||
Read a mesh in from "*filename*" and initialize the "*mesh*".
|
||||
|
||||
The file is in the format "*format*" ("*lagrit*" for LaGriT dumps,
|
||||
"*gmv*" for GMV files, "*avs*" for AVS files).
|
||||
|
||||
*'iotype'* is 1 for ascii and 0 for binary.
|
||||
|
||||
'*name*' is the name of the mesh that is read and returned
|
||||
|
||||
If a LaGriT file is read, the geometric model info will be read as well.
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
*void* **MESH\_InitFromCMO**(*PMeshObj* mesh, *char*
|
||||
*cmoname);
|
||||
|
||||
Initialize the mesh object from a given cmo. If '*cmoname*' is NULL (say
|
||||
sent in as the character string ), the mesh object is initialized from
|
||||
the default mesh object. If not the given cmo is made is active and the
|
||||
mesh object is
|
||||
|
||||
initialized from that.
|
||||
|
||||
<img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/note1.gif">"31" "32"This implies that
|
||||
sometime in the middle of a LaGriT subroutine, one can call a C routine
|
||||
which initializes a mesh object and then uses the functionality of
|
||||
MSTKLA!! (Cool!)
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
*int* **MESH\_Select**(*PMeshObj* mesh);
|
||||
|
||||
Make a particular mesh object active
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
*void* **MESH\_Delete**(*PMeshObj* mesh);
|
||||
|
||||
Delete a particular mesh object.
|
||||
|
||||
<img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/note1.gif">"31" "32"
|
||||
*
|
||||
* NOT YET IMPLEMENTED
|
||||
|
||||
*
|
||||
* WILL BE IN SOON
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
*void* **MESH\_WriteToFile**(*PMeshObj* mesh, *char*
|
||||
*filename, *char*
|
||||
|
||||
*format, *int* iotype);
|
||||
|
||||
<img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/note1.gif">"31" "32"
|
||||
*
|
||||
* NOT YET IMPLEMENTED
|
||||
|
||||
*
|
||||
* WILL BE IN SOON
|
||||
*
|
||||
*
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
*PMeshObj* **MESH\_Duplicate**(*PMeshObj* mesh);
|
||||
|
||||
<img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/note1.gif">"31" "32"
|
||||
*
|
||||
* NOT YET IMPLEMENTED
|
||||
|
||||
*
|
||||
*
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
*int* **MESH\_NumVertices**(*PMeshObj* mesh);
|
||||
|
||||
Number of vertices (nodes) in the mesh.
|
||||
|
||||
<img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/bullet12.gif">"27" "31"
|
||||
*
|
||||
*
|
||||
* IMPORTANT
|
||||
|
||||
*
|
||||
*
|
||||
*
|
||||
|
||||
This count may include deleted vertices, parent vertices and other
|
||||
|
||||
types of vertices that should be ignored. So when looping through
|
||||
|
||||
vertices of a mesh, one should check if the vertex is to be ignored
|
||||
|
||||
by checking if MV\_Type returns VIGNORE or VDELETED.
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
*int* **MESH\_NumRegions**(*PMeshObj* mesh);
|
||||
|
||||
Number of regions (elements) in the mesh.
|
||||
|
||||
<img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/bullet12.gif">"27" "31"
|
||||
*
|
||||
*
|
||||
* IMPORTANT
|
||||
|
||||
*
|
||||
*
|
||||
*
|
||||
|
||||
This count may include deleted regions. While looping through the
|
||||
|
||||
regions of a mesh, one should check if the region is to be ignored
|
||||
|
||||
by checking if MR\_Type returns RDELETED.
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
*PMeshVert* **MESH\_Vertex**(*PMeshObj* mesh, *int* i);
|
||||
|
||||
Fetch the i'th vertex (node) of the mesh (This is C so remember i
|
||||
|
||||
starts from 0) The returned mesh vertex object can be queried for
|
||||
|
||||
information. The returned vertex must always be checked for its type
|
||||
|
||||
to see if it deleted or must otherwise be ignored.
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
*PMeshRegn* **MESH\_Region**(*PMeshObj* mesh, *int* i);
|
||||
|
||||
Fetch the i'th region (element) of the mesh. The returned mesh region
|
||||
|
||||
can be queried for information. The returned region must be checked if
|
||||
|
||||
it is a deleted region.
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
*void* **MESH\_BldUpAdj**(*PMeshObj* mesh);
|
||||
|
||||
Build the vertex to region connectivity. This will allow upward
|
||||
|
||||
adjacency operator MV\_Regions to be called. In fact those operators
|
||||
|
||||
will function properly only after this is called.
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
*void* **MESH\_DelUpAdj**(*PMeshObj* mesh);
|
||||
|
||||
Delete the vertex to region connectivity information to save
|
||||
|
||||
memory. It is not possible for MSTKLA to determine when this
|
||||
|
||||
information is not needed and call this routine automatically.
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
*void* **MESH\_IncrNodeLists**(*PMeshObj* mesh);
|
||||
|
||||
Increment all the node lists.
|
||||
|
||||
<img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/note1.gif">"31" "32"(
|
||||
*
|
||||
* NOT FULLY TESTED
|
||||
|
||||
*
|
||||
*)
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
*void* **MESH\_IncrElemLists**(*PMeshObj* mesh);
|
||||
|
||||
Increment all the element lists.
|
||||
|
||||
<img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/note1.gif">"31" "32"(
|
||||
*
|
||||
* NOT FULLY TESTED
|
||||
|
||||
*
|
||||
*)
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
*void* **MESH\_CmprNodeLists**(*PMeshObj* mesh);
|
||||
|
||||
Compress all the element lists.
|
||||
|
||||
<img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/note1.gif">"31" "32"
|
||||
*
|
||||
*
|
||||
* NOT YET
|
||||
IMPLEMENTED
|
||||
*
|
||||
*
|
||||
*
|
||||
|
||||
<img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/bullet12.gif">"27" "31"
|
||||
*
|
||||
*
|
||||
* IMPORTANT !!!
|
||||
|
||||
*
|
||||
*
|
||||
*
|
||||
|
||||
There is one side effect of compression of lists. If one is storing a
|
||||
|
||||
list of node numbers or PMeshVerts (which for the LaGriT interface are
|
||||
|
||||
just integers cast as pointers), then after compression, the node
|
||||
|
||||
numbers or PMeshVert "addresses" may not be referring to the nodes you
|
||||
|
||||
think they are.
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
*void* **MESH\_CmprElemLists**(*PMeshObj* mesh);
|
||||
|
||||
Compress all the element lists.
|
||||
*
|
||||
*
|
||||
* NOT YET IMPLEMENTED
|
||||
*
|
||||
*
|
||||
*
|
||||
|
||||
<img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/bullet12.gif">"27" "31"
|
||||
*
|
||||
*
|
||||
* IMPORTANT !!!
|
||||
|
||||
*
|
||||
*
|
||||
*
|
||||
|
||||
There is one side effect of compression of lists. If one is storing a
|
||||
|
||||
list of element numbers or PMeshRegns (which for the LaGriT interface
|
||||
|
||||
are just integers cast as pointers), then after compression, the
|
||||
|
||||
element numbers or PMeshRegn "addresses" may not be referring to the
|
||||
|
||||
elements you think they are.
|
||||
|
||||
|
||||
|
||||
|
||||
<img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/arrow2.gif">"30"
|
||||
"30"](http://www.ees.lanl.gov/staff/rao/mstkla/mstkla.md#MSTKLA_Init) <img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/arrow3.gif">"30"
|
||||
"30"](http://www.ees.lanl.gov/staff/rao/mstkla/prelim.md) <img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/arrow4.gif">"30"
|
||||
"30"](http://www.ees.lanl.gov/staff/rao/mstkla/MeshRegion.md)
|
||||
140
docs/pages/mstkla/MeshAttributes.md
Executable file
140
docs/pages/mstkla/MeshAttributes.md
Executable file
@@ -0,0 +1,140 @@
|
||||
---
|
||||
GENERATOR: 'Mozilla/4.05C-SGI [en] (X11; I; IRIX64 6.5 IP28) [Netscape]'
|
||||
---
|
||||
<img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/arrow2.gif">"30"
|
||||
"30"](mstkla.md#MESH%20VERTEX:) <img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/arrow3.gif">"30"
|
||||
"30"](MeshEdge.md) <img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/arrow4.gif">"30"
|
||||
"30"](GenRegion.md)
|
||||
|
||||
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
**MESH ATTRIBUTE OPERATORS**
|
||||
|
||||
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
*void* **MESH\_AddAtt**(*PMeshObj* mesh, *char
|
||||
**attname, *AttType*
|
||||
attype, *Rank* rank,
|
||||
|
||||
*MType* mtype, *Interp* interp, *int* persist, *char
|
||||
**ioflags,
|
||||
*double* defval);
|
||||
|
||||
*AttType*, *Rank* and *Interp* are typedef enums which are available if
|
||||
one
|
||||
|
||||
includes "*mstkla.h*". The specific names (which are pretty much the
|
||||
strings
|
||||
|
||||
that are used in LaGriT) are given in *mstkla\_types.h* (See [MSTKLA
|
||||
typedefs](prelim.md))
|
||||
|
||||
'persist' must be 0 for temporary atts and 1 for permanent attribs
|
||||
|
||||
'ioflags' is a string as in lagrit (may be any combination of 'a', 'g',
|
||||
'f', 's', 'x', 'no' for
|
||||
|
||||
AVS, GMV, FEHM, SGI, LaGriT or None)
|
||||
|
||||
mtype is **MVERTEX** if the attribute is to be node based and is
|
||||
**MFACE** or
|
||||
|
||||
**MREGION** if the attribute is to be element based depending on whether
|
||||
the mesh
|
||||
|
||||
is 2D or 3D respectively.
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
*void* **MESH\_ModAtt**(*PMeshObj* mesh, *char
|
||||
**attname, *char
|
||||
|
||||
**fieldname, *int* inew,
|
||||
|
||||
*double* rnew, *char
|
||||
**cnew);
|
||||
|
||||
Here depending on the fieldname, one has to fill the right value for
|
||||
inew,
|
||||
|
||||
rnew or cnew.
|
||||
|
||||
*
|
||||
*
|
||||
* NOT TESTED
|
||||
*
|
||||
*
|
||||
*
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
*void* **MESH\_CopyAtt**(*PMeshObj* trgmsh, *PMeshObj* srcmsh, *char*
|
||||
|
||||
*trgatt, *char*
|
||||
*srcatt);
|
||||
|
||||
*
|
||||
*
|
||||
* NOT TESTED
|
||||
*
|
||||
*
|
||||
*
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
*void* **MESH\_DelAtt**(*PMeshObj* mesh, *char
|
||||
**attname);
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
*void* **MESH\_SetAtt**(*PMeshObj* mesh, *char
|
||||
**attname, *int* ifirst,
|
||||
*int* ilast, *int*
|
||||
|
||||
istride, *char
|
||||
**psetname, *double* value);
|
||||
|
||||
If psetname is specified ifirst is ignored
|
||||
|
||||
*
|
||||
*
|
||||
* NOT TESTED
|
||||
*
|
||||
*
|
||||
*
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
Once attributes have been created, one can go to an individual mesh
|
||||
entity
|
||||
|
||||
and ask for the value of an attribute for that entity or change the
|
||||
value.
|
||||
|
||||
The entities can be Mesh Vertices (always), Mesh Faces (for a surface
|
||||
mesh
|
||||
|
||||
only), Mesh Regions (for a solid mesh only).
|
||||
|
||||
For example one can use **MR\_GetAttVal** operator to get the value of
|
||||
an
|
||||
|
||||
attribute for a given element or use **MR\_SetAttVal** to set it.
|
||||
|
||||
See attribute operators for[Mesh Vertices](MeshVertex.md#MV-Attribs),[Mesh Regions](MeshRegion.md#MR-Attribs) and [Mesh
|
||||
Faces](MeshFace.md#MF-Attribs)
|
||||
|
||||
|
||||
<img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/arrow2.gif">"30"
|
||||
"30"](mstkla.md#MESH%20VERTEX:) <img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/arrow3.gif">"30"
|
||||
"30"](MeshEdge.md) <img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/arrow4.gif">"30"
|
||||
"30"](GenRegion.md)
|
||||
219
docs/pages/mstkla/MeshEdge.md
Executable file
219
docs/pages/mstkla/MeshEdge.md
Executable file
@@ -0,0 +1,219 @@
|
||||
---
|
||||
GENERATOR: 'Mozilla/4.05C-SGI [en] (X11; I; IRIX64 6.5 IP28) [Netscape]'
|
||||
---
|
||||
<img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/arrow2.gif">"30"
|
||||
"30"](http://www.ees.lanl.gov/staff/rao/mstkla/mstkla.md#MESH%20EDGE:) <img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/arrow3.gif">"30"
|
||||
"30"](http://www.ees.lanl.gov/staff/rao/mstkla/MeshFace.md) <img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/arrow4.gif">"30"
|
||||
"30"](http://www.ees.lanl.gov/staff/rao/mstkla/MeshVertex.md)
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
**MESH EDGES:**
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
Since LaGriT does not really store mesh edges, the mesh edge data
|
||||
|
||||
structure (*MeshEdge*, *PMeshEdge*) is created on the fly whenever edge
|
||||
|
||||
information is requested. Therefore after utilizing the edge(s) get
|
||||
|
||||
information, it (they) should be destroyed by calling ME\_Delete
|
||||
|
||||
operator.
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
*int* **ME\_Number**(*PMeshObj* mesh, *PMeshEdge* e);
|
||||
|
||||
*
|
||||
* This will return 0 for now since I haven't yet decided on a good
|
||||
|
||||
*
|
||||
* way to assign a unique number to the (virtual) edges of the mesh.
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
*void* **ME\_Delete**(*PMeshEdge* e);
|
||||
|
||||
Free the data structure associated with this edge created on the fly.
|
||||
|
||||
(There is an operator for creation but I cannot yet imagine needing to
|
||||
|
||||
make that a publicly available operator).
|
||||
|
||||
<img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/bullet12.gif">"27" "31"
|
||||
*
|
||||
* IMPORTANT
|
||||
*
|
||||
*
|
||||
|
||||
ME\_Delete will not remove any connections in the mesh. It just destroys
|
||||
the
|
||||
|
||||
temporary data structure used to store the edge info
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
*int* **ME\_IsParent**(*PMeshObj* mesh, *PMeshEdge* pe);
|
||||
|
||||
If both vertices of the edge are parents, the edge is a parent.
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
*PMeshEdge* **ME\_Parent**(*PMeshObj* mesh, *PMeshEdge* pe);
|
||||
|
||||
The parents of each vertex of the edge are obtained and a new 'parent'
|
||||
|
||||
edge is constructed from them.
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
*void* **ME\_Children**(*PMeshObj* mesh, *PMeshEdge* pe, *int*
|
||||
*nec,
|
||||
*PMeshEdge*
|
||||
*
|
||||
*ec);
|
||||
|
||||
<img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/note1.gif">"31" "32"
|
||||
*
|
||||
*
|
||||
* NOT YET
|
||||
IMPLEMENTED
|
||||
*
|
||||
*
|
||||
*
|
||||
|
||||
Child vertices of the face are found and appropriate combinations of
|
||||
these vertices are used to construct the new 'child' faces. For a
|
||||
combination to be appropriate, the vertices of the child face has to
|
||||
point to the same material region.
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
*int* **MEs\_areSame**(*PMeshEdge* e1, *PMeshEdge* e2);
|
||||
|
||||
Compare the data in two MeshEdge data structures and see if they
|
||||
|
||||
represent the same connection in the mesh. This operator is needed
|
||||
|
||||
since the on-the-fly *PMeshEdge* pointers may not be the same and they
|
||||
|
||||
do not directly point to any persistent "object" in the database.
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
*PGeomEntity* **ME\_GMentity**(*PMeshObj* mesh, *PMeshEdge* e);
|
||||
|
||||
Return the geometric model entity the edge is on. In the absence of
|
||||
explicit
|
||||
|
||||
edge representation in the database, this may be problematic in a few
|
||||
cases
|
||||
|
||||
cases where multiple classifications are possible.
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
*GType* **ME\_GMtype**(*PMeshObj* mesh, *PMeshEdge* e);
|
||||
|
||||
Return the type of geometric model entity the edge is on. This (I
|
||||
|
||||
think) is more deterministically found from the classifications of its
|
||||
|
||||
vertices but still there may be some incorrect cases. The way around
|
||||
|
||||
is complicated and will not be implemented for now.
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
*PMeshVert* **ME\_Vertex**(*PMeshObj* mesh, *PMeshEdge* e, *int* i);
|
||||
|
||||
Return the i'th vertex of the mesh edge. i can only be 0 or 1.
|
||||
|
||||
Parent edges return parent vertices and child edges return child
|
||||
vertices.
|
||||
|
||||
If a vertex is not on an interface the vertex itself is returned.
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
<img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/new1.gif">"31" "12"*PMeshVert*
|
||||
**ME\_OtherVertex**(*PMeshObj* mesh, *PMeshEdge* e, *PMeshVert* v);
|
||||
|
||||
Return the other vertex of the mesh edge (obviously the one that is not
|
||||
v).
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
*void* **ME\_Faces**(*PMeshObj* mesh, *PMeshEdge* e, *int*
|
||||
*nef,
|
||||
*PMeshFace*
|
||||
*
|
||||
*efaces);
|
||||
|
||||
Get the "faces" of an "edge". The faces data structures are also
|
||||
|
||||
constructed on the fly since they do not exist in the LaGriT
|
||||
|
||||
database. Also, as with other upward connectivity queries, this can
|
||||
|
||||
execute usefully only if the routine MESH\_BldUpAdj is called
|
||||
|
||||
beforehand. Also, see note on freeing the *PMeshFace* structures listed
|
||||
|
||||
under MV\_Edges and MV\_Faces.
|
||||
|
||||
The behavior of this operator for parent and child edges is similar to
|
||||
|
||||
MV\_Edges.
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
*void* **ME\_Regions**(*PMeshObj* mesh, *PMeshEdge* e, *int*
|
||||
*ner,
|
||||
*PMeshRegn*
|
||||
*
|
||||
*eregions);
|
||||
|
||||
Get the regions connected to an edge. MESH\_BldUpAdj must be called
|
||||
before this operator can be called usefully.
|
||||
|
||||
The behavior of this operator for child and parent edges is similar to
|
||||
|
||||
that of MV\_Regions.
|
||||
|
||||
<img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/bullet12.gif">"27" "31"
|
||||
*
|
||||
* IMPORTANT
|
||||
*
|
||||
*
|
||||
|
||||
Since MESH\_BldUpAdj builds explicit upward adjacency information, this
|
||||
|
||||
routine does not require a seed region to be provided. Also, this
|
||||
|
||||
routine will work regardless of whether there is a complete cycle of
|
||||
|
||||
regions around the edge and whether the edge is an arbitrary type of
|
||||
|
||||
non-manifold edge!!
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
*int* **ME\_EntOnBdry**(*PMeshObj* mesh, *PMeshEdge* pe, *PMeshVert*e
|
||||
pv);
|
||||
|
||||
Check if vertex is on the boundary of edge. In other words, is this
|
||||
|
||||
vertex one of the edges vertices.
|
||||
|
||||
|
||||
|
||||
|
||||
<img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/arrow2.gif">"30"
|
||||
"30"](http://www.ees.lanl.gov/staff/rao/mstkla/mstkla.md#MESH%20EDGE:) <img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/arrow3.gif">"30"
|
||||
"30"](http://www.ees.lanl.gov/staff/rao/mstkla/MeshFace.md) <img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/arrow4.gif">"30"
|
||||
"30"](http://www.ees.lanl.gov/staff/rao/mstkla/MeshVertex.md)
|
||||
286
docs/pages/mstkla/MeshFace.md
Executable file
286
docs/pages/mstkla/MeshFace.md
Executable file
@@ -0,0 +1,286 @@
|
||||
---
|
||||
GENERATOR: 'Mozilla/4.05C-SGI [en] (X11; I; IRIX64 6.5 IP28) [Netscape]'
|
||||
---
|
||||
<img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/arrow2.gif">"30"
|
||||
"30"](http://www.ees.lanl.gov/staff/rao/mstkla/mstkla.md#MESH%20FACE:) <img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/arrow3.gif">"30"
|
||||
"30"](http://www.ees.lanl.gov/staff/rao/mstkla/MeshRegion.md) <img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/arrow4.gif">"30"
|
||||
"30"](http://www.ees.lanl.gov/staff/rao/mstkla/MeshEdge.md)
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
**MESH FACES:**
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
Since LaGriT does not really store mesh faces, the mesh face data
|
||||
|
||||
structure (MeshFace, *PMeshFace*) is created on the fly whenever face
|
||||
|
||||
information is requested. Therefore after utilizing the face(s) get
|
||||
|
||||
information, it (they) should be destroyed by calling MF\_Delete
|
||||
|
||||
operator.
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
*int* **MF\_Number**(*PMeshObj* mesh, *PMeshFace* f);
|
||||
|
||||
<img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/note1.gif">"31" "32"
|
||||
*
|
||||
* This will return 0
|
||||
for now since I haven't yet decided on a good
|
||||
|
||||
*
|
||||
* way to assign a unique number to the (virtual) faces of the mesh.
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
*void* **MF\_Delete**(*PMeshFace* f);
|
||||
|
||||
Free the data structure associated with this face created on the fly.
|
||||
|
||||
(There is an operator for creation but I cannot yet imagine needing to
|
||||
|
||||
make that a publicly available operator).
|
||||
|
||||
<img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/bullet12.gif">"27" "31"
|
||||
*
|
||||
* IMPORTANT
|
||||
*
|
||||
*
|
||||
|
||||
MF\_Delete will not remove any connections in the mesh. It just
|
||||
|
||||
destroys the temporary data structure used to store the face info
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
*int* **MF\_IsParent**(*PMeshObj* mesh, *PMeshFace* pf);
|
||||
|
||||
If all vertices of the face are parents, the face is a parent.
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
*PMeshFace* **MF\_Parent**(*PMeshObj* mesh, *PMeshFace* pf);
|
||||
|
||||
The parents of all vertices of the face are obtained and a new
|
||||
|
||||
'parent' face is constructed from them.
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
*void* **MF\_Children**(*PMeshObj* mesh, *PMeshFace* pf, *int*
|
||||
*nfc,
|
||||
*PMeshFace*
|
||||
*
|
||||
*fc);
|
||||
|
||||
<img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/note1.gif">"31" "32"
|
||||
*
|
||||
*
|
||||
* NOT YET
|
||||
IMPLEMENTED
|
||||
*
|
||||
*
|
||||
*
|
||||
|
||||
Child vertices of the face are found and appropriate combinations of
|
||||
these vertices are used to construct the new 'child' faces. For a
|
||||
combination to be appropriate, the vertices of the child face has to
|
||||
point to the same material region.
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
*int* **MFs\_areSame**(*PMeshObj* mesh, *PMeshFace* f1, *PMeshFace* f2);
|
||||
|
||||
Compare the data in two MeshFace data structures and see if they
|
||||
|
||||
represent the same connection in the mesh. This operator is needed
|
||||
|
||||
since the on-the-fly *PMeshFace* pointers may not be the same and they
|
||||
|
||||
do not directly point to any persistent "object" in the database.
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
*PGeomEntity* **MF\_GMentity**(*PMeshObj* mesh, *PMeshFace* f);
|
||||
|
||||
Return the geometric model entity the face is on. In the absence of
|
||||
|
||||
explicit face representation in the database, this may be problematic
|
||||
|
||||
in a few cases cases where multiple classifications are possible.
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
*GType* **MF\_GMtype**(*PMeshObj* mesh, *PMeshFace* f);
|
||||
|
||||
Return the type of geometric model entity the face is on. This (I
|
||||
|
||||
think) is more deterministically found from the classifications of its
|
||||
|
||||
vertices but some problems may still occur. See Comments in ME\_GMtype.
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
*PMeshVert* **MF\_Vertices**(*PMeshObj* mesh, *PMeshFace* f, *int*
|
||||
|
||||
*nfv, *PMeshVert*ex
|
||||
*
|
||||
*fverts);
|
||||
|
||||
Return the vertices of the mesh face. The vertices are in no
|
||||
|
||||
particular order. Parent faces return parent vertices and child faces
|
||||
|
||||
child vertices. If a vertex is not on an non-manifold boundary
|
||||
|
||||
(interface) the vertex itself is returned.
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
*PMeshVert* **MF\_VerticesOrd**(*PMeshObj* mesh, *PMeshFace* f, *int*
|
||||
|
||||
*nfv, *PMeshVert*ex
|
||||
*
|
||||
*fverts);
|
||||
|
||||
<img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/note1.gif">"31" "32"
|
||||
*
|
||||
* NOT YET IMPLEMENTED
|
||||
|
||||
*
|
||||
*
|
||||
|
||||
Return the vertices of the mesh face. The vertices are ordered such
|
||||
|
||||
that the smallest one is the first. Also, the sequence is such that
|
||||
|
||||
the face points out of the region connected to it or in case there are
|
||||
|
||||
two regions connected to it, such that it points out of the region
|
||||
|
||||
with the lower ID Number. The behavior of the operator for parent and
|
||||
|
||||
child faces is the same as MF\_Vertices
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
*void* **MF\_Edges**(*PMeshObj* mesh, *PMeshFace* f, *int*
|
||||
*nef,
|
||||
*PMeshFace*
|
||||
*
|
||||
*efaces);
|
||||
|
||||
Get the "edges" of an "face". The edges data structures are
|
||||
|
||||
constructed on the fly since they do not exist in the LaGriT
|
||||
|
||||
database. See note on freeing the *PMeshFace* structures listed under
|
||||
|
||||
MV\_Edges and MV\_Faces. Parent faces return parent edges and child
|
||||
|
||||
faces return child edges.
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
*void* **MF\_Regions**(*PMeshObj* mesh, *PMeshFace* f, *PMeshRegn*
|
||||
fregions[2]);
|
||||
|
||||
Get the regions connected to an face. MESH\_BldUpAdj must be called
|
||||
|
||||
before this operator can be called usefully. The regions will be
|
||||
|
||||
returned such that the face 'f' as defined will point out fregions[0]
|
||||
|
||||
(if it exists) and into fregions[1] (if it exists).
|
||||
|
||||
A parent face will return both regions connected to it while a child
|
||||
|
||||
face will return a region only on its side of the interface. If a
|
||||
|
||||
"child" face constructed from interior nodes and child nodes on an
|
||||
|
||||
interface, both regions connected to it are returned.
|
||||
|
||||
<img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/bullet12.gif">"27" "31"
|
||||
*
|
||||
* IMPORTANT
|
||||
*
|
||||
*
|
||||
|
||||
Since MESH\_BldUpAdj builds explicit upward adjacency information, this
|
||||
|
||||
routine does not require a seed region to be provided.
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
*int* **MF\_EntOnBdry**(*PMeshObj* mesh, *PMeshFace* f, MType mtype,
|
||||
PMeshEntity pent);
|
||||
|
||||
Check if mesh entity of type 'mtype' is on the boundary of mesh
|
||||
|
||||
face. mtype can only be MEDGE or MVERTEX. In other words, check if
|
||||
|
||||
mesh face is made up of mesh edge or vertex in question.
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
[]{#MF-Attribs*int* **MF\_GetAttVal**(*PMeshObj* mesh, *PMeshFace* f,
|
||||
*char
|
||||
**attname, *int
|
||||
**ival,
|
||||
|
||||
*double
|
||||
**rval, *char
|
||||
**cval, *void
|
||||
*
|
||||
**pval, *AttType
|
||||
**atype);
|
||||
|
||||
Depending on the type of the attribute, the appropriate field will be
|
||||
|
||||
filled on succesful completion. Arrays are returned in pval, integer in
|
||||
|
||||
ival and real number in rval (I don't think lagrit supports character
|
||||
|
||||
attributes)
|
||||
|
||||
<img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/bullet12.gif">"27" "31" Will only work for
|
||||
surface meshes
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
*int* **MR\_SetAttVal**(*PMeshObj* mesh, *PMeshFace* f, *char
|
||||
|
||||
**attname, *int* ival,
|
||||
|
||||
*double* rval, *char* cval, *void
|
||||
**pval);
|
||||
|
||||
This is similar to the GetAttVal routine - depending on the type and
|
||||
|
||||
rank, one sends in a value with the right variable
|
||||
|
||||
*
|
||||
*
|
||||
* PERHAPS these routines need an additional variable, "rank" but
|
||||
for
|
||||
|
||||
now.....
|
||||
|
||||
|
||||
|
||||
<img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/bullet12.gif">"27" "31" Will only work for
|
||||
surface meshes
|
||||
<img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/arrow2.gif">"30"
|
||||
"30"](http://www.ees.lanl.gov/staff/rao/mstkla/mstkla.md#MESH%20FACE:) <img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/arrow3.gif">"30"
|
||||
"30"](http://www.ees.lanl.gov/staff/rao/mstkla/MeshRegion.md) <img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/arrow4.gif">"30"
|
||||
"30"](http://www.ees.lanl.gov/staff/rao/mstkla/MeshEdge.md)
|
||||
209
docs/pages/mstkla/MeshRegion.md
Executable file
209
docs/pages/mstkla/MeshRegion.md
Executable file
@@ -0,0 +1,209 @@
|
||||
---
|
||||
GENERATOR: 'Mozilla/4.05C-SGI [en] (X11; I; IRIX64 6.5 IP28) [Netscape]'
|
||||
---
|
||||
<img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/arrow2.gif">"30"
|
||||
"30"](http://www.ees.lanl.gov/staff/rao/mstkla/mstkla.md#MESH%20REGION:) <img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/arrow3.gif">"30"
|
||||
"30"](http://www.ees.lanl.gov/staff/rao/mstkla/Mesh.md) <img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/arrow4.gif">"30"
|
||||
"30"](http://www.ees.lanl.gov/staff/rao/mstkla/MeshFace.md)
|
||||
|
||||
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
**MESH REGIONS**:
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
*int* **MR\_Number**(*PMeshObj* mesh, *PMeshRegn* r);
|
||||
|
||||
Number ID for mesh region
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
*PGeomEntity* **MR\_GMEntity**(*PMeshObj* mesh, *PMeshRegn* r);
|
||||
|
||||
Geometric entity (can only be a region) mesh region is classified on
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
*ElType* **MR\_Type**(*PMeshObj* mesh, *PMeshRegn* r);
|
||||
|
||||
Type of element that mesh region is (TET, HEX etc)
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
*int* **MR\_NumVerts**(*PMeshObj* mesh, *PMeshRegn* r);
|
||||
|
||||
Number of vertices in the element
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
*void* **MR\_Vertices**(*PMeshObj* mesh, *PMeshRegn* r, *int*
|
||||
*nv,
|
||||
*PMeshVert*
|
||||
*
|
||||
*verts);
|
||||
|
||||
List of vertices of a mesh region
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
*void* **MR\_VerticesE**(*PMeshObj* mesh, *PMeshRegn* r, *PMeshEdge* e,
|
||||
*PMeshVert*
|
||||
*rverts);
|
||||
|
||||
<img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/note1.gif">"31" "32"**THIS OPERATOR IS
|
||||
APPLICABLE ONLY TO TETS**
|
||||
|
||||
Return the vertices of the given tet w.r.t to the given edge. The
|
||||
|
||||
vertices v1 and v2 are vertices of the edge (maybe (0,1) or (1,0)) -
|
||||
|
||||
these are returned as rverts[0] and rverts[1]. The vertices
|
||||
rverts[2]
|
||||
|
||||
(call it k1) and rverts[3] (k2) are returned such that if the
|
||||
vertices
|
||||
|
||||
are above the edge then looking from vertex 0 to vertex 1 of the edge
|
||||
|
||||
k2 is to the left of k1. Mathematically,
|
||||
|
||||
(v2k1 X v2k2) . v2v1 > 0
|
||||
|
||||
where v2k1 is the vector from v2 to k1, etc.
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
*void* **MR\_VerticesLocE**(*PMeshObj* mesh, *PMeshRegn* r, *int* enum,
|
||||
*PMeshVert*
|
||||
*rverts);
|
||||
|
||||
<img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/note1.gif">"31" "32"**THIS OPERATOR IS
|
||||
APPLICABLE ONLY TO TETS**
|
||||
|
||||
Same as MR\_VerticesE (above) but the edge is specified by a local edge
|
||||
|
||||
number of the region instead of an explicit pointer.
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
*int* **MR\_NumFaces**(*PMeshObj* mesh, *PMeshRegn* r);
|
||||
|
||||
Number of faces of element
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
*void* **MR\_Edges**(*PMeshObj* mesh, *PMeshRegn* r, *int*
|
||||
*num,
|
||||
*PMeshEdge*
|
||||
*
|
||||
*edge);
|
||||
|
||||
List of edges of a mesh region
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
*void* **MR\_Faces**(*PMeshObj* mesh, *PMeshRegn* r, *int*
|
||||
*num,
|
||||
*PMeshFace*
|
||||
*
|
||||
*faces);
|
||||
|
||||
List of faces of a mesh region
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
*int* **MR\_LocEdgeNum**(*PMeshObj* mesh, *PMeshRegn* r, *PMeshEdge* e);
|
||||
|
||||
Local edge number of the given edge in the given region
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
*int* **MR\_LocFaceNum**(*PMeshObj* mesh, *PMeshRegn* r, *PMeshFace* f);
|
||||
|
||||
Local face number of the given face in the given region.
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
*int **MR\_EntOnBdry***(*PMeshObj* mesh, *PMeshRegn* r, MType mtype,
|
||||
PMeshEntity pent);
|
||||
|
||||
Check if mesh entity of type 'mtype' is on the boundary of mesh
|
||||
|
||||
region. mtype can be MFACE, MEDGE or MVERTEX. In other words, the
|
||||
|
||||
operator checks if mesh region is made up of mesh face, edge or vertex
|
||||
|
||||
in question.
|
||||
|
||||
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
*PMeshRegn* **MR\_FaceNebr**(*PMeshObj* mesh, *PMeshRegn* r, *int*
|
||||
lfnum);
|
||||
|
||||
Return the mesh region adjacent to face number 'lfnum' of region 'r'
|
||||
|
||||
The local face numbering starts from 0 in C style.
|
||||
|
||||
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
[]{#MR-Attribs*int* **MR\_GetAttVal**(*PMeshObj* mesh, *PMeshRegn* r,
|
||||
*char
|
||||
**attname, *int
|
||||
**ival,
|
||||
|
||||
*double
|
||||
**rval, *char
|
||||
**cval, *void
|
||||
*
|
||||
**pval, *AttType
|
||||
**atype);
|
||||
|
||||
Depending on the type of the attribute, the appropriate field will be
|
||||
|
||||
filled on succesful completion. Arrays are returned in pval, integer in
|
||||
|
||||
ival and real number in rval (I don't think lagrit supports character
|
||||
|
||||
attributes)
|
||||
|
||||
<img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/bullet12.gif">"27" "31" Will only work for
|
||||
solid meshes
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
*int* **MR\_SetAttVal**(*PMeshObj* mesh, *PMeshRegn* r, *char
|
||||
|
||||
**attname, *int* ival,
|
||||
|
||||
*double* rval, *char* cval, *void
|
||||
**pval);
|
||||
|
||||
This is similar to the GetAttVal routine - depending on the type and
|
||||
|
||||
rank, one sends in a value with the right variable
|
||||
|
||||
*
|
||||
*
|
||||
* PERHAPS these routines need an additional variable, "rank" but
|
||||
for
|
||||
|
||||
now.....
|
||||
|
||||
|
||||
|
||||
<img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/bullet12.gif">"27" "31" Will only work for
|
||||
solid meshes
|
||||
|
||||
|
||||
<img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/arrow2.gif">"30"
|
||||
"30"](http://www.ees.lanl.gov/staff/rao/mstkla/mstkla.md#MESH%20REGION:) <img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/arrow3.gif">"30"
|
||||
"30"](http://www.ees.lanl.gov/staff/rao/mstkla/Mesh.md) <img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/arrow4.gif">"30"
|
||||
"30"](http://www.ees.lanl.gov/staff/rao/mstkla/MeshFace.md)
|
||||
272
docs/pages/mstkla/MeshVertex.md
Executable file
272
docs/pages/mstkla/MeshVertex.md
Executable file
@@ -0,0 +1,272 @@
|
||||
---
|
||||
GENERATOR: 'Mozilla/4.05C-SGI [en] (X11; I; IRIX64 6.5 IP28) [Netscape]'
|
||||
---
|
||||
<img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/arrow2.gif">"30"
|
||||
"30"](http://www.ees.lanl.gov/staff/rao/mstkla/mstkla.md#MESH%20VERTEX:) <img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/arrow3.gif">"30"
|
||||
"30"](http://www.ees.lanl.gov/staff/rao/mstkla/MeshEdge.md) <img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/arrow4.gif">"30"
|
||||
"30"](http://www.ees.lanl.gov/staff/rao/mstkla/GenRegion.md)
|
||||
|
||||
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
**MESH VERTEX OPERATORS**
|
||||
|
||||
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
*int* **MV\_Number**(*PMeshObj* mesh, *PMeshVert* v);
|
||||
|
||||
Return an ID number for the mesh vertex.
|
||||
|
||||
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
*VType* **MV\_Type**(*PMeshObj* mesh, *PMeshVert* v);
|
||||
|
||||
Return the mesh vertex type. Most useful in checking if a mesh vertex
|
||||
|
||||
has been deleted or if it is a parent vertex on an interface
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
*PGeomEntity* **MV\_GMEntity**(*PMeshObj* mesh, *PMeshVert* v);
|
||||
|
||||
Return the geometric model entity the mesh vertex is classified on.
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
*GType* **MV\_GMtype**(*PMeshObj* mesh, *PMeshVert* v);
|
||||
|
||||
Return the type of geometric model entity the mesh vertex is
|
||||
|
||||
classified on (GREGION, GFACE, GEDGE, GVERTEX, GUNKNOWN).
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
*void* **MV\_Coords**(*PMeshObj* mesh, *PMeshVert* v, *double*
|
||||
*xyz);
|
||||
|
||||
Coordinates of mesh vertex
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
*int* **MV\_IsParent**(*PMeshObj* mesh, *PMeshVert* v);
|
||||
|
||||
<img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/note1.gif">"31" "32"A vertex not on an
|
||||
interface is its own parent - return value will be 1
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
*int* **MV\_IsChild**(*PMeshObj* mesh, *PMeshVert* v);
|
||||
|
||||
<img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/note1.gif">"31" "32"A vertex not on an
|
||||
interface is its own child - return value will be 1
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
*PMeshVert* **MV\_Parent**(*PMeshObj* mesh, *PMeshVert* v);
|
||||
|
||||
<img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/note1.gif">"31" "32"For a vertex not on an
|
||||
interface, the vertex itself is returned
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
*void* **MV\_Children**(*PMeshVert* mesh, *PMeshVert* v, *int*
|
||||
*nvc,
|
||||
*PMeshVert*
|
||||
*
|
||||
*vc)
|
||||
|
||||
<img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/note1.gif">"31" "32"For a vertex not on an
|
||||
interface, a 1 item array with the vertex
|
||||
|
||||
pointer itself is returned and nvc = 1
|
||||
|
||||
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
*void* **MV\_Edges**(*PMeshObj* mesh, *PMeshVert* v, *int*
|
||||
*nve,
|
||||
*PMeshEdge*
|
||||
*
|
||||
*vedges);
|
||||
|
||||
List of mesh edges connected to vertex. For this routine to work
|
||||
|
||||
properly, one must call MESH\_BldAdj first. If not the routine will
|
||||
|
||||
just return 0.
|
||||
|
||||
If the vertex is a parent vertex, then the operator will return all
|
||||
|
||||
the edges connected to all the child vertices of the vertex. The edge
|
||||
|
||||
returned will be of type PARENT. Each of these edges will be made up
|
||||
|
||||
of 'v' and any other parent vertex it is connected to. If it is a
|
||||
|
||||
child vertex, then it will return edges connected only to itself. In
|
||||
|
||||
this case all the edges will be of type CHILD. Each edge will be made
|
||||
|
||||
up of the child vertex 'v' and any other child vertex it is connected
|
||||
|
||||
to. Note that vertices on 2-manifold (single material) boundaries and
|
||||
|
||||
in the interior can be considered a parent or a child as required.
|
||||
|
||||
<img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/bullet12.gif">"27" "31"
|
||||
*
|
||||
*
|
||||
* IMPORTANT
|
||||
|
||||
*
|
||||
*
|
||||
*
|
||||
|
||||
When finished with the list of edges, call ME\_Delete on each of the
|
||||
|
||||
edges and free the vedges list. This is important since the MeshEdge
|
||||
|
||||
data structures are created on the fly and the MESH object does not
|
||||
|
||||
keep track of them.
|
||||
|
||||
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
*void* **MV\_Faces**(*PMeshObj* mesh, *PMeshVert* v, *int*
|
||||
*nvf,
|
||||
*PMeshFace*
|
||||
*
|
||||
*vfaces);
|
||||
|
||||
<img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/note1.gif">"31" "32"
|
||||
*
|
||||
* NOT YET TESTED
|
||||
*
|
||||
*
|
||||
|
||||
List of mesh faces connected to vertex. For this routine to work
|
||||
|
||||
properly, one must call MESH\_BldAdj first. If not the routine will
|
||||
|
||||
just return 0.
|
||||
|
||||
The behavior of the operator for parent and child vertices is the same
|
||||
|
||||
as it is for MV\_Edges.
|
||||
|
||||
<img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/bullet12.gif">"27" "31"
|
||||
*
|
||||
*
|
||||
* IMPORTANT
|
||||
|
||||
*
|
||||
*
|
||||
*
|
||||
|
||||
When finished with the list of faces, call MF\_Delete on each of the
|
||||
|
||||
faces and free the vfaces list. This is important since the MeshFace
|
||||
|
||||
data structures are created on the fly and the MESH object does not
|
||||
|
||||
keep track of them.
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
*int* **MV\_numRegions**(*PMeshObj* mesh, *PMeshVert* v);
|
||||
|
||||
Number of mesh regions connected to mesh vertex. For this routine to
|
||||
|
||||
work properly, one must call MESH\_BldUpAdj first. If not the routine
|
||||
|
||||
will just return 0.
|
||||
|
||||
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
*void* **MV\_Regions**(*PMeshObj* mesh, *PMeshVert* v, *int*
|
||||
*nr,
|
||||
*PMeshRegn*
|
||||
*
|
||||
*regns);
|
||||
|
||||
List of mesh regions connected to mesh vertex. For this routine to
|
||||
|
||||
work properly, one must call MESH\_BldUpAdj first. If not the routine
|
||||
|
||||
will just return 0 for the number of regions and a NULL pointer for
|
||||
|
||||
the region list.
|
||||
|
||||
|
||||
|
||||
For a parent vertex, mesh regions in all the material regions
|
||||
|
||||
connected to all its children are returned. For a child vertex, only
|
||||
|
||||
mesh regions in the particular material region pointed to by the child
|
||||
|
||||
are returned.
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
[]{#MV-Attribs*int* **MV\_GetAttVal**(*PMeshObj* mesh, *PMeshVert* v,
|
||||
*char
|
||||
**attname, *int
|
||||
**ival,
|
||||
|
||||
*double
|
||||
**rval, *char
|
||||
**cval, *void
|
||||
*
|
||||
**pval, *AttType
|
||||
**atype);
|
||||
|
||||
Depending on the type of the attribute, the appropriate field will be
|
||||
|
||||
filled on succesful completion. Arrays are returned in pval, integer in
|
||||
|
||||
ival and real number in rval (I don't think lagrit supports character
|
||||
|
||||
attributes)
|
||||
|
||||
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
*int* **MV\_SetAttVal**(*PMeshObj* mesh, *PMeshVert* v, *char
|
||||
|
||||
**attname, *int* ival,
|
||||
|
||||
*double* rval, *char* cval, *void
|
||||
**pval);
|
||||
|
||||
This is similar to the GetAttVal routine - depending on the type and
|
||||
|
||||
rank, one sends in a value with the right variable
|
||||
|
||||
*
|
||||
*
|
||||
* PERHAPS these routines need an additional variable, "rank" but
|
||||
for
|
||||
|
||||
now.....
|
||||
|
||||
|
||||
|
||||
|
||||
<img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/arrow2.gif">"30"
|
||||
"30"](http://www.ees.lanl.gov/staff/rao/mstkla/mstkla.md#MESH%20VERTEX:) <img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/arrow3.gif">"30"
|
||||
"30"](http://www.ees.lanl.gov/staff/rao/mstkla/MeshEdge.md) <img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/arrow4.gif">"30"
|
||||
"30"](http://www.ees.lanl.gov/staff/rao/mstkla/GenRegion.md)
|
||||
525
docs/pages/mstkla/example.md
Executable file
525
docs/pages/mstkla/example.md
Executable file
@@ -0,0 +1,525 @@
|
||||
---
|
||||
GENERATOR: 'Mozilla/4.05C-SGI [en] (X11; I; IRIX64 6.5 IP28) [Netscape]'
|
||||
---
|
||||
|
||||
<img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/arrow2.gif">"30"
|
||||
"30"](mstkla.md#EXAMPLE) <img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/arrow3.gif">"30"
|
||||
"30"](utilities.md) <img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/arrow4.gif">"30"
|
||||
"30"](linking.md)
|
||||
|
||||
/
|
||||
*
|
||||
|
||||
==========================================================================
|
||||
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
|
||||
Example program with MSTKLA
|
||||
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
|
||||
==========================================================================
|
||||
|
||||
*
|
||||
|
||||
#include <stdio.h>
|
||||
|
||||
#include <stdlib.h>
|
||||
|
||||
#include "mstkla.h"
|
||||
|
||||
#include "gmtkla.h"
|
||||
|
||||
int main(int argc, char
|
||||
*argv[]) {
|
||||
|
||||
char
|
||||
*meshname;
|
||||
|
||||
PMeshObj mesh;
|
||||
|
||||
PMeshVert vert, rverts[8];
|
||||
|
||||
PMeshRegn reg, oreg;
|
||||
|
||||
ElType type;
|
||||
|
||||
int nv, nf, nr, nrv, i, j,
|
||||
*rfside, nrf, ngr, ngf;
|
||||
|
||||
double xyz[3];
|
||||
|
||||
PGeomEntity gent;
|
||||
|
||||
PGeomFace
|
||||
*rflist,
|
||||
*gflist;
|
||||
|
||||
PGeomRegn
|
||||
*grlist;
|
||||
|
||||
|
||||
|
||||
***/
|
||||
* Initialization
|
||||
***/*
|
||||
|
||||
|
||||
|
||||
MSTKLA\_Init();
|
||||
|
||||
GMTKLA\_Init();
|
||||
|
||||
|
||||
|
||||
***/
|
||||
* Create a mesh object and fill in the data after reading from a
|
||||
file
|
||||
***/*
|
||||
|
||||
mesh = MESH\_Create();
|
||||
|
||||
MESH\_InitFromFile(mesh, argv[1], argv[2], 1, &meshname);
|
||||
|
||||
|
||||
|
||||
***/
|
||||
* Model info
|
||||
***/*
|
||||
|
||||
|
||||
|
||||
ngr = GM\_NumRegions();
|
||||
|
||||
fprintf(stderr,"Number of model regions: %d
|
||||
|
||||
n",ngr);
|
||||
|
||||
|
||||
|
||||
ngf = GM\_NumFaces();
|
||||
|
||||
fprintf(stderr,"Number of model faces: %d
|
||||
|
||||
n",ngf);
|
||||
|
||||
|
||||
|
||||
***/
|
||||
* Get all the regions in the model
|
||||
***/*
|
||||
|
||||
GM\_Regions(&ngr, &grlist);
|
||||
|
||||
|
||||
|
||||
***/
|
||||
* Loop through the regions and print out info about the faces***
|
||||
|
||||
*** bounding this region***
|
||||
|
||||
***
|
||||
***/*
|
||||
|
||||
|
||||
|
||||
for (i = 0; i < ngr; i++) {
|
||||
|
||||
fprintf(stderr,"Region %-d
|
||||
|
||||
n:
|
||||
|
||||
n",(i+1));
|
||||
|
||||
|
||||
|
||||
***/
|
||||
* Faces of the region
|
||||
***/*
|
||||
|
||||
|
||||
|
||||
GR\_Faces(grlist[i],&nrf,&rflist,&rfside);
|
||||
|
||||
|
||||
|
||||
fprintf(stderr," %d Faces
|
||||
|
||||
n",nrf);
|
||||
|
||||
for (j = 0; j < nrf; j++) {
|
||||
|
||||
fprintf(stderr,"Face %-d Dir %-d Type %-d
|
||||
|
||||
n",
|
||||
|
||||
GF\_Number(rflist[j]),rfside[j],GF\_Type(rflist[j]));
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
for (i = 0; i < ngr; i++)
|
||||
|
||||
GR\_Delete(grlist[i]);
|
||||
|
||||
free(grlist);
|
||||
|
||||
**/*
|
||||
* Just get the all the faces of the model
|
||||
***/*
|
||||
|
||||
*** /
|
||||
* Delete the objects containing that info - the surfaces
|
||||
themselves***
|
||||
|
||||
*** don't get deleted***
|
||||
|
||||
***
|
||||
***/*
|
||||
|
||||
GM\_Faces(&ngf, &gflist);
|
||||
|
||||
for (i = 0; i < ngf; i++)
|
||||
|
||||
GF\_Delete(gflist[i]);
|
||||
|
||||
free(gflist);
|
||||
|
||||
|
||||
|
||||
***/
|
||||
* Mesh Info
|
||||
***/*
|
||||
|
||||
fprintf(stderr,"Number of nodes in
|
||||
mesh:
|
||||
|
||||
t%d
|
||||
|
||||
n",MESH\_NumVertices(mesh));
|
||||
|
||||
fprintf(stderr,"Number of elements in
|
||||
mesh:
|
||||
|
||||
t%d
|
||||
|
||||
n",MESH\_NumRegions(mesh));
|
||||
|
||||
***/
|
||||
* Loop through each mesh vertex and print some info about it
|
||||
|
||||
***/*
|
||||
|
||||
nv = MESH\_NumVertices(mesh);
|
||||
|
||||
for (i = 0; i < nv; i++) {
|
||||
|
||||
vert = MESH\_Vertex(mesh,i);
|
||||
|
||||
if (MV\_Type(mesh,vert) == VDELETED MV\_Type(mesh,vert) ==
|
||||
VIGNORE)
|
||||
|
||||
continue;
|
||||
|
||||
***/
|
||||
* Get the classification (model entity that mesh entity is on)
|
||||
of***
|
||||
|
||||
*** the mesh vertex***
|
||||
|
||||
***
|
||||
***/*
|
||||
|
||||
gent = MV\_GMentity(mesh,vert);
|
||||
|
||||
***/
|
||||
* Get the coordinates of the mesh vertex
|
||||
***/*
|
||||
|
||||
MV\_Coords(mesh, vert, xyz);
|
||||
|
||||
if (gent)
|
||||
|
||||
fprintf(stderr,"V%-d [ G%-d (order %1d) --- %lf %lf %lf
|
||||
|
||||
n",
|
||||
|
||||
MV\_Number(mesh,vert),GEnt\_Number(gent), MV\_GMtype(mesh,vert),
|
||||
|
||||
xyz[0],xyz[1],xyz[2]);
|
||||
|
||||
else
|
||||
|
||||
fprintf(stderr,"V%-d [ G
|
||||
* (order %1d) --- %lf %lf %lf
|
||||
|
||||
n",
|
||||
|
||||
MV\_Number(mesh,vert),MV\_GMtype(mesh,vert),
|
||||
|
||||
xyz[0],xyz[1],xyz[2]);
|
||||
|
||||
|
||||
|
||||
fprintf(stderr,"
|
||||
|
||||
n
|
||||
|
||||
n");
|
||||
|
||||
nr = MESH\_NumRegions(mesh);
|
||||
|
||||
***/
|
||||
* Loop through each mesh regions and print some info about it
|
||||
|
||||
***/*
|
||||
|
||||
for (i = 0; i < nr; i++) {
|
||||
|
||||
reg = MESH\_Region(mesh,i);
|
||||
|
||||
***/
|
||||
* Region type - TET, PYRAMID, PRISM, HEX?
|
||||
***/*
|
||||
|
||||
type = MR\_Type(mesh,reg);
|
||||
|
||||
|
||||
|
||||
***/
|
||||
* Vertices of region aka nodes of element
|
||||
***/*
|
||||
|
||||
MR\_Vertices(mesh, reg, &nrv, (PMeshVert
|
||||
*) rverts);
|
||||
|
||||
|
||||
|
||||
***/
|
||||
* Classification of mesh region i.e. what model region it is in
|
||||
|
||||
***/*
|
||||
|
||||
gent = MR\_GMentity(mesh,reg);
|
||||
|
||||
if (GEnt\_Type(gent) != GREGION)
|
||||
|
||||
fprintf(stderr,"Mesh Region not classified on model
|
||||
region???
|
||||
|
||||
n");
|
||||
|
||||
|
||||
|
||||
fprintf(stderr,"R%-d [ G%-d --- ", MR\_Number(mesh,reg),
|
||||
GEnt\_Number(gent));
|
||||
|
||||
for (j = 0; j < nrv; j++)
|
||||
|
||||
fprintf(stderr,"%d ", MV\_Number(mesh,rverts[j]));
|
||||
|
||||
fprintf(stderr,"
|
||||
|
||||
n");
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
***/
|
||||
* Loop through the regions of the mesh and print the face
|
||||
neighbor info
|
||||
***/*
|
||||
|
||||
for (i = 0; i < nr; i++) {
|
||||
|
||||
reg = MESH\_Region(mesh,i);
|
||||
|
||||
fprintf(stderr,"Region %-d neighbors: ", MR\_Number(mesh,reg));
|
||||
|
||||
type = MR\_Type(mesh,reg);
|
||||
|
||||
nf = RType\_NumFaces(type);
|
||||
|
||||
for (j = 0; j < nf; j++) {
|
||||
|
||||
***/
|
||||
* Find the other region sharing face 'j' of 'reg'
|
||||
***/*
|
||||
|
||||
oreg = MR\_FaceNebr(mesh,reg,j);
|
||||
|
||||
if (oreg) { ***/
|
||||
* a region exists on the other side of face,
|
||||
print info
|
||||
***/*
|
||||
|
||||
fprintf(stderr,"R%-d ",MR\_Number(mesh,oreg));
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
fprintf(stderr,"
|
||||
|
||||
n");
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
<img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/arrow2.gif">"30"
|
||||
"30"](mstkla.md#EXAMPLE) <img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/arrow3.gif">"30"
|
||||
"30"](utilities.md) <img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/arrow4.gif">"30"
|
||||
"30"](linking.md)
|
||||
235
docs/pages/mstkla/index.md
Executable file
235
docs/pages/mstkla/index.md
Executable file
@@ -0,0 +1,235 @@
|
||||
---
|
||||
GENERATOR: 'Mozilla/4.05C-SGI [en] (X11; I; IRIX64 6.5 IP28) [Netscape]'
|
||||
title: MSTKLA Online Manual
|
||||
---
|
||||
|
||||
<img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/construction24.gif">"249"
|
||||
"87"<img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/construc6.gif">"248" "166"
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
**MSTKLA - Mesh ToolKit interface to [LAgrit](http://lagrit.lanl.gov)**
|
||||
|
||||
(LA-UR-99-6711)
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
**DIRECT LINKS**
|
||||
<img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/model.gif">"142"
|
||||
"24"](Geom.md) <img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/mesh.gif">"143"
|
||||
"26"](Mesh.md) <img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/utilities.gif">"143"
|
||||
"25"](utilities.md) <img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/attributes.gif">"1"
|
||||
"26"](MeshAttributes.md)
|
||||
<img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/modelenty.gif">"144"
|
||||
"24"](GeomEntity.md) <img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/modelregn.gif">"141"
|
||||
"25"](GeomRegion.md) <img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/modelface.gif">"143"
|
||||
"26"](GeomFace.md) <img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/modeledge.gif">"143"
|
||||
"25"](GeomEdge.md) <img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/modelvert.gif">"142"
|
||||
"24"](GeomVertex.md)
|
||||
<img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/genregn.gif">"1"
|
||||
"25"](GenRegion.md) <img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/meshregn.gif">"143"
|
||||
"25"](MeshRegion.md) <img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/meshface.gif">"143"
|
||||
"26"](MeshFace.md) <img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/meshedge.gif">"143"
|
||||
"25"](MeshEdge.md) <img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/meshvert.gif">"143"
|
||||
"25"](MeshVertex.md)
|
||||
<img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/trivia.gif">"144" "25"](trivia.md)
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
Questions, Comments, Suggestions? Contact:
|
||||
|
||||
Rao V Garimella,
|
||||
PostDoc
|
||||
Tel: (505) 665-4636
|
||||
|
||||
EES-5, MS D0
|
||||
'
|
||||
|
||||
'
|
||||
|
||||
FAX: (505) 665-69
|
||||
|
||||
Los Alamos National Lab (
|
||||
)-( ) Email: <rao@lanl.gov
|
||||
|
||||
Los Alamos, NM 8
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
|
||||
|
||||
**MSTKLA** is a C interface to the **LaGriT** code which is designed to
|
||||
make it easier to use the LaGriT functionality. It tries to hide some of
|
||||
the internals of LaGriT and provides an API that works in a somewhat
|
||||
object oriented way. It does not attempt to provide or enhance
|
||||
interactive commands that exist in LaGriT. Rather, it is designed more
|
||||
with writing automated mesh generation procedures and complex meshing
|
||||
algorithms within LaGriT in mind.
|
||||
|
||||
MSTKLA has one or more *mesh objects*, which have mesh ***regions***,
|
||||
mesh ***faces,*** mesh ***edges*** and mesh ***vertices*** (nodes).
|
||||
*Mesh faces and mesh edges are objects defined on the fly in terms of
|
||||
their vertices.* One can ask these objects various questions or modify
|
||||
their info through operators. In addition there is a ***geometric
|
||||
model*** and ***geometric model objects*** (In the spirit of consistent
|
||||
naming, I am labeling this set of functions **GMTKLA**). Since LaGriT
|
||||
does not really store curves or points in the database, these are also
|
||||
faked on the fly.
|
||||
|
||||
The mesh and model entities are related through the concept of
|
||||
***CLASSIFICATION***.
|
||||
|
||||
***"A mesh entity is classified on a model entity if it forms all or
|
||||
part of that model entity's discretization (grid) but not its
|
||||
boundary's".***
|
||||
|
||||
So mesh regions can be classified only on a model region. Mesh faces
|
||||
can be classified on a model face or a model region. Mesh vertices can
|
||||
be classified on a model vertex, model edge, model face or model region.
|
||||
|
||||
Classification information can be queried from MSTKLA if it is
|
||||
available. In particular, in LaGriT, only ***external faces*** (what
|
||||
LaGriT calls ***"reflective" boundaries***) and ***internal faces or
|
||||
interfaces*** created with the option ***"intrcons"*** in the
|
||||
***[surface](http://www.t12.lanl.gov/~lagrit/SURFACE.md)***
|
||||
command have the information required to retrieve full classification
|
||||
information. Full classification information includes the ***type*** of
|
||||
geometric model entity the mesh entity is classified on, the ***ID of
|
||||
that geometric model entity*** and ***a pointer to the geometric model
|
||||
object*** (which can be further queried). Interface surfaces created
|
||||
with the surface command option "***intrface***" **do not** have the
|
||||
necessary information to relate the mesh and the model fully. (In the
|
||||
future, I may put in code to take the "intrface" type surfaces and add
|
||||
the info needed to find out the classification information).
|
||||
|
||||
Note that the current interface works for querying an existing mesh but
|
||||
not **yet** for modifying it. The operators for this are on the way.
|
||||
Operators for calling the actual meshing operators (connect, refine,
|
||||
smooth, etc) will also be added in the near future.
|
||||
|
||||
Finally, the basic interface (low level query and modification
|
||||
operators) are expected to retain the same format regardless of what the
|
||||
underlying database is (LaGriT or something else). So, for example, I am
|
||||
hoping that an operator to retrieve the nodes of an element will retain
|
||||
the same form shown below regardless of how it functions internally:
|
||||
|
||||
*void* **MR\_Vertices**(*PMeshObj* mesh, *PMeshRegn* reg, *int
|
||||
**nv,
|
||||
*PMeshVert
|
||||
**rverts);
|
||||
|
||||
I will try hard to maintain this API constant but cannot absolutely
|
||||
guarantee it.
|
||||
|
||||
|
||||
[]{#parent-childAlso see **[Parent-Child Node (Vertex)
|
||||
Issues](http://www.ees.lanl.gov/staff/rao/mstkla/parent-child.md)**
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
[]{#typedefs[TYPEDEFS](http://www.ees.lanl.gov/staff/rao/mstkla/prelim.md)
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
------------------------------------------------------------------------
|
||||
[]{#MSTKLA_Init**MSTKLA Interface Operators**
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
**MESH INITIALIZATION:**
|
||||
|
||||
|
||||
|
||||
*void* **MSTKLA\_Init**(*void*);
|
||||
|
||||
Initialize the mesh toolkit.
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
**MESH OPERATORS:**
|
||||
|
||||
|
||||
|
||||
[]{#MESH OBJECT:[MESH
|
||||
OBJECT:](http://www.ees.lanl.gov/staff/rao/mstkla/Mesh.md)
|
||||
|
||||
[]{#MESH REGION:[MESH
|
||||
REGION:](http://www.ees.lanl.gov/staff/rao/mstkla/MeshRegion.md)
|
||||
|
||||
[]{#MESH FACE:[MESH
|
||||
FACE:](http://www.ees.lanl.gov/staff/rao/mstkla/MeshFace.md)
|
||||
|
||||
[]{#MESH EDGE:[MESH
|
||||
EDGE:](http://www.ees.lanl.gov/staff/rao/mstkla/MeshEdge.md)
|
||||
|
||||
[]{#MESH VERTEX:[MESH
|
||||
VERTEX:](http://www.ees.lanl.gov/staff/rao/mstkla/MeshVertex.md)
|
||||
|
||||
|
||||
|
||||
[]{#GENERIC MESH REGION QUERIES:[GENERIC MESH REGION
|
||||
QUERIES:](http://www.ees.lanl.gov/staff/rao/mstkla/GenRegion.md)
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
[]{#GMTKLA_Init**GEOMETRIC MODEL INITIALIZATION:**
|
||||
|
||||
*void* **GMTKLA\_Init**(*void*);
|
||||
|
||||
Initialize the geometric model interface.
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
**MODEL OPERATORS:**
|
||||
|
||||
[]{#GEOMETRIC MODEL:[GEOMETRIC
|
||||
MODEL:](http://www.ees.lanl.gov/staff/rao/mstkla/Geom.md)
|
||||
|
||||
[]{#MODEL ENTITY:[MODEL
|
||||
ENTITY:](http://www.ees.lanl.gov/staff/rao/mstkla/GeomEntity.md)
|
||||
|
||||
[]{#MODEL REGION:[MODEL
|
||||
REGION:](http://www.ees.lanl.gov/staff/rao/mstkla/GeomRegion.md)
|
||||
|
||||
[]{#MODEL FACE:[MODEL
|
||||
FACE:](http://www.ees.lanl.gov/staff/rao/mstkla/GeomFace.md)
|
||||
|
||||
[]{#MODEL EDGE:[MODEL
|
||||
EDGE:](http://www.ees.lanl.gov/staff/rao/mstkla/GeomEdge.md)
|
||||
|
||||
[]{#MODEL VERTEX[MODEL
|
||||
VERTEX](http://www.ees.lanl.gov/staff/rao/mstkla/GeomVertex.md)
|
||||
---> Not implemented fully
|
||||
|
||||
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
[]{#UTILITIES:**[UTILITIES:](http://www.ees.lanl.gov/staff/rao/mstkla/utilities.md)**
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
------------------------------------------------------------------------
|
||||
[]{#EXAMPLE**[EXAMPLE OF PROGRAMMING WITH
|
||||
MSTKLA](http://www.ees.lanl.gov/staff/rao/mstkla/example.md)**
|
||||
|
||||
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
------------------------------------------------------------------------
|
||||
[]{#EXECUTABLE**[LIBRARIES, INCLUDE FILES AND CREATING AN
|
||||
EXECUTABLE](http://www.ees.lanl.gov/staff/rao/mstkla/linking.md)**
|
||||
143
docs/pages/mstkla/linking.md
Executable file
143
docs/pages/mstkla/linking.md
Executable file
@@ -0,0 +1,143 @@
|
||||
---
|
||||
GENERATOR: 'Mozilla/4.05C-SGI [en] (X11; I; IRIX64 6.5 IP28) [Netscape]'
|
||||
---
|
||||
<img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/arrow2.gif">"30"
|
||||
"30"](mstkla.md#EXECUTABLE) <img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/arrow3.gif">"30"
|
||||
"30"](example.md)
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
**INCLUDE FILES FOR MSTKLA**
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
**
|
||||
#include "mstkla.h"** with the addition of
|
||||
**-I/home/rao/meshing/mstkla/1.0/include** in the link line
|
||||
|
||||
**
|
||||
#include "gmtkla.h"** with the addition of
|
||||
**-I/home/rao/meshing/mstkla/1.0/include** in the link line
|
||||
|
||||
**
|
||||
#include "utilities.h"** with the addition of
|
||||
**-I/home/rao/utilities/1.0/include** in the link line
|
||||
|
||||
**
|
||||
#include "macros.h"** with the addition of
|
||||
**-I/home/rao/meshing/mstkla/1.0/include** in the link line
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
**Linking with MSTKLA **
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
**MSTKLA** (and the embedded **GMTKLA**) are in the following libs:
|
||||
|
||||
**/home/rao/develop/meshing/mstkla/1.0/lib/
|
||||
$ARCHOS**/
|
||||
|
||||
where
|
||||
|
||||
**
|
||||
$ARCHOS** is a variable that combines the architecture and operating
|
||||
system info.
|
||||
|
||||
You can have it set in your **Makefile** by appropriately calling the
|
||||
script
|
||||
|
||||
**/home/rao/bin/getarch** (See the **Makefile** in
|
||||
**/home/rao/develop/meshing/test**)
|
||||
|
||||
The libraries are **libmstk.a** (debug version) and **libmstk-O.a**
|
||||
(optimized version)
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
**MSTKLA** also uses 2 other modules called '**clagrit**' and
|
||||
'**utilities**'. The libs for clagrit are in
|
||||
|
||||
**/home/rao/develop/meshing/clagrit/1.0/lib/
|
||||
$ARCHOS**/
|
||||
|
||||
The libs are l**ibclagrit.a** (debug) and **libclagrit-O.a**
|
||||
(optimized).
|
||||
|
||||
|
||||
|
||||
The libs for utilities are in
|
||||
|
||||
**/home/rao/develop/utilities/1.0/lib/
|
||||
$ARCHOS**/
|
||||
|
||||
and the libs are **libutilities.a** (debug) and **libutilities-O.a**
|
||||
(optimized)
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
Also, the standard l**agrit** and **util** libs have to be included.
|
||||
|
||||
They are located in
|
||||
|
||||
**/pvcs.config/t3d/bin**
|
||||
|
||||
The libs are **liblagrit\_
|
||||
$ARCH.a**, **libutil\_
|
||||
$ARCH.a** (debug) and
|
||||
**liblagrit\_
|
||||
$ARCH\_opt.a**, **libutil\_
|
||||
$ARCH\_opt.a** (optimized).
|
||||
Here, **
|
||||
$ARCH** is as follows:
|
||||
|
||||
Solaris: sol
|
||||
|
||||
HP: hp
|
||||
|
||||
DEC: dec
|
||||
|
||||
SGI: sgi
|
||||
|
||||
SGI/64: sgi\_64
|
||||
|
||||
IBM: ibm
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
The order of libraries that works while linking (until more complicated
|
||||
library interdependencies creep in) is
|
||||
|
||||
|
||||
|
||||
**-L
|
||||
$(MSTKLA\_LIBDIR) -lmstkla -L
|
||||
$(CLAGRIT\_LIBDIR) -lclagrit
|
||||
|
||||
**
|
||||
|
||||
**-L
|
||||
$(MYUTIL\_LIBDIR) -lutilities
|
||||
|
||||
**
|
||||
|
||||
**-L
|
||||
$(LAGRIT\_LIBDIR) -llagrit\_
|
||||
$(ARCH) -L
|
||||
$(CLAGRIT\_LIBDIR)
|
||||
-lclagrit
|
||||
|
||||
**
|
||||
|
||||
**-L
|
||||
$(UTIL\_LIBDIR) -lutil
|
||||
|
||||
**
|
||||
|
||||
**-lm**
|
||||
|
||||
|
||||
|
||||
<img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/arrow2.gif">"30"
|
||||
"30"](mstkla.md#EXECUTABLE) <img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/arrow3.gif">"30"
|
||||
"30"](utilities.md)
|
||||
143
docs/pages/mstkla/mstkla.md
Executable file
143
docs/pages/mstkla/mstkla.md
Executable file
@@ -0,0 +1,143 @@
|
||||
|
||||
|
||||
# MSTKLA - Mesh ToolKit interface to LaGriT
|
||||
|
||||
Note these pages have not been updated to newer versions of MSTKLA
|
||||
|
||||
(LA-UR-99-6711)
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
Questions, Comments, Suggestions? Contact:
|
||||
|
||||
Rao V Garimella,
|
||||
|
||||
Email: rao@lanl.gov
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
|
||||
**MSTKLA** is a C interface to the **LaGriT** code which is designed to
|
||||
make it easier to use the LaGriT functionality. It tries to hide some of
|
||||
the internals of LaGriT and provides an API that works in a somewhat
|
||||
object oriented way. It does not attempt to provide or enhance
|
||||
interactive commands that exist in LaGriT. Rather, it is designed more
|
||||
with writing automated mesh generation procedures and complex meshing
|
||||
algorithms within LaGriT in mind.
|
||||
|
||||
MSTKLA has one or more *mesh objects*, which have mesh **regions**,
|
||||
mesh **faces,** mesh **edges** and mesh **vertices** (nodes).
|
||||
*Mesh faces and mesh edges are objects defined on the fly in terms of
|
||||
their vertices.* One can ask these objects various questions or modify
|
||||
their info through operators. In addition there is a **geometric
|
||||
model** and **geometric model objects** (In the spirit of consistent
|
||||
naming, I am labeling this set of functions **GMTKLA**). Since LaGriT
|
||||
does not really store curves or points in the database, these are also
|
||||
faked on the fly.
|
||||
|
||||
The mesh and model entities are related through the concept of
|
||||
**CLASSIFICATION**.
|
||||
|
||||
"A mesh entity is classified on a model entity if it forms all or
|
||||
part of that model entity's discretization (grid) but not its
|
||||
boundary's".
|
||||
|
||||
So mesh regions can be classified only on a model region. Mesh faces
|
||||
can be classified on a model face or a model region. Mesh vertices can
|
||||
be classified on a model vertex, model edge, model face or model region.
|
||||
|
||||
Classification information can be queried from MSTKLA if it is
|
||||
available. In particular, in LaGriT, only **external faces** (what
|
||||
LaGriT calls **"reflective" boundaries**) and **internal faces or
|
||||
interfaces** created with the option **"intrcons"** in the
|
||||
**surface**
|
||||
command have the information required to retrieve full classification
|
||||
information. Full classification information includes the **type** of
|
||||
geometric model entity the mesh entity is classified on, the **ID of
|
||||
that geometric model entity** and **a pointer to the geometric model
|
||||
object** (which can be further queried). Interface surfaces created
|
||||
with the surface command option "**intrface**" **do not** have the
|
||||
necessary information to relate the mesh and the model fully. (In the
|
||||
future, I may put in code to take the "intrface" type surfaces and add
|
||||
the info needed to find out the classification information).
|
||||
|
||||
Note that the current interface works for querying an existing mesh but
|
||||
not **yet** for modifying it. The operators for this are on the way.
|
||||
Operators for calling the actual meshing operators (connect, refine,
|
||||
smooth, etc) will also be added in the near future.
|
||||
|
||||
Finally, the basic interface (low level query and modification
|
||||
operators) are expected to retain the same format regardless of what the
|
||||
underlying database is (LaGriT or something else). So, for example, I am
|
||||
hoping that an operator to retrieve the nodes of an element will retain
|
||||
the same form shown below regardless of how it functions internally:
|
||||
|
||||
void MR_Vertices(PMeshObj mesh, PMeshRegn reg, int nv, PMeshVert rverts);
|
||||
|
||||
I will try hard to maintain this API constant but cannot absolutely guarantee it.
|
||||
|
||||
parent-child Also see [Parent-Child Node](parent-child.md)
|
||||
|
||||
|
||||
typedefs[TYPEDEFS](prelim.md)
|
||||
|
||||
|
||||
## MSTKLA_Init MSTKLA Interface Operators
|
||||
|
||||
|
||||
|
||||
**MESH INITIALIZATION:**
|
||||
|
||||
|
||||
void MSTKLA_Init(void);
|
||||
|
||||
Initialize the mesh toolkit.
|
||||
|
||||
|
||||
**MESH OPERATORS:**
|
||||
|
||||
|
||||
MESH OBJECT: [MESH OBJECT](Mesh.md)
|
||||
|
||||
MESH REGION:[MESH REGION](MeshRegion.md)
|
||||
|
||||
MESH FACE:[MESH FACE](MeshFace.md)
|
||||
|
||||
MESH EDGE:[MESH EDGE](MeshEdge.md)
|
||||
|
||||
MESH VERTEX:[MESH VERTEX](MeshVertex.md)
|
||||
|
||||
|
||||
GENERIC MESH REGION QUERIES:[GENERIC MESH REGION QUERIES](GenRegion.md)
|
||||
|
||||
|
||||
**GMTKLA_Init GEOMETRIC MODEL INITIALIZATION:**
|
||||
|
||||
void GMTKLA_Init(void);
|
||||
|
||||
Initialize the geometric model interface.
|
||||
|
||||
|
||||
**MODEL OPERATORS:**
|
||||
|
||||
|
||||
GEOMETRIC MODEL:[GEOMETRIC MODEL](Geom.md)
|
||||
|
||||
MODEL ENTITY:[MODEL ENTITY](GeomEntity.md)
|
||||
|
||||
MODEL REGION:[MODEL REGION](GeomRegion.md)
|
||||
|
||||
MODEL FACE:[MODEL FACE](GeomFace.md)
|
||||
|
||||
MODEL EDGE:[MODEL EDGE](GeomEdge.md)
|
||||
|
||||
MODEL VERTEX: [MODEL VERTEX](GeomVertex.md) *Not implemented fully*
|
||||
|
||||
|
||||
UTILITIES: [UTILITIES:](utilities.md)
|
||||
|
||||
|
||||
EXAMPLE: [EXAMPLE OF PROGRAMMING WITH MSTKLA](example.md)**
|
||||
|
||||
EXECUTABLE: [LIBRARIES, INCLUDE FILES AND CREATING AN EXECUTABLE](linking.md)
|
||||
|
||||
47
docs/pages/mstkla/parent-child.md
Executable file
47
docs/pages/mstkla/parent-child.md
Executable file
@@ -0,0 +1,47 @@
|
||||
---
|
||||
GENERATOR: 'Mozilla/4.05C-SGI [en] (X11; I; IRIX64 6.5 IP28) [Netscape]'
|
||||
---
|
||||
|
||||
<img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/arrow2.gif">"30"
|
||||
"30"](mstkla.md#parent-child) <img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/arrow3.gif">"30"
|
||||
"30"](mstkla.md) <img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/arrow4.gif">"30"
|
||||
"30"](prelim.md)
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
**Parent-Child Node (Vertex) Issues**
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
|
||||
|
||||
All the operators are designed to work consistently with parent and
|
||||
child nodes(if they exist) consistently. Operators exist for getting the
|
||||
parent of a vertex, edge and face. The parent edge/face of a edge/face
|
||||
is constructed from the parents of its component vertices. Operators
|
||||
also exist for obtaining the child vertices/edges/faces of
|
||||
vertices/edges/faces.
|
||||
|
||||
The upward and downward adjacency information is designed to be returned
|
||||
in a consistent manner as described below. If upward adjacency
|
||||
information is requested for a child entity then only those higher order
|
||||
entities connected to the child will be returned. On the other hand, if
|
||||
it is requested for a parent, upward adjacency information from all its
|
||||
children will be consolidated and returned. For example, if regions of a
|
||||
child vertex (node) are requested, then only the regions classified in
|
||||
that model region will be returned. On the other hand if one wants all
|
||||
the regions in all model regions connected to the node, one should get
|
||||
the parent of the vertex and ask for the regions connected to the parent
|
||||
vertex. The behavior of downward adjacency information queries is
|
||||
determined by the type of entity and how it is constructed. Asking for
|
||||
the nodes of a vertex will return only the child nodes if any of the
|
||||
nodes are on an interface. Parent faces and edges on an interface will
|
||||
return parent nodes and child faces and edges on an interface will
|
||||
return child nodes. *Lastly, if the entity is not on an interface, it is
|
||||
its own parent or its own child.*
|
||||
<img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/arrow2.gif">"30"
|
||||
"30"](mstkla.md#parent-child) <img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/arrow3.gif">"30"
|
||||
"30"](mstkla.md) <img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/arrow4.gif">"30"
|
||||
"30"](prelim.md)
|
||||
131
docs/pages/mstkla/prelim.md
Executable file
131
docs/pages/mstkla/prelim.md
Executable file
@@ -0,0 +1,131 @@
|
||||
---
|
||||
GENERATOR: 'Mozilla/4.05C-SGI [en] (X11; I; IRIX64 6.5 IP28) [Netscape]'
|
||||
---
|
||||
<img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/arrow2.gif">"30"
|
||||
"30"](mstkla.md#typedefs) <img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/arrow3.gif">"30"
|
||||
"30"](parent-child.md) <img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/arrow4.gif">"30"
|
||||
"30"](Mesh.md)
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
**TYPEDEFS FOR MESH AND MODEL ENTITIES**
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
|
||||
|
||||
A mesh object (actually a pointer to it) in the interface can be
|
||||
declared as
|
||||
|
||||
*PMeshObj* mesh1, mesh2;
|
||||
|
||||
|
||||
|
||||
Mesh entity types are as follows:
|
||||
|
||||
/
|
||||
* Mesh Regions
|
||||
*/
|
||||
|
||||
*PMeshRegn* reg1, oreg, regarr[50];
|
||||
|
||||
|
||||
|
||||
/
|
||||
* Mesh Vertices (nodes)
|
||||
*/
|
||||
|
||||
*PMeshVert* vert,
|
||||
*verts. vert[20][30];
|
||||
|
||||
/
|
||||
* Mesh Face
|
||||
*/
|
||||
|
||||
*PMeshFace* rface;
|
||||
|
||||
/
|
||||
* Mesh Edge
|
||||
*/
|
||||
|
||||
*PMeshEdge* face\_edges[4];
|
||||
|
||||
/
|
||||
* Type of mesh region or element
|
||||
*/
|
||||
|
||||
/
|
||||
* This is an enum decl which can be
|
||||
*/
|
||||
|
||||
/
|
||||
* TET, PYRAMID, PRISM, HEX or RDELETED
|
||||
*/
|
||||
|
||||
*ElType* reg\_type;
|
||||
|
||||
/
|
||||
* Type of mesh vertec
|
||||
*/
|
||||
|
||||
/
|
||||
* Can be VIGNORE, VPARENT, VDELETED
|
||||
*/
|
||||
|
||||
*VType* vert\_type;
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
Geometric model entity types are:
|
||||
|
||||
/
|
||||
* Model entity - can be a region, face, edge or a vertex
|
||||
*/
|
||||
|
||||
*PGeomEntity* gent;
|
||||
|
||||
/
|
||||
* Model region
|
||||
*/
|
||||
|
||||
*PGeomRegn* greg;
|
||||
|
||||
|
||||
|
||||
/
|
||||
* Model face
|
||||
*/
|
||||
|
||||
*PGeomFace* gfaces[20],
|
||||
*
|
||||
*gfaces2, interface;
|
||||
|
||||
/
|
||||
* Model edge - not used at this point
|
||||
*/
|
||||
|
||||
*PGeomEdge* geds[],
|
||||
*gfeds;
|
||||
|
||||
/
|
||||
* Model vertex - not used at this point
|
||||
*/
|
||||
|
||||
*PGeomVert* gv1, gv2;
|
||||
|
||||
/
|
||||
* Type of model entity - can be GREGION, GFACE, GEDGE, GVERTEX
|
||||
*/
|
||||
|
||||
* GType* geomtype;
|
||||
|
||||
|
||||
|
||||
<img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/arrow2.gif">"30"
|
||||
"30"](mstkla.md#typedefs) <img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/arrow3.gif">"30"
|
||||
"30"](parent-child.md) <img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/arrow4.gif">"30"
|
||||
"30"](Mesh.md)
|
||||
28
docs/pages/mstkla/trivia.md
Executable file
28
docs/pages/mstkla/trivia.md
Executable file
@@ -0,0 +1,28 @@
|
||||
---
|
||||
GENERATOR: 'Mozilla/4.05C-SGI [en] (X11; I; IRIX64 6.5 IP28) [Netscape]'
|
||||
---
|
||||
<img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/arrow2.gif">"30"
|
||||
"30"](mstkla.md#MODEL%20ENTITY:)
|
||||
|
||||
**Trivia**
|
||||
|
||||
How to pronounce MSTKLA?
|
||||
|
||||
Well.....
|
||||
|
||||
MSTKLA is the precursor to MSTK. It is hoped that the underlying
|
||||
structure of MSTK will be all new code independent of LaGriT. However,
|
||||
since we are using LaGriT as the underlying structure for now, the
|
||||
toolkit is called MSTKLA.
|
||||
|
||||
M-S-T-K rolls off the tongue nicely, not so M-S-T-K-L-A. Therefore,
|
||||
judging by the people's first reaction to the name (the second reaction
|
||||
is Blechhhch!!), why not pronounce it as *misticlaa*?
|
||||
|
||||
Rao
|
||||
|
||||
P.S.: Sorry, I am lousy at christening pieces of code!! Just take a look
|
||||
at my API...
|
||||
|
||||
|
||||
|
||||
217
docs/pages/mstkla/utilities.md
Executable file
217
docs/pages/mstkla/utilities.md
Executable file
@@ -0,0 +1,217 @@
|
||||
---
|
||||
GENERATOR: 'Mozilla/4.05C-SGI [en] (X11; I; IRIX64 6.5 IP28) [Netscape]'
|
||||
---
|
||||
|
||||
<img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/arrow2.gif">"30"
|
||||
"30"](http://www.ees.lanl.gov/staff/rao/mstkla/mstkla.md#UTILITIES:) <img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/arrow3.gif">"30"
|
||||
"30"](http://www.ees.lanl.gov/staff/rao/mstkla/GeomVertex.md) <img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/arrow4.gif">"30"
|
||||
"30"](http://www.ees.lanl.gov/staff/rao/mstkla/example.md)
|
||||
|
||||
<img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/construction14.gif">"169" "131"
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
**UTILITIES:**
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
|
||||
|
||||
*void* **ReportError**(*char*
|
||||
*modulename, *char*
|
||||
*message, *ErrType*
|
||||
severity);
|
||||
|
||||
Report an error message. The severity may be specified as
|
||||
|
||||
**MESSG**: Print a message to the screen
|
||||
|
||||
**WARNING**: Print message with additional attention grabbing text
|
||||
|
||||
**ERROR**: Print message with additional attention grabbing text
|
||||
|
||||
**FATAL**: Print attention grabbing message and exit.
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
<img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/new1.gif">"31" "12" **VECTOR FUNCTIONS:**
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
*void* **vdiff**(*double*
|
||||
*a, *double*
|
||||
*b, *double*
|
||||
*a\_minus\_b);
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
*void* **vsum**(*double*
|
||||
*a, *double*
|
||||
*b, *double*
|
||||
*a\_plus\_b);
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
*double* **vmag2**(*double*
|
||||
*v);
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
*double* **vmag**(*double*
|
||||
*v);
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
*void* **vcross**(*double*
|
||||
*a, *double*
|
||||
*b, *double*
|
||||
*a\_cross\_b);
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
*double* **vdot**(*double*
|
||||
*a, *double*
|
||||
*b);
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
*void* **vnorm**(*double*
|
||||
*a, *double*
|
||||
*unita);
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
** <img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/new1.gif">"31" "12"REAL NUMBER
|
||||
COMPARISON FUNCTIONS:**
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
|
||||
|
||||
*int* **REAL\_le**(*double* a, *double* b);
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
*int* **REAL\_ge**(*double* a, *double* b);
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
*int* **REAL\_eq**(*double* a, *double* b);
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
<img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/new1.gif">"31" "12" **COMP GEOM
|
||||
FUNCTIONS:**
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
*int* **pntInTriangle2**(*double*
|
||||
*pnt, *double* (
|
||||
*tri)[3], *double*
|
||||
tol, *int* flag, *int*
|
||||
*mtype, *int*
|
||||
*locID);
|
||||
|
||||
|
||||
|
||||
Check if a point that is guaranteed to be in the plane of a triangle is
|
||||
inside the triangle itself.
|
||||
|
||||
If **flag = 1**, check if point is strictly inside
|
||||
|
||||
**flag = 0**, check if point is inside or on the boundary within a
|
||||
real tolerance 'tol'
|
||||
|
||||
Return **value = 1 (inside), 0 (outside), -1 (on boundary)**
|
||||
|
||||
If point is on the boundary, **mtype** indicates type of entity it is
|
||||
on
|
||||
|
||||
**locID** indicates the local ID number of the vertex or edge it is on
|
||||
|
||||
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
*int* **pntInTet**(*double*
|
||||
*pnt, *double* (
|
||||
*tet)[3], *double* tol,
|
||||
*int* flag, *int*
|
||||
*mtype, *int*
|
||||
*locID);
|
||||
|
||||
Check if a point is inside a tet
|
||||
|
||||
If **flag = 1**, check if point is strictly inside
|
||||
|
||||
**flag = 0**, check if point is inside or on the booundary
|
||||
|
||||
within a real tolerance 'tol'
|
||||
|
||||
Return **value = 1 (inside), 0 (outside), -1 (on boundary)**
|
||||
|
||||
If point is on the boundary, **mtype** indicates type of entity it is
|
||||
on
|
||||
|
||||
**locID** indicates the local ID number of the vertex or edge it is on
|
||||
|
||||
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
*void* **Tri\_CircumCen**(*double* (
|
||||
*xyz)[3], *double*
|
||||
*cen);
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
*double* **Tri\_Area**(*double* (
|
||||
*xyz)[3]);
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
*void* **Tri\_Normal**(*double* (
|
||||
*xyz)[3], *double*
|
||||
*normal);
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
*double* **Tet\_Volume**(*double* (
|
||||
*xyz)[3]);
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
*void* **Tet\_CircumCen**(*double* (
|
||||
*xyz)[3], *double*
|
||||
*cen);
|
||||
|
||||
------------------------------------------------------------------------
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
<img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/arrow2.gif">"30"
|
||||
"30"](http://www.ees.lanl.gov/staff/rao/mstkla/mstkla.md#UTILITIES:) <img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/arrow3.gif">"30"
|
||||
"30"](http://www.ees.lanl.gov/staff/rao/mstkla/GeomVertex.md) <img height="300" width="300" src="https://lanl.github.io/LaGriT/assets/images/arrow4.gif">"30"
|
||||
"30"](http://www.ees.lanl.gov/staff/rao/mstkla/example.md)
|
||||
Reference in New Issue
Block a user