mFES - molecular Finite Element Solver  0.4
Classes | Namespaces | Typedefs | Enumerations | Functions | Variables
nglib.cpp File Reference
#include <mystdlib.h>
#include <myadt.hpp>
#include <linalg.hpp>
#include <csg.hpp>
#include <stlgeom.hpp>
#include <geometry2d.hpp>
#include <meshing.hpp>
#include <../visualization/soldata.hpp>
#include <nginterface.h>
#include "nglib.h"

Classes

class  nglib::Ng_Meshing_Parameters
 Netgen Meshing Parameters class. More...

Namespaces

namespace  netgen
 

namespace defined for NETGEN


namespace  nglib

Typedefs

typedef void * nglib::Ng_Mesh
 Data type for NETGEN mesh.
typedef void * nglib::Ng_CSG_Geometry
 Data type for NETGEN CSG geometry.
typedef void * nglib::Ng_Geometry_2D
 Data type for NETGEN 2D geometry.
typedef void * nglib::Ng_STL_Geometry
 Data type for NETGEN STL geometry.

Enumerations

enum  nglib::Ng_Surface_Element_Type {
  nglib::NG_TRIG = 1, nglib::NG_QUAD = 2, nglib::NG_TRIG6 = 3, nglib::NG_QUAD6 = 4,
  nglib::NG_QUAD8 = 5
}
 Currently implemented surface element types. More...
enum  nglib::Ng_Volume_Element_Type { nglib::NG_TET = 1, nglib::NG_PYRAMID = 2, nglib::NG_PRISM = 3, nglib::NG_TET10 = 4 }
 Currently implemented volume element types. More...
enum  nglib::Ng_Result {
  nglib::NG_ERROR = -1, nglib::NG_OK = 0, nglib::NG_SURFACE_INPUT_ERROR = 1, nglib::NG_VOLUME_FAILURE = 2,
  nglib::NG_STL_INPUT_ERROR = 3, nglib::NG_SURFACE_FAILURE = 4, nglib::NG_FILE_NOT_FOUND = 5
}
 Values returned by Netgen functions. More...

Functions

void netgen::MeshFromSpline2D (SplineGeometry2d &geometry, Mesh *&mesh, MeshingParameters &mp)
DLL_HEADER void nglib::Ng_Init ()
 Initialise the Netgen library and prepare for use.
DLL_HEADER void nglib::Ng_Exit ()
 Exit the Netgen meshing kernel in a clean manner.
DLL_HEADER Ng_Meshnglib::Ng_NewMesh ()
 Create a new (and empty) Netgen Mesh Structure.
DLL_HEADER void nglib::Ng_DeleteMesh (Ng_Mesh *mesh)
 Delete an existing Netgen Mesh Structure.
DLL_HEADER void nglib::Ng_SaveMesh (Ng_Mesh *mesh, const char *filename)
 Save a Netgen Mesh to disk.
DLL_HEADER Ng_Meshnglib::Ng_LoadMesh (const char *filename)
 Load a Netgen VOL Mesh from disk into memory.
DLL_HEADER Ng_Meshnglib::Ng_SetProperties (Ng_Mesh *m, int surfnr, int bcnr, int domin, int domout)
 Set element options.
DLL_HEADER Ng_Result nglib::Ng_MergeMesh (Ng_Mesh *mesh, const char *filename)
 Merge a Netgen VOL Mesh from disk into an existing mesh in memory.
DLL_HEADER Ng_Result nglib::Ng_MergeMesh (Ng_Mesh *mesh1, Ng_Mesh *mesh2)
 Merge one Netgen Mesh into another Netgen Mesh in the case when both are already in memory.
DLL_HEADER void nglib::Ng_AddPoint (Ng_Mesh *mesh, double *x)
 Add a point to a given Netgen Mesh Structure.
DLL_HEADER void nglib::Ng_AddSurfaceElement (Ng_Mesh *mesh, Ng_Surface_Element_Type et, int *pi)
 Add a surface element to a given Netgen Mesh Structure.
DLL_HEADER void nglib::Ng_AddVolumeElement (Ng_Mesh *mesh, Ng_Volume_Element_Type et, int *pi)
 Add a volume element to a given Netgen Mesh Structure.
DLL_HEADER void nglib::Ng_RestrictMeshSizeGlobal (Ng_Mesh *mesh, double h)
 Apply a global restriction on mesh element size.
DLL_HEADER void nglib::Ng_RestrictMeshSizePoint (Ng_Mesh *mesh, double *p, double h)
 Locally restrict the mesh element size at the given point.
DLL_HEADER void nglib::Ng_RestrictMeshSizeBox (Ng_Mesh *mesh, double *pmin, double *pmax, double h)
 Locally restrict the mesh element size within a specified box.
DLL_HEADER Ng_Result nglib::Ng_GenerateVolumeMesh (Ng_Mesh *mesh, Ng_Meshing_Parameters *mp)
 Create a 3D Volume Mesh given a Surface Mesh.
DLL_HEADER int nglib::Ng_GetNP (Ng_Mesh *mesh)
 Returns the Number of Points present in the specified Mesh.
DLL_HEADER int nglib::Ng_GetNSE (Ng_Mesh *mesh)
 Returns the Number of Surface Elements present in the specified Mesh.
DLL_HEADER int nglib::Ng_GetNE (Ng_Mesh *mesh)
 Returns the Number of Volume Elements present in the specified Mesh.
DLL_HEADER void nglib::Ng_GetPoint (Ng_Mesh *mesh, int num, double *x)
DLL_HEADER Ng_Surface_Element_Type nglib::Ng_GetSurfaceElement (Ng_Mesh *mesh, int num, int *pi)
DLL_HEADER Ng_Volume_Element_Type nglib::Ng_GetVolumeElement (Ng_Mesh *mesh, int num, int *pi)
DLL_HEADER void nglib::Ng_AddPoint_2D (Ng_Mesh *mesh, double *x)
DLL_HEADER void nglib::Ng_AddBoundarySeg_2D (Ng_Mesh *mesh, int pi1, int pi2)
DLL_HEADER int nglib::Ng_GetNP_2D (Ng_Mesh *mesh)
DLL_HEADER int nglib::Ng_GetNE_2D (Ng_Mesh *mesh)
DLL_HEADER int nglib::Ng_GetNSeg_2D (Ng_Mesh *mesh)
DLL_HEADER void nglib::Ng_GetPoint_2D (Ng_Mesh *mesh, int num, double *x)
DLL_HEADER Ng_Surface_Element_Type nglib::Ng_GetElement_2D (Ng_Mesh *mesh, int num, int *pi, int *matnum=NULL)
DLL_HEADER void nglib::Ng_GetSegment_2D (Ng_Mesh *mesh, int num, int *pi, int *matnum=NULL)
DLL_HEADER Ng_Geometry_2Dnglib::Ng_LoadGeometry_2D (const char *filename)
DLL_HEADER Ng_Result nglib::Ng_GenerateMesh_2D (Ng_Geometry_2D *geom, Ng_Mesh **mesh, Ng_Meshing_Parameters *mp)
DLL_HEADER void nglib::Ng_HP_Refinement (Ng_Geometry_2D *geom, Ng_Mesh *mesh, int levels)
DLL_HEADER Ng_STL_Geometrynglib::Ng_STL_LoadGeometry (const char *filename, int binary=0)
DLL_HEADER Ng_STL_Geometrynglib::Ng_STL_NewGeometry ()
DLL_HEADER void nglib::Ng_STL_AddTriangle (Ng_STL_Geometry *geom, double *p1, double *p2, double *p3, double *nv=NULL)
DLL_HEADER void nglib::Ng_STL_AddEdge (Ng_STL_Geometry *geom, double *p1, double *p2)
DLL_HEADER Ng_Result nglib::Ng_STL_InitSTLGeometry (Ng_STL_Geometry *geom)
DLL_HEADER Ng_Result nglib::Ng_STL_MakeEdges (Ng_STL_Geometry *geom, Ng_Mesh *mesh, Ng_Meshing_Parameters *mp)
DLL_HEADER Ng_Result nglib::Ng_STL_GenerateSurfaceMesh (Ng_STL_Geometry *geom, Ng_Mesh *mesh, Ng_Meshing_Parameters *mp)
DLL_HEADER void nglib::Ng_Uniform_Refinement (Ng_Mesh *mesh)
DLL_HEADER void nglib::Ng_2D_Uniform_Refinement (Ng_Geometry_2D *geom, Ng_Mesh *mesh)
DLL_HEADER void nglib::Ng_STL_Uniform_Refinement (Ng_STL_Geometry *geom, Ng_Mesh *mesh)
DLL_HEADER void nglib::Ng_CSG_Uniform_Refinement (Ng_CSG_Geometry *geom, Ng_Mesh *mesh)
DLL_HEADER void nglib::Ng_Generate_SecondOrder (Ng_Mesh *mesh)
DLL_HEADER void nglib::Ng_2D_Generate_SecondOrder (Ng_Geometry_2D *geom, Ng_Mesh *mesh)
DLL_HEADER void nglib::Ng_STL_Generate_SecondOrder (Ng_STL_Geometry *geom, Ng_Mesh *mesh)
DLL_HEADER void nglib::Ng_CSG_Generate_SecondOrder (Ng_CSG_Geometry *geom, Ng_Mesh *mesh)
DLL_HEADER void nglib::Ng_HP_Refinement (Ng_Geometry_2D *geom, Ng_Mesh *mesh, int levels, double parameter)
DLL_HEADER void netgen::MyError (const char *ch)
DLL_HEADER void netgen::Ng_PrintDest (const char *s)
DLL_HEADER double netgen::GetTime ()
void netgen::ResetTime ()
void netgen::MyBeep (int i)
void netgen::Render ()
void Ng_Redraw ()
void Ng_ClearSolutionData ()
 delete gridfunctions
void Ng_SetSolutionData (Ng_SolutionData *soldata)
void Ng_InitSolutionData (Ng_SolutionData *soldata)

Variables

Array< STLReadTriangle > nglib::readtrias
Array< Point< 3 > > nglib::readedges
char netgen::geomfilename [255]

Function Documentation

delete gridfunctions

void Ng_InitSolutionData ( Ng_SolutionData soldata)
void Ng_Redraw ( )
void Ng_SetSolutionData ( Ng_SolutionData soldata)