25CElement::CElement(
const CMatrix &P,
int iOrder)
27, m_iIntegrationOrder(iOrder)
43 vector<INTEGRATION_POINT> IntegrationPoints;
45 vector<INTEGRATION_POINT>::iterator itIP;
49 for (itIP = IntegrationPoints.begin(); itIP != IntegrationPoints.end(); ++itIP)
56 KeMatrix += Kei * itIP->dWeight;
72 IntegrationPoints.clear();
81 IntegrationPoints.push_back(IP);
87 IntegrationPoints.push_back(IP);
90 IntegrationPoints.push_back(IP);
93 IntegrationPoints.push_back(IP);
98 IntegrationPoints.push_back(IP);
103 IntegrationPoints.push_back(IP);
106 IntegrationPoints.push_back(IP);
109 IntegrationPoints.push_back(IP);
114 IntegrationPoints.push_back(IP);
119 IntegrationPoints.push_back(IP);
122 IntegrationPoints.push_back(IP);
125 IntegrationPoints.push_back(IP);
130 IntegrationPoints.push_back(IP);
133 IntegrationPoints.push_back(IP);
136 IntegrationPoints.push_back(IP);
139 vector<INTEGRATION_POINT>::iterator itIP;
140 for (itIP = IntegrationPoints.begin(); itIP != IntegrationPoints.end(); ++itIP)
142 itIP->Position = itIP->Position *
m_P;
181 vector<CMatrix> Nodes;
187 Node(0, 0) =
m_P(i, 0);
188 Node(0, 1) =
m_P(i, 1);
190 Nodes.push_back(Node);
195 vector<CMatrix> Rows;
210 AMatrix(i, j) = Rows[i](0, j);
224 XMatrix(0, j) = R1(0, j);
225 XMatrix(1, j) = R2(0, j);
226 XMatrix(2, j) = 2*R3(0, j);
244 const double v12 = 0.0, v21 = 0.0;
246 const double G12 = 0.5*(E1+E2)/(2*(1+0.5*(v12+v21)));
249 DMatrix(0, 0) = E1/(1-v12*v21);
250 DMatrix(1, 1) = E2/(1-v12*v21);
251 DMatrix(1, 0) = v12*E2/(1-v12*v21);
252 DMatrix(0, 1) = v12*E2/(1-v12*v21);
265 T(0, 0) = MatOrient.
x*MatOrient.
x;
266 T(0, 1) = MatOrient.
y*MatOrient.
y;
267 T(0, 2) = -2*MatOrient.
x*MatOrient.
y;
268 T(1, 0) = MatOrient.
y*MatOrient.
y;
269 T(1, 1) = MatOrient.
x*MatOrient.
x;
270 T(1, 2) = 2*MatOrient.
x*MatOrient.
y;
271 T(2, 0) = MatOrient.
x*MatOrient.
y;
272 T(2, 1) = -MatOrient.
x*MatOrient.
y;
273 T(2, 2) = MatOrient.
x*MatOrient.
x-MatOrient.
y*MatOrient.
y;
287 double x = Position(0, 0), y = Position(0, 1);
304 double x = Position(0, 0), y = Position(0, 1);
312 Theta_x(0, 6) = 3*x*x;
313 Theta_x(0, 7) = 2*x*y;
321 double x = Position(0, 0), y = Position(0, 1);
331 Theta_y(0, 8) = 2*x*y;
332 Theta_y(0, 9) = 3*y*y;
338 double x = Position(0, 0), y = Position(0, 1);
346 Epsilon_x(0, 6) = 6*x;
347 Epsilon_x(0, 7) = 2*y;
355 double x = Position(0, 0), y = Position(0, 1);
365 Epsilon_y(0, 8) = 2*x;
366 Epsilon_y(0, 9) = 6*y;
372 double x = Position(0, 0), y = Position(0, 1);
374 Epsilon_xy(0, 0) = 0;
375 Epsilon_xy(0, 1) = 0;
376 Epsilon_xy(0, 2) = 0;
377 Epsilon_xy(0, 3) = 0;
378 Epsilon_xy(0, 4) = 1;
379 Epsilon_xy(0, 5) = 0;
380 Epsilon_xy(0, 6) = 0;
381 Epsilon_xy(0, 7) = 2*x;
382 Epsilon_xy(0, 8) = 2*y;
383 Epsilon_xy(0, 9) = 0;
399 vector<CMatrix> Nodes;
404 Node(0, 0) =
m_P(i, 0);
405 Node(0, 1) =
m_P(i, 1);
406 Nodes.push_back(Node);
410 vector<CMatrix> Rows;
418 AMatrix(i, j) = Rows[i](0, j);
431 XMatrix(0, j) = R1(0, j);
432 XMatrix(1, j) = R2(0, j);
438 const double E =
m_E;
450 T(0, 0) = MatOrient.
x;
451 T(0, 1) = MatOrient.
y;
452 T(1, 0) = -MatOrient.
y;
453 T(1, 1) = MatOrient.
x;
467 double x = Position(0, 0), y = Position(0, 1);
477 double x = Position(0, 0), y = Position(0, 1);
487 double x = Position(0, 0), y = Position(0, 1);
Base class for representing finite elements.
void SetNodeCoordinates(const CMatrix &P)
virtual void GetDMatrix(CMatrix &DMatrix)=0
This is the material properties matrix (typically involving E and v)
virtual void GetAMatrix(CMatrix &AMatrix)=0
This is the coordinate matrix given nodal coordinates P.
void GetKeMatrix(CMatrix &KeMatrix)
void GetBMatrix(CMatrix &BMatrix, CMatrix &Position)
This is the dimension matrix which is composed of the A and X matrices (B=X*A^-1)
void SetIntegrationOrder(int iOrder)
virtual void GetXMatrix(CMatrix &XMatrix, CMatrix &Position)=0
This is the matrix which defines strain in terms of the coefficients.
virtual void GetIntegrationPoints(vector< INTEGRATION_POINT > &IntegrationPoints)=0
Defines a series of integration points.
CMatrix GetEpsilon_xyMatrix(CMatrix &Position)
This is d^2v/dxdy.
void GetDMatrix(CMatrix &DMatrix)
This is the material properties matrix (typically involving E and v)
CMatrix GetTheta_yMatrix(CMatrix &Position)
This is dv/dy.
CMatrix GetvMatrix(CMatrix &Position)
This is the matrix of displacement v in terms of coefficients C1, C2 ... C10.
void GetAMatrix(CMatrix &AMatrix)
This is the coordinate matrix given nodal coordinates P.
void GetXMatrix(CMatrix &XMatrix, CMatrix &Position)
This is the matrix which defines strain in terms of the coefficients.
CElementTriBending(const CMatrix &P=CMatrix(), int iOrder=3)
CElementTriBending ///.
CMatrix GetEpsilon_xMatrix(CMatrix &Position)
This is d^2v/dx^2.
CMatrix GetTheta_xMatrix(CMatrix &Position)
This is dv/dx.
CMatrix GetEpsilon_yMatrix(CMatrix &Position)
This is d^2v/dy^2.
Base class for representing triangular elements.
void GetIntegrationPoints(vector< INTEGRATION_POINT > &IntegrationPoints)
Defines a series of integration points.
CElementTri(const CMatrix &P, int iOrder)
CMatrix GetvMatrix(CMatrix &Position)
This is the matrix of displacement v in terms of coefficients C1, C2 and C3.
CMatrix GetEpsilon_xMatrix(CMatrix &Position)
This is dv/dx.
void GetAMatrix(CMatrix &AMatrix)
This is the coordinate matrix given nodal coordinates P.
void GetXMatrix(CMatrix &XMatrix, CMatrix &Position)
This is the matrix which defines strain in terms of the coefficients.
CElementTriTension(const CMatrix &P=CMatrix(), int iOrder=3)
CElementTriTension ///.
void GetDMatrix(CMatrix &DMatrix)
This is the material properties matrix (typically involving E and v)
CMatrix GetEpsilon_yMatrix(CMatrix &Position)
This is dv/dy.
Class to represent a matrix and perform various operations on it.
void Initialise(int iHeight, int iWidth)
CMatrix & EqualsMultipleTranspose(const CMatrix &LeftMatrix, const CMatrix &RightMatrix)
This function multiplies the transpose of the left matrix with the right matrix.
double GetInverse(CMatrix &Inverse) const
double GetDeterminant() const
CMatrix & EqualsTransposeMultiple(const CMatrix &LeftMatrix, const CMatrix &RightMatrix)
This function multiplies the transpose of the left matrix with the right matrix.
CMatrix & EqualsMultiple(const CMatrix &LeftMatrix, const CMatrix &RightMatrix)
This function multiplies the left matrix with the right matrix.
Namespace containing a series of customised math operations not found in the standard c++ library.
WXYZ & Normalise(WXYZ &Quaternion)
Normalise the quaternion and return it.
Struct for representing an integration point.
Struct for representing points in 2D space.