2023-09-04 16:43:47 +05:00
|
|
|
#ifndef NETGEN_MESHTOOL_HPP
|
|
|
|
#define NETGEN_MESHTOOL_HPP
|
2009-01-13 04:40:13 +05:00
|
|
|
|
2023-09-04 16:43:47 +05:00
|
|
|
// #include "../general/ngarray.hpp"
|
|
|
|
// #include "../gprim/geom3d.hpp"
|
|
|
|
// #include "../gprim/geomobjects.hpp"
|
|
|
|
// #include "meshtype.hpp"
|
|
|
|
// #include "meshclass.hpp"
|
2009-01-13 04:40:13 +05:00
|
|
|
|
2023-09-04 16:43:47 +05:00
|
|
|
namespace netgen {
|
2009-01-13 04:40:13 +05:00
|
|
|
///
|
|
|
|
extern void MeshQuality2d (const Mesh & mesh);
|
|
|
|
|
|
|
|
///
|
|
|
|
extern void MeshQuality3d (const Mesh & mesh,
|
2019-07-09 13:39:16 +05:00
|
|
|
NgArray<int> * inclass = NULL);
|
2009-01-13 04:40:13 +05:00
|
|
|
|
|
|
|
///
|
|
|
|
extern void SaveEdges (const Mesh & mesh,
|
|
|
|
const char * geomfile,
|
|
|
|
double h,
|
|
|
|
char * filename);
|
|
|
|
|
|
|
|
///
|
|
|
|
extern void SaveSurfaceMesh (const Mesh & mesh,
|
|
|
|
double h,
|
|
|
|
char * filename);
|
|
|
|
/*
|
|
|
|
///
|
|
|
|
extern void Save2DMesh (
|
|
|
|
const Mesh & mesh2d,
|
2019-07-09 13:39:16 +05:00
|
|
|
const NgArray<class SplineSegment*> * splines,
|
2009-01-13 04:40:13 +05:00
|
|
|
ostream & outfile);
|
|
|
|
*/
|
|
|
|
|
|
|
|
class Surface;
|
|
|
|
///
|
|
|
|
extern void SaveVolumeMesh (
|
2019-07-09 13:39:16 +05:00
|
|
|
const NgArray<Point3d> & points,
|
|
|
|
const NgArray<Element> & elements,
|
|
|
|
const NgArray<Element> & volelements,
|
|
|
|
const NgArray<Surface*> & surfaces,
|
2009-01-13 04:40:13 +05:00
|
|
|
char * filename);
|
|
|
|
|
|
|
|
///
|
|
|
|
void SaveVolumeMesh (const Mesh & mesh,
|
2014-08-30 06:15:59 +06:00
|
|
|
const class NetgenGeometry & geometry,
|
2009-01-13 04:40:13 +05:00
|
|
|
char * filename);
|
|
|
|
|
|
|
|
///
|
|
|
|
extern int CheckCode ();
|
|
|
|
|
|
|
|
|
|
|
|
///
|
2011-07-25 14:40:23 +06:00
|
|
|
extern double CalcTetBadness (const Point3d & p1, const Point3d & p2,
|
|
|
|
const Point3d & p3, const Point3d & p4,
|
|
|
|
double h,
|
2011-07-25 17:33:19 +06:00
|
|
|
const MeshingParameters & mp);
|
2009-01-13 04:40:13 +05:00
|
|
|
///
|
2011-07-25 14:40:23 +06:00
|
|
|
extern double CalcTetBadnessGrad (const Point3d & p1, const Point3d & p2,
|
|
|
|
const Point3d & p3, const Point3d & p4,
|
|
|
|
double h, int pi,
|
|
|
|
Vec<3> & grad,
|
2011-07-25 17:33:19 +06:00
|
|
|
const MeshingParameters & mp);
|
2009-01-13 04:40:13 +05:00
|
|
|
|
|
|
|
|
|
|
|
/** Calculates volume of an element.
|
|
|
|
The volume of the tetrahedron el is computed
|
|
|
|
*/
|
2019-07-09 13:39:16 +05:00
|
|
|
// extern double CalcVolume (const NgArray<Point3d> & points,
|
2009-01-13 04:40:13 +05:00
|
|
|
// const Element & el);
|
|
|
|
|
|
|
|
/** The total volume of all elements is computed.
|
|
|
|
This function calculates the volume of the mesh */
|
2019-07-09 13:39:16 +05:00
|
|
|
extern double CalcVolume (const NgArray<Point3d> & points,
|
|
|
|
const NgArray<Element> & elements);
|
2009-01-13 04:40:13 +05:00
|
|
|
|
|
|
|
///
|
|
|
|
extern int CheckSurfaceMesh (const Mesh & mesh);
|
|
|
|
|
|
|
|
///
|
|
|
|
extern int CheckSurfaceMesh2 (const Mesh & mesh);
|
|
|
|
///
|
|
|
|
extern int CheckMesh3D (const Mesh & mesh);
|
|
|
|
///
|
|
|
|
extern void RemoveProblem (Mesh & mesh, int domainnr);
|
2023-09-04 16:43:47 +05:00
|
|
|
|
|
|
|
} // namespace netgen
|
|
|
|
#endif // NETGEN_MESHTOOL_HPP
|