ISAAR.MSolve.IGA/Elements/Structural/KirchhoffLoveShell.cs
/// <summary>
/// Calculates the stiffness matrix of the element.
/// </summary>
/// <param name="element">An element of type <see cref="NurbsKirchhoffLoveShellElement"/>.</param>
/// <returns>An <see cref="IMatrix"/> containing the stiffness matrix of an <see cref="NurbsKirchhoffLoveShellElement"/>.</returns>
Calculates the stiffness matrix of the element.
Calculates the stiffness matrix of the element .
public IMatrix StiffnessMatrix(IElement element)
        {
            var numberOfCP = element.Nodes.Count;
			Matrix stiffnessMatrixElement = Matrix.CreateZero(numberOfCP * 3,
                numberOfCP * 3);
			for (int j = 0; j < _gaussPoints.Length; j++)
			{
				var jacobianMatrix = CalculateJacobian(element, _shapeFunctions, j);
				var hessianMatrix = CalculateHessian(element, _shapeFunctions, j);
				var surfaceBasisVector1 = CalculateSurfaceBasisVector1(jacobianMatrix, 0);
				var surfaceBasisVector2 = CalculateSurfaceBasisVector1(jacobianMatrix, 1);
				var surfaceBasisVector3 = surfaceBasisVector1.CrossProduct(surfaceBasisVector2);
				var J1 = surfaceBasisVector3.Norm2();
				surfaceBasisVector3.ScaleIntoThis(1 / J1);
				var surfaceBasisVectorDerivative1 = CalculateSurfaceBasisVector1(hessianMatrix, 0);
				var surfaceBasisVectorDerivative2 = CalculateSurfaceBasisVector1(hessianMatrix, 1);
				var surfaceBasisVectorDerivative12 = CalculateSurfaceBasisVector1(hessianMatrix, 2);
                var material = materialsAtMidsurfaceGP[_gaussPoints[j]];
                material.TangentVectorV1 = surfaceBasisVector1.CopyToArray();
                material.TangentVectorV2 = surfaceBasisVector2.CopyToArray();
                material.NormalVectorV3 = surfaceBasisVector3.CopyToArray();
                material.Thickness = this._thickness;
                var membraneConstitutiveMatrix = material.MembraneConstitutiveMatrix;
                var bendingConstitutiveMatrix = material.BendingConstitutiveMatrix;
                var Bmembrane = CalculateMembraneDeformationMatrix(_shapeFunctions, j, surfaceBasisVector1,
                    surfaceBasisVector2, numberOfCP);
                var Bbending = CalculateBendingDeformationMatrix(surfaceBasisVector3, _shapeFunctions, j,
                    surfaceBasisVector2, surfaceBasisVectorDerivative1, surfaceBasisVector1, J1,
                    surfaceBasisVectorDerivative2, surfaceBasisVectorDerivative12, numberOfCP);
				var Kmembrane = Bmembrane.Transpose() * membraneConstitutiveMatrix * Bmembrane *  J1 *
								_gaussPoints[j].WeightFactor;
				var Kbending = Bbending.Transpose() * bendingConstitutiveMatrix * Bbending  * J1 *
							   _gaussPoints[j].WeightFactor;
				stiffnessMatrixElement.AddIntoThis(Kmembrane);
				stiffnessMatrixElement.AddIntoThis(Kbending);
			}
			return stiffnessMatrixElement;
		}
public IMatrix StiffnessMatrix ( IElement element ) { var numberOfCP = element . Nodes . Count ; Matrix stiffnessMatrixElement = Matrix . CreateZero ( numberOfCP * 3 , numberOfCP * 3 ) ; for ( int j = 0 ; j < _gaussPoints . Length ; j ++ ) { var jacobianMatrix = CalculateJacobian ( element , _shapeFunctions , j ) ; var hessianMatrix = CalculateHessian ( element , _shapeFunctions , j ) ; var surfaceBasisVector1 = CalculateSurfaceBasisVector1 ( jacobianMatrix , 0 ) ; var surfaceBasisVector2 = CalculateSurfaceBasisVector1 ( jacobianMatrix , 1 ) ; var surfaceBasisVector3 = surfaceBasisVector1 . CrossProduct ( surfaceBasisVector2 ) ; var J1 = surfaceBasisVector3 . Norm2 ( ) ; surfaceBasisVector3 . ScaleIntoThis ( 1 / J1 ) ; var surfaceBasisVectorDerivative1 = CalculateSurfaceBasisVector1 ( hessianMatrix , 0 ) ; var surfaceBasisVectorDerivative2 = CalculateSurfaceBasisVector1 ( hessianMatrix , 1 ) ; var surfaceBasisVectorDerivative12 = CalculateSurfaceBasisVector1 ( hessianMatrix , 2 ) ; var material = materialsAtMidsurfaceGP [ _gaussPoints [ j ] ] ; material . TangentVectorV1 = surfaceBasisVector1 . CopyToArray ( ) ; material . TangentVectorV2 = surfaceBasisVector2 . CopyToArray ( ) ; material . NormalVectorV3 = surfaceBasisVector3 . CopyToArray ( ) ; material . Thickness = this . _thickness ; var membraneConstitutiveMatrix = material . MembraneConstitutiveMatrix ; var bendingConstitutiveMatrix = material . BendingConstitutiveMatrix ; var Bmembrane = CalculateMembraneDeformationMatrix ( _shapeFunctions , j , surfaceBasisVector1 , surfaceBasisVector2 , numberOfCP ) ; var Bbending = CalculateBendingDeformationMatrix ( surfaceBasisVector3 , _shapeFunctions , j , surfaceBasisVector2 , surfaceBasisVectorDerivative1 , surfaceBasisVector1 , J1 , surfaceBasisVectorDerivative2 , surfaceBasisVectorDerivative12 , numberOfCP ) ; var Kmembrane = Bmembrane . Transpose ( ) * membraneConstitutiveMatrix * Bmembrane * J1 * _gaussPoints [ j ] . WeightFactor ; var Kbending = Bbending . Transpose ( ) * bendingConstitutiveMatrix * Bbending * J1 * _gaussPoints [ j ] . WeightFactor ; stiffnessMatrixElement . AddIntoThis ( Kmembrane ) ; stiffnessMatrixElement . AddIntoThis ( Kbending ) ; } return stiffnessMatrixElement ; }
Calculates the stiffness matrix of the element.
Calculates the stiffness matrix of the element .
An  containing the stiffness matrix of an .
An containing the stiffness matrix of an .
element
IElement
An element of type .
An element of type .