Public Member Functions | List of all members
Q9Element Class Reference

Class for implementation of Q9 elements. More...

#include <Q9Element.h>

Inheritance diagram for Q9Element:
QuadrilateralElement Element

Public Member Functions

void calculateStiffnessMatrix ()
 Calculates stiffness matrix \(\boldsymbol{K}\). More...
 
MatrixXd getNMatrix (double xi, double eta)
 Calculates and returns \(\boldsymbol{N}\) for this element type. More...
 
MatrixXd getBMatrix (MatrixXd jacobi, double xi, double eta)
 Calculates and returns \(\boldsymbol{B}\) for this element type. More...
 
MatrixXd getJacobi (double xi, double eta)
 Calculates and returns \(\boldsymbol{J}\) for this element type. More...
 
MatrixXd getN_xiMatrix (double xi, double eta)
 Calculates and returns \(\boldsymbol{N}_\xi\) for this element type. More...
 
MatrixXd getN_etaMatrix (double xi, double eta)
 Calculates and returns \(\boldsymbol{N}_\eta\) for this element type. More...
 
- Public Member Functions inherited from QuadrilateralElement
void setExtrapolationMatrix ()
 Creates the matrix used for extrapolating results. More...
 
void resetElementLoad ()
 resets element load to zero
 
void calculateElementLoadTorsion ()
 Calculates the initial load vector for torsion \(\boldsymbol{S}^0\). Load vector is negative for torsion loading to match global load vector. More...
 
void calculateElementLoadShearX ()
 Calculates the initial load vector \(\boldsymbol{S}_x^0\) for applied shear along x-axis. More...
 
void calculateElementLoadShearY ()
 Calculates the initial load vector \(\boldsymbol{S}_y^0\) for applied shear along y-axis. More...
 
void checkBMatrix ()
 Method verifies \( \boldsymbol{B} \). More...
 
void checkNMatrix ()
 Method verifies \(\boldsymbol{N}\). More...
 
void computeTauTorsion (double rateOfTwist)
 Calculates shear stresses from torsion load at nodes using initialStrain and elementsDisplacement. For quadrilateral elements the stresses are calculated at the integration points (using xiCoord and etaCoord). The stress values are then extrapolated to the nodes using setExtrapolationMatrix(). More...
 
void computeTauShear (double Cx, double Cy)
 Calculates shear stresses from shear loading at nodes using elementsDisplacement. For quadrilateral elements the stresses are calculated at the integration points (using xiCoord and etaCoord). The stress values are then extrapolated to the nodes using setExtrapolationMatrix(). More...
 
double xOfZeta (double xi, double eta)
 Calculates and returns the the distance in the x-direction between the integration point in the element and the element area centre. More...
 
double yOfZeta (double xi, double eta)
 Calculates and returns the the distance in the y-direction between the integration point in the element and the element area centre. More...
 
void calculateArea ()
 Calculates the area of the element. More...
 
void calculateAreaCentre ()
 Calculates the area centre of the element. More...
 
double getBendingStiffnessX (double Ay)
 Calculates the second moment of area about the x-axis for the element. More...
 
double getBendingStiffnessY (double Ax)
 Calculates the second moment of area about the y-axis for the element. More...
 
double getBendingStiffnessProduct (double Ax, double Ay)
 Calculating the product of moment of inertia. More...
 
double calculateDeltaGIt ()
 Calculates delta GIt for the element, used to find gloal GIt for torsional analysis. More...
 
void calculateTorsionShearCenter ()
 Calculates the shear center for the element, based on torsional analysis. More...
 
MatrixXd getN1Matrix (double xi, double eta)
 Gets the \( \textbf{N}_1 matrix\). More...
 
double getShearFactorContributionX ()
 Gets the shear deformation factor contribution from the element, in x-direction. More...
 
double getShearFactorContributionY ()
 Gets the shear deformation factor contribution from the element, in y-direction. More...
 
void calculateElementLoadComposite (double C_x, double C_y, double rateOfTwist)
 Calculates the element load for composite analysis. More...
 
void computeTauComposite (double C_x, double C_y, double rateOfTwist)
 Calculates the element stresses at the integration points for composite analysis. More...
 
- Public Member Functions inherited from Element
 Element ()
 Constructor.
 
void calculateConstants (int type)
 Initiates XoverY, xCoordinates, and yCoordinates for all massive element types. More...
 
void setElementValue (MatrixXd &system, MatrixXd &local)
 Uses getIEG() to assign system values to corresponding local parameters.
 
MatrixXd getZeroVector ()
 Initate a vector with numer of columns equal to number of nodes.
 

Additional Inherited Members

- Public Attributes inherited from QuadrilateralElement
double xiCoord [2][2] = { { -sqrt(1 / 3.0), sqrt(1 / 3.0) } ,{ sqrt(1 / 3.0), -sqrt(1 / 3.0) } }
 
double etaCoord [2][2] = { { -sqrt(1 / 3.0), -sqrt(1 / 3.0) } ,{ sqrt(1 / 3.0), sqrt(1 / 3.0) } }
 
double weights [2][2] = { { 1, 1 } ,{ 1, 1 } }
 
double xiExtrapolation [2][2] = { { -sqrt(3), sqrt(3) },{ sqrt(3), -sqrt(3) } }
 
double etaExtrapolation [2][2] = { { -sqrt(3), -sqrt(3) } ,{ sqrt(3), sqrt(3) } }
 
double xiCoord3x3 [3][3] = { { -sqrt(0.6), sqrt(0.6) , sqrt(0.6) },{ -sqrt(0.6), 0, sqrt(0.6) },{ 0, -sqrt(0.6), 0 } }
 
double etaCoord3x3 [3][3] = { { -sqrt(0.6), -sqrt(0.6), sqrt(0.6) },{ sqrt(0.6), -sqrt(0.6), 0 },{ sqrt(0.6), 0, 0 } }
 
double weights3x3 [3][3] = { { 25.0 / 81 , 25.0 / 81 , 25.0 / 81 },{ 25.0 / 81 , 40.0 / 81, 40.0 / 81 },{ 40.0 / 81, 40.0 / 81, 64.0 / 81 } }
 
std::vector< std::vector< MatrixXd > > N
 Vector used for storing values of the N matrix.
 
std::vector< std::vector< MatrixXd > > N1
 Vector used for storing values of the N1 matrix.
 
std::vector< std::vector< MatrixXd > > J
 Vector used for storing values of the Jacobian Matrix.
 
std::vector< std::vector< MatrixXd > > B
 Vector used for storing values of the B matrix.
 
std::vector< std::vector< double > > xIntegration
 Vector used for storing x-coordinate values.
 
std::vector< std::vector< double > > yIntegration
 Vector used for storing y-coordinate values.
 
- Public Attributes inherited from Element
std::vector< Nodenodes
 Vector containing nodes of the element.
 
double area
 Elements total area.
 
Material material
 Elements material with Youngs modulus, poisson's ratio and shear modulus.
 
int elementType
 Defines what type of element this element is (value '2' for T3,'9' for T6, '3' for Q4 and '10' for Q9)
 
int numberOfCorners
 Number of corner nodes for the element. 3 for triangular and 4 for quadrilateral.
 
double Iex
 Elements second area moment about x-axis.
 
double Iey
 Elements second area moment about y-axis.
 
double Iexy
 Elements second area moment product.
 
double ecx
 Elements area centre in x-direction.
 
double ecy
 Elements area centre in y-direction.
 
double dx
 Distance in x-direction between mesh- and node area centre.
 
double dy
 Distance in y-direction between mesh- and node area centre.
 
double deltaGIt
 Contribution to St.Venant stiffness of the cross-section ( \( GI_t\)) from this element.
 
double torsion_xs
 Shear center in x-direction derived from torsional analysis.
 
double torsion_ys
 Shear center in y-direction derived from torsional analysis.
 
MatrixXd B
 Matrix containing differentials of shapefunction with respect to x and y respectively. 2 rows , number of columns equals number of nodes.
 
MatrixXd G
 Matrix with shear module used to determine initial element loads in torsional analysis. 2x2 matrix.
 
MatrixXd XoverY
 Matrix with all x-coordinates followed by all y-coordinates for the nodes in order. Number of rows equal number of nodes times two.
 
MatrixXd xCoordinates
 Matrix with x-coordinates for the nodes in order. Number of rows equal number of nodes.
 
MatrixXd yCoordinates
 Matrix with y-coordinates for the nodes in order. Number of rows equal number of nodes.
 
MatrixXd cornerCoordinatesX
 x-position of corner nodes
 
MatrixXd cornerCoordinatesY
 y-position of corner nodes
 
MatrixXd elementStiffness
 Matrix used to temporarily hold element stiffnes coefficients, \(\boldsymbol{K}_e\).
 
MatrixXd elementLoad
 Matrix used to temporarily hold element load coefficients, \(\boldsymbol{S}^0\).
 
MatrixXd elementDisplacement
 Matrix used to temporarily hold element displacement values, \( \boldsymbol{v} \).
 
MatrixXd initialStrain
 Matrix used to temporarily hold element initial strain coefficients, \( \boldsymbol{\epsilon}_0 \).
 
MatrixXd tauResult
 Stores the tau values of the element temporarily, before it's written to file.
 
MatrixXd extrapolationMatrix
 Matrix used for extrapolating stress results.
 

Detailed Description

Class for implementation of Q9 elements.

Member Function Documentation

void Q9Element::calculateStiffnessMatrix ( )
virtual

Calculates stiffness matrix \(\boldsymbol{K}\).

\( \boldsymbol{K} = \int_A \boldsymbol{B}^T \boldsymbol{G} \boldsymbol{B} dA \)

Implements Element.

MatrixXd Q9Element::getBMatrix ( MatrixXd  jacobi,
double  xi,
double  eta 
)
virtual

Calculates and returns \(\boldsymbol{B}\) for this element type.

\( \boldsymbol{B} = \frac{1}{4}\boldsymbol{J}^{-1} \begin{bmatrix} \boldsymbol{N_\xi} \\ \boldsymbol{N_\eta} \\ \end{bmatrix}\)

Parameters
jacobi\(\boldsymbol{J}\) for this integration point
xixi-value of integration point
etaeta-value of integration point
Returns
\(\boldsymbol{B}\)

Implements QuadrilateralElement.

MatrixXd Q9Element::getJacobi ( double  xi,
double  eta 
)
virtual

Calculates and returns \(\boldsymbol{J}\) for this element type.

\( \boldsymbol{J} \;\; = \;\; \begin{bmatrix} \frac{\partial \boldsymbol{N} \boldsymbol{x}}{\partial \xi} & \frac{\partial \boldsymbol{N} \boldsymbol{y}}{\partial \xi} \\[6pt] \frac{\partial \boldsymbol{N} \boldsymbol{x}}{\partial \eta} & \frac{\partial \boldsymbol{N} \boldsymbol{y}}{\partial \eta} & \end{bmatrix}\)

Parameters
xixi-value of integration point
etaeta-value of integration point
Returns
\(\boldsymbol{J}\)

Implements QuadrilateralElement.

MatrixXd Q9Element::getN_etaMatrix ( double  xi,
double  eta 
)
virtual

Calculates and returns \(\boldsymbol{N}_\eta\) for this element type.

\( \boldsymbol{N_{\eta}}^T = \;\; \frac{1}{4} \begin{bmatrix} \xi (\xi-1)(2\eta-1) \\ \xi (\xi+1)(2\eta - 1) \\ \xi (\xi + 1)(2\eta +1) \\ \xi (\xi+1)(2\eta+1) \\ -2(\xi^2-1)(2\eta - 1)\\ -4\xi\eta(\xi+1) \\ -2(\xi^2-1)(2\eta+1) \\ -4\xi\eta(\xi-1) \\ 8 \eta(\xi^2-1) \end{bmatrix}\)

Parameters
xixi-value of integration point
etaeta-value of integration point
Returns
\(N_{\eta}\)

Implements QuadrilateralElement.

MatrixXd Q9Element::getN_xiMatrix ( double  xi,
double  eta 
)
virtual

Calculates and returns \(\boldsymbol{N}_\xi\) for this element type.

\( \boldsymbol{N_\xi}^T \;\; = \;\; \frac{1}{4} \begin{bmatrix} \eta (\eta-1)(2\xi-1) \\ \eta (\eta-1)(1 + 2\xi) \\ \eta (1 + \eta)(1 + 2\xi) \\ \eta (\eta+1)(2\xi-1) \\ -4\xi\eta(\eta-1) \\ -2(\eta^2-1)(2\xi+1) \\ -4\xi\eta(\eta+1) \\ -2(\eta^2-1)(2\xi-1) \\ 8 \xi(\eta^2-1) \end{bmatrix}\)

Parameters
xixi-value of integration point
etaeta-value of integration point
Returns
\(N_{\xi}\)

Implements QuadrilateralElement.

MatrixXd Q9Element::getNMatrix ( double  xi,
double  eta 
)
virtual

Calculates and returns \(\boldsymbol{N}\) for this element type.

\( \boldsymbol{N}^T \;\; = \;\; \frac{1}{4} \begin{bmatrix} \xi\eta (\xi-1)(\eta-1) \\ \xi\eta (\xi+1)(\eta-1) \\ \xi\eta (\xi+1)(\eta+1) \\ \xi\eta (\xi-1)(\eta+1) \\ -2\eta(\eta-1)(\xi^2-1) \\ -2\xi(\xi+1)(\eta^2-1) \\ -2\eta(\eta+1)(\xi^2-1) \\ -2\xi(\xi-1)(\eta^2-1) \\ 4 (\xi^2-1)(\eta^2-1) \end{bmatrix} \)

Parameters
xixi-value of integration point
etaeta-value of integration point
Returns
\(\boldsymbol{N}\)

Implements QuadrilateralElement.


The documentation for this class was generated from the following files: