23 for (
int i = 0; i < 3; i++)
40 if ((m = v_to_v(
indices[0],
indices[1])) != -1 && middle[m] != -1)
return 1;
41 if ((m = v_to_v(
indices[1],
indices[2])) != -1 && middle[m] != -1)
return 1;
42 if ((m = v_to_v(
indices[2],
indices[0])) != -1 && middle[m] != -1)
return 1;
48 for (
int i = 0; i < 3; i++)
57 d[0] = ( (pmat(0,1)-pmat(0,0))*(pmat(0,1)-pmat(0,0)) +
58 (pmat(1,1)-pmat(1,0))*(pmat(1,1)-pmat(1,0)) );
59 d[1] = ( (pmat(0,2)-pmat(0,1))*(pmat(0,2)-pmat(0,1)) +
60 (pmat(1,2)-pmat(1,1))*(pmat(1,2)-pmat(1,1)) );
61 d[2] = ( (pmat(0,2)-pmat(0,0))*(pmat(0,2)-pmat(0,0)) +
62 (pmat(1,2)-pmat(1,0))*(pmat(1,2)-pmat(1,0)) );
67 d[0] += (pmat(2,1)-pmat(2,0))*(pmat(2,1)-pmat(2,0));
68 d[1] += (pmat(2,2)-pmat(2,1))*(pmat(2,2)-pmat(2,1));
69 d[2] += (pmat(2,2)-pmat(2,0))*(pmat(2,2)-pmat(2,0));
73 if (d[0] >= d[2]) shift = 0;
76 if (d[1] >= d[2]) shift = 1;
100 int l, L, j, ind[3], i;
103 if ( (l = length[ v_to_v(
indices[1],
indices[2]) ]) > L ) { L = l; j = 1; }
104 if ( (l = length[ v_to_v(
indices[2],
indices[0]) ]) > L ) { L = l; j = 2; }
106 for (i = 0; i < 3; i++)
123 for (
int i = 0; i < 3; i++)
virtual int * GetVertices()
int NeedRefinement(DSTable &v_to_v, int *middle) const
Return 1 if the element needs refinement in order to get conforming mesh.
static const int edges[3][2]
virtual void MarkEdge(DenseMatrix &pmat)
int Height() const
Get the height (size of output) of the Operator. Synonym with NumRows.
virtual void SetVertices(const int *ind)
Set the vertices according to the given input.
Class for linear FE on triangle.
int attribute
Element's attribute (specifying material property, etc).
void SetSize(int nsize)
Change logical size of the array, keep existing entries.
Linear2DFiniteElement TriangleFE
Abstract data type element.