gmsh-TingyuanDoc
0.1
An Open-Source Timing-driven Analytical Mixed-size FPGA Placer
|
Go to the documentation of this file.
59 MTetrahedron(
const std::vector<MVertex *> &v,
int num = 0,
int part = 0)
62 for(
int i = 0; i < 4; i++)
_v[i] = v[i];
65 virtual int getDim()
const {
return 3; }
80 virtual void getEdgeRep(
bool curved,
int num,
double *x,
double *y,
double *
z,
96 virtual void getFaceRep(
bool curved,
int num,
double *x,
double *y,
double *
z,
126 mat[0][0] =
_v[1]->
x() -
_v[0]->
x();
127 mat[0][1] =
_v[2]->
x() -
_v[0]->
x();
128 mat[0][2] =
_v[3]->
x() -
_v[0]->
x();
129 mat[1][0] =
_v[1]->
y() -
_v[0]->
y();
130 mat[1][1] =
_v[2]->
y() -
_v[0]->
y();
131 mat[1][2] =
_v[3]->
y() -
_v[0]->
y();
132 mat[2][0] =
_v[1]->
z() -
_v[0]->
z();
133 mat[2][1] =
_v[2]->
z() -
_v[0]->
z();
134 mat[2][2] =
_v[3]->
z() -
_v[0]->
z();
142 virtual void xyz2uvw(
double xyz[3],
double uvw[3])
const;
143 virtual void getNode(
int num,
double &u,
double &v,
double &w)
const
174 virtual bool isInside(
double u,
double v,
double w)
const
177 if(u < (-tol) || v < (-tol) || w < (-tol) || u > ((1. + tol) - v - w))
185 static const int e[6][2] = {{0, 1}, {1, 2}, {2, 0}, {3, 0}, {3, 2}, {3, 1}};
186 return e[edge][vert];
190 static const int f[4][3] = {{0, 2, 1}, {0, 1, 3}, {0, 3, 2}, {3, 1, 2}};
191 return f[face][vert];
197 static const int e[4][3] = {
198 {-3, -2, -1}, {1, -6, 4}, {-4, 5, 3}, {6, 2, -5}};
199 return e[face][edge];
204 static const int eSolin[6][2] = {{0, 1}, {1, 2}, {2, 0},
205 {0, 3}, {2, 3}, {1, 3}};
206 return MEdge(
_v[eSolin[num][0]],
_v[eSolin[num][1]]);
210 static const int fSolin[4][3] = {
211 {0, 1, 2}, {0, 1, 3}, {0, 2, 3}, {1, 2, 3}};
212 return MFace(
_v[fSolin[num][0]],
_v[fSolin[num][1]],
_v[fSolin[num][2]]);
249 for(
int i = 0; i < 6; i++)
_vs[i]->setPolynomialOrder(2);
254 for(
int i = 0; i < 6; i++)
_vs[i] = v[4 + i];
255 for(
int i = 0; i < 6; i++)
_vs[i]->setPolynomialOrder(2);
262 return num < 4 ?
_v[num] :
_vs[num - 4];
266 return num < 4 ?
_v[num] :
_vs[num - 4];
277 static const int map[10] = {0, 4, 1, 5, 2, 6, 7, 9, 8, 3};
282 static const int map[10] = {0, 1, 2, 3, 4, 5, 6, 7, 9, 8};
287 static const int map[10] = {0, 1, 2, 3, 4, 5, 6, 7, 9, 8};
295 virtual void getEdgeRep(
bool curved,
int num,
double *x,
double *y,
double *
z,
298 virtual void getFaceRep(
bool curved,
int num,
double *x,
double *y,
double *
z,
311 static const int f[4][3] = {{2, 1, 0}, {0, 5, 3}, {3, 4, 2}, {5, 1, 4}};
312 v[3] =
_vs[
f[num][0]];
313 v[4] =
_vs[
f[num][1]];
314 v[5] =
_vs[
f[num][2]];
342 virtual void getNode(
int num,
double &u,
double &v,
double &w)
const
347 void xyz2uvw(
double xyz[3],
double uvw[3])
const
376 std::vector<MVertex *>
_vs;
381 const std::vector<MVertex *> &v,
char order,
int num = 0,
385 for(std::size_t i = 0; i <
_vs.size(); i++)
392 for(std::size_t i = 4; i < v.size(); i++)
_vs.push_back(v[i]);
393 for(std::size_t i = 0; i <
_vs.size(); i++)
401 return num < 4 ?
_v[num] :
_vs[num - 4];
405 return num < 4 ?
_v[num] :
_vs[num - 4];
427 const int ie = (num + 1) * (
_order - 1);
428 for(
int i = num * (
_order - 1); i != ie; ++i) v[j++] =
_vs[i];
441 for(
int i = 0; i < 3; i++) {
444 for(
int j = 0; j < n; j++) v[++count] =
_vs[n * edge_num + j];
448 for(
int j = n - 1; j >= 0; j--) v[++count] =
_vs[n * edge_num + j];
452 if((
int)v.size() > count + 1) {
453 int start = 6 * n + num * (n - 1) * n / 2;
454 for(
int i = 0; i < (n - 1) * n / 2; i++) { v[++count] =
_vs[start + i]; }
491 virtual void getEdgeRep(
bool curved,
int num,
double *x,
double *y,
double *
z,
494 virtual void getFaceRep(
bool curved,
int num,
double *x,
double *y,
double *
z,
497 virtual void getNode(
int num,
double &u,
double &v,
double &w)
const
502 void xyz2uvw(
double xyz[3],
double uvw[3])
const
virtual const char * getStringForPOS() const
virtual int getTypeForMSH() const
static std::map< int, IndicesReversed > _order2indicesReversedTet
virtual const char * getStringForTOCHNOG() const
virtual int getNumVolumeVertices() const
virtual void getEdgeVertices(const int num, std::vector< MVertex * > &v) const
virtual void xyz2uvw(double xyz[3], double uvw[3]) const
virtual void getFaceRep(bool curved, int num, double *x, double *y, double *z, SVector3 *n)
virtual void getFaceVertices(const int num, std::vector< MVertex * > &v) const
virtual void xyz2uvw(double xyz[3], double uvw[3]) const
virtual int getType() const
virtual MVertex * getVertexUNV(int num)
virtual const char * getStringForINP() const
virtual void setVertex(int num, MVertex *v)
virtual void setVertex(int num, MVertex *v)
MTetrahedronN(const std::vector< MVertex * > &v, char order, int num=0, int part=0)
virtual const char * getStringForDIFF() const
MTetrahedron(const std::vector< MVertex * > &v, int num=0, int part=0)
virtual const char * getStringForBDF() const
virtual int getNumEdgeVertices() const
virtual double getOuterRadius()
virtual MEdge getEdge(int num) const
virtual int getNumEdgesRep(bool curved)
MTetrahedron(MVertex *v0, MVertex *v1, MVertex *v2, MVertex *v3, int num=0, int part=0)
static int faces_tetra(const int face, const int vert)
virtual void getEdgeVertices(const int num, std::vector< MVertex * > &v) const
virtual const char * getStringForDIFF() const
virtual void getNode(int num, double &u, double &v, double &w) const
virtual MEdge getEdgeSolin(int num)
virtual int getNumEdgesRep(bool curved)
virtual SPoint3 circumcenter()
virtual MVertex * getVertexINP(int num)
static void Error(const char *fmt,...)
virtual void getNode(int num, double &u, double &v, double &w) const
std::vector< int > IndicesReversed
void f(int n, double u, double *val)
virtual void getFaceVertices(const int num, std::vector< MVertex * > &v) const
virtual int getPolynomialOrder() const
virtual int getTypeForMSH() const
virtual int getTypeForUNV() const
virtual double getInnerRadius()
virtual int numEdge2numVertex(int numEdge, int numVert) const
virtual int getNumEdgeVertices() const
virtual MVertex * getVertexBDF(int num)
virtual void getEdgeVertices(const int num, std::vector< MVertex * > &v) const
virtual void getFaceVertices(const int num, std::vector< MVertex * > &v) const
void xyz2uvw(double xyz[3], double uvw[3]) const
virtual std::size_t getNumVertices() const
virtual const MVertex * getVertex(int num) const
std::vector< MVertex * > _vs
void getMat(double mat[3][3]) const
MTetrahedron10(MVertex *v0, MVertex *v1, MVertex *v2, MVertex *v3, MVertex *v4, MVertex *v5, MVertex *v6, MVertex *v7, MVertex *v8, MVertex *v9, int num=0, int part=0)
virtual void getEdgeRep(bool curved, int num, double *x, double *y, double *z, SVector3 *n)
virtual int getNumFacesRep(bool curved)
virtual const char * getStringForBDF() const
virtual MVertex * getVertexKEY(int num)
virtual const MVertex * getVertex(int num) const
virtual int getPolynomialOrder() const
virtual int numCommonNodesInDualGraph(const MElement *const other) const
virtual void setVertex(int num, MVertex *v)
virtual MVertex * getVertex(int num)
virtual void getIntegrationPoints(int pOrder, int *npts, IntPt **pts)
virtual bool getFaceInfo(const MFace &face, int &ithFace, int &sign, int &rot) const
virtual int getTypeForVTK() const
virtual MVertex * getVertexRAD(int num)
virtual int getNumFacesRep(bool curved)
void _getEdgeVertices(const int num, std::vector< MVertex * > &v) const
virtual bool getIsAssimilatedSerendipity() const
virtual const char * getStringForRAD() const
virtual const char * getStringForKEY() const
virtual int getTypeForVTK() const
virtual int getVolumeSign()
virtual SPoint3 barycenterUVW() const
virtual double getVolume()
MTetrahedron10(const std::vector< MVertex * > &v, int num=0, int part=0)
virtual const char * getStringForRAD() const
virtual int getNumEdges() const
virtual int getNumFaces()
static int edges_tetra(const int edge, const int vert)
virtual int getNumFaceVertices() const
double getTolerance() const
virtual MVertex * getVertex(int num)
void _getFaceRep(MVertex *v0, MVertex *v1, MVertex *v2, double *x, double *y, double *z, SVector3 *n)
void xyz2uvw(double xyz[3], double uvw[3]) const
virtual int getTypeForMSH() const
virtual void getFaceRep(bool curved, int num, double *x, double *y, double *z, SVector3 *n)
virtual const MVertex * getVertex(int num) const
virtual double gammaShapeMeasure()
MTetrahedronN(MVertex *v0, MVertex *v1, MVertex *v2, MVertex *v3, const std::vector< MVertex * > &v, char order, int num=0, int part=0)
virtual int getDim() const
static int faces2edge_tetra(const int face, const int edge)
virtual int getTypeForUNV() const
virtual void getNode(int num, double &u, double &v, double &w) const
void _getFaceVertices(const int num, std::vector< MVertex * > &v) const
virtual std::size_t getNumVertices() const
virtual int getNumEdgesRep(bool curved)
virtual const char * getStringForINP() const
virtual const char * getStringForPOS() const
virtual MVertex * getVertex(int num)
virtual void getNode(int num, double &u, double &v, double &w) const
virtual double etaShapeMeasure()
virtual void getEdgeRep(bool curved, int num, double *x, double *y, double *z, SVector3 *n)
virtual const char * getStringForKEY() const
virtual bool isInside(double u, double v, double w) const
virtual const char * getStringForTOCHNOG() const
virtual MFace getFaceSolin(int num)
virtual void getFaceRep(bool curved, int num, double *x, double *y, double *z, SVector3 *n)
virtual MFace getFace(int num) const
virtual MVertex * getVertexVTK(int num)
virtual void getEdgeRep(bool curved, int num, double *x, double *y, double *z, SVector3 *n)
virtual MVertex * getVertexDIFF(int num)
virtual int getNumFacesRep(bool curved)
virtual std::size_t getNumVertices() const