gmsh-TingyuanDoc
0.1
An Open-Source Timing-driven Analytical Mixed-size FPGA Placer
|
Go to the documentation of this file.
53 MQuadrangle(
const std::vector<MVertex *> &v,
int num = 0,
int part = 0)
56 for(
int i = 0; i < 4; i++)
_v[i] = v[i];
62 virtual int getDim()
const {
return 2; }
69 static const int map[4] = {0, 1, 3, 2};
82 virtual void getEdgeRep(
bool curved,
int num,
double *x,
double *y,
double *
z,
98 virtual void getFaceRep(
bool curved,
int num,
double *x,
double *y,
double *
z,
119 virtual void getNode(
int num,
double &u,
double &v,
double &w)
const
158 virtual bool isInside(
double u,
double v,
double w)
const
161 if(u < -(1. + tol) || v < -(1. + tol) || u > (1. + tol) || v > (1. + tol) ||
176 static const int e[4][2] = {{0, 1}, {1, 2}, {2, 3}, {3, 0}};
177 return e[edge][vert];
182 static const int eSolin[4][2] = {{0, 1}, {1, 2}, {3, 2}, {0, 3}};
183 return MEdge(
_v[eSolin[num][0]],
_v[eSolin[num][1]]);
216 for(
int i = 0; i < 4; i++)
_vs[i]->setPolynomialOrder(2);
218 MQuadrangle8(
const std::vector<MVertex *> &v,
int num = 0,
int part = 0)
221 for(
int i = 0; i < 4; i++)
_vs[i] = v[4 + i];
222 for(
int i = 0; i < 4; i++)
_vs[i]->setPolynomialOrder(2);
229 return num < 4 ?
_v[num] :
_vs[num - 4];
233 return num < 4 ?
_v[num] :
_vs[num - 4];
245 static const int map[8] = {0, 4, 1, 5, 2, 6, 3, 7};
250 static const int map[8] = {0, 1, 3, 2, 4, 7, 5, 6};
255 virtual void getEdgeRep(
bool curved,
int num,
double *x,
double *y,
double *
z,
265 virtual void getFaceRep(
bool curved,
int num,
double *x,
double *y,
double *
z,
305 virtual void getNode(
int num,
double &u,
double &v,
double &w)
const
340 for(
int i = 0; i < 5; i++)
_vs[i]->setPolynomialOrder(2);
342 MQuadrangle9(
const std::vector<MVertex *> &v,
int num = 0,
int part = 0)
345 for(
int i = 0; i < 5; i++)
_vs[i] = v[4 + i];
346 for(
int i = 0; i < 5; i++)
_vs[i]->setPolynomialOrder(2);
353 return num < 4 ?
_v[num] :
_vs[num - 4];
357 return num < 4 ?
_v[num] :
_vs[num - 4];
368 static const int map[9] = {0, 2, 8, 6, 1, 5, 7, 3, 4};
374 virtual void getEdgeRep(
bool curved,
int num,
double *x,
double *y,
double *
z,
384 virtual void getFaceRep(
bool curved,
int num,
double *x,
double *y,
double *
z,
422 virtual void getNode(
int num,
double &u,
double &v,
double &w)
const
450 static std::map<TupleReorientation, IndicesReoriented>
454 std::vector<MVertex *>
_vs;
459 const std::vector<MVertex *> &v,
char order,
int num = 0,
463 for(std::size_t i = 0; i <
_vs.size(); i++)
470 for(std::size_t i = 4; i < v.size(); i++)
_vs.push_back(v[i]);
471 for(std::size_t i = 0; i <
_vs.size(); i++)
479 return num < 4 ?
_v[num] :
_vs[num - 4];
483 return num < 4 ?
_v[num] :
_vs[num - 4];
502 virtual void getEdgeRep(
bool curved,
int num,
double *x,
double *y,
double *
z,
509 const int ie = (num + 1) * (
_order - 1);
510 for(
int i = num * (
_order - 1); i != ie; ++i) v[j++] =
_vs[i];
513 virtual void getFaceRep(
bool curved,
int num,
double *x,
double *y,
double *
z,
517 v.resize(4 +
_vs.size());
519 for(std::size_t i = 0; i !=
_vs.size(); ++i) v[i + 4] =
_vs[i];
553 if(
_order == 2 &&
_vs.size() + 4 == 9)
return 28;
554 if(
_order == 2 &&
_vs.size() + 4 == 8)
return 23;
564 virtual void getNode(
int num,
double &u,
double &v,
double &w)
const
572 template <
class T>
void inline sort2(T &a, T &b)
581 template <
class T>
void sort4(T *t[4])
583 sort2<T *>(t[0], t[1]);
584 sort2<T *>(t[2], t[3]);
585 sort2<T *>(t[0], t[2]);
586 sort2<T *>(t[1], t[3]);
587 sort2<T *>(t[1], t[2]);
599 if(_v1[0] < _v2[0])
return true;
600 if(_v1[0] > _v2[0])
return false;
601 if(_v1[1] < _v2[1])
return true;
602 if(_v1[1] > _v2[1])
return false;
603 if(_v1[2] < _v2[2])
return true;
604 if(_v1[2] > _v2[2])
return false;
605 if(_v1[3] < _v2[3])
return true;
virtual void getFaceRep(bool curved, int num, double *x, double *y, double *z, SVector3 *n)
virtual void getEdgeVertices(const int num, std::vector< MVertex * > &v) const
virtual double getVolume()
virtual void getEdgeVertices(const int num, std::vector< MVertex * > &v) const
virtual const char * getStringForKEY() const
virtual int getTypeForMSH() const
virtual void getEdgeRep(bool curved, int num, double *x, double *y, double *z, SVector3 *n)
virtual MFaceN getHighOrderFace(int num, int sign, int rot)
virtual MVertex * getVertexDIFF(int num)
virtual int getNumEdgesRep(bool curved)
virtual void setVertex(int num, MVertex *v)
std::vector< MVertex * > _vs
virtual void getNode(int num, double &u, double &v, double &w) const
virtual bool isInside(double u, double v, double w) const
virtual MVertex * getVertex(int num)
MQuadrangle(const std::vector< MVertex * > &v, int num=0, int part=0)
virtual void getNode(int num, double &u, double &v, double &w) const
virtual int getPolynomialOrder() const
virtual int getNumEdges() const
virtual int getNumFaceVertices() const
virtual const char * getStringForRAD() const
static void Error(const char *fmt,...)
virtual MFace getFaceSolin(int numFace)
virtual const char * getStringForINP() const
virtual int numEdge2numVertex(int numEdge, int numVert) const
virtual void getFaceVertices(const int num, std::vector< MVertex * > &v) const
virtual MFaceN getHighOrderFace(int num, int sign, int rot)
virtual const char * getStringForKEY() const
virtual void getIntegrationPoints(int pOrder, int *npts, IntPt **pts)
virtual int getNumFacesRep(bool curved)
MQuadrangleN(const std::vector< MVertex * > &v, char order, int num=0, int part=0)
virtual int getNumFaceVertices() const
static int edges_quad(const int edge, const int vert)
MQuadrangle8(MVertex *v0, MVertex *v1, MVertex *v2, MVertex *v3, MVertex *v4, MVertex *v5, MVertex *v6, MVertex *v7, int num=0, int part=0)
virtual int getNumEdgeVertices() const
virtual double getOuterRadius()
virtual int getNumFacesRep(bool curved)
virtual double angleShapeMeasure()
virtual SPoint3 barycenterUVW() const
virtual int getDim() const
virtual const char * getStringForDIFF() const
virtual void getNode(int num, double &u, double &v, double &w) const
std::pair< int, std::pair< int, int > > TupleReorientation
virtual void getFaceRep(bool curved, int num, double *x, double *y, double *z, SVector3 *n)
virtual const char * getStringForPOS() const
virtual const char * getStringForINP() const
virtual double gammaShapeMeasure()
virtual MFaceN getHighOrderFace(int num, int sign, int rot)
virtual int getNumEdgesRep(bool curved)
virtual void getFaceRep(bool curved, int num, double *x, double *y, double *z, SVector3 *n)
static std::map< TupleReorientation, IndicesReoriented > _tuple2indicesReoriented
virtual const MVertex * getVertex(int num) const
std::vector< int > IndicesReoriented
virtual int getTypeForMSH() const
virtual SPoint3 barycenterUVW() const
virtual int getTypeForVTK() const
virtual std::size_t getNumVertices() const
virtual void reorient(int rotation, bool swap)
virtual void reorient(int rotation, bool swap)
virtual void setVertex(int num, MVertex *v)
virtual int getTypeForVTK() const
virtual const char * getStringForBDF() const
virtual void getEdgeVertices(const int num, std::vector< MVertex * > &v) const
MQuadrangle(MVertex *v0, MVertex *v1, MVertex *v2, MVertex *v3, int num=0, int part=0)
virtual const char * getStringForBDF() const
virtual int getNumFaces()
virtual double getInnerRadius()
virtual int getNumFacesRep(bool curved)
virtual void getEdgeRep(bool curved, int num, double *x, double *y, double *z, SVector3 *n)
virtual int getTypeForUNV() const
void swap(double &a, double &b)
virtual MFaceN getHighOrderFace(int num, int sign, int rot)
void _getFaceVertices(std::vector< MVertex * > &v) const
virtual int getPolynomialOrder() const
virtual void getFaceRep(bool curved, int num, double *x, double *y, double *z, SVector3 *n)
virtual MVertex * getVertexDIFF(int num)
virtual std::size_t getNumVertices() const
virtual void setVertex(int num, MVertex *v)
virtual bool getFaceInfo(const MFace &face, int &ithFace, int &sign, int &rot) const
virtual MEdge getEdgeSolin(int num)
virtual bool getIsAssimilatedSerendipity() const
virtual void reorient(int rotation, bool swap)
virtual MFace getFace(int num) const
bool operator()(MQuadrangle *t1, MQuadrangle *t2) const
virtual int getNumEdgeVertices() const
virtual int getTypeForUNV() const
virtual int numCommonNodesInDualGraph(const MElement *const other) const
virtual int getNumEdgesRep(bool curved)
virtual std::size_t getNumVertices() const
virtual void getFaceVertices(const int num, std::vector< MVertex * > &v) const
MQuadrangleN(MVertex *v0, MVertex *v1, MVertex *v2, MVertex *v3, const std::vector< MVertex * > &v, char order, int num=0, int part=0)
virtual void getFaceVertices(const int num, std::vector< MVertex * > &v) const
virtual void getFaceVertices(const int num, std::vector< MVertex * > &v) const
virtual MVertex * getVertex(int num)
virtual const char * getStringForPOS() const
virtual void getEdgeRep(bool curved, int num, double *x, double *y, double *z, SVector3 *n)
virtual const char * getStringForBDF() const
virtual const char * getStringForINP() const
virtual int getTypeForMSH() const
virtual int getNumEdgesRep(bool curved)
double getTolerance() const
virtual const char * getStringForDIFF() const
virtual void getNode(int num, double &u, double &v, double &w) const
virtual const MVertex * getVertex(int num) const
virtual int getTypeForVTK() const
virtual int getNumFacesRep(bool curved)
MQuadrangle8(const std::vector< MVertex * > &v, int num=0, int part=0)
virtual const char * getStringForDIFF() const
virtual const char * getStringForPOS() const
virtual int getTypeForVTK() const
virtual int getTypeForMSH() const
virtual void getNode(int num, double &u, double &v, double &w) const
virtual double etaShapeMeasure()
virtual MVertex * getVertexDIFF(int num)
void projectInMeanPlane(double *xn, double *yn)
virtual const char * getStringForTOCHNOG() const
virtual void reorient(int rotation, bool swap)
void _getEdgeVertices(const int num, std::vector< MVertex * > &v) const
virtual int getType() const
MQuadrangle9(MVertex *v0, MVertex *v1, MVertex *v2, MVertex *v3, MVertex *v4, MVertex *v5, MVertex *v6, MVertex *v7, MVertex *v8, int num=0, int part=0)
virtual SPoint3 barycenterUVW() const
virtual MVertex * getVertexUNV(int num)
MQuadrangle9(const std::vector< MVertex * > &v, int num=0, int part=0)
virtual void getEdgeVertices(const int num, std::vector< MVertex * > &v) const
virtual MEdge getEdge(int num) const
virtual const MVertex * getVertex(int num) const
virtual void setVertex(int num, MVertex *v)
virtual MVertex * getVertex(int num)
virtual MVertex * getVertex(int num)
virtual SPoint3 barycenterUVW() const
virtual void getEdgeRep(bool curved, int num, double *x, double *y, double *z, SVector3 *n)
virtual const char * getStringForTOCHNOG() const
virtual const MVertex * getVertex(int num) const
virtual int getPolynomialOrder() const
virtual int getNumEdgeVertices() const
virtual std::size_t getNumVertices() const