KratosMultiphysics
KRATOS Multiphysics (Kratos) is a framework for building parallel, multi-disciplinary simulation software, aiming at modularity, extensibility, and high performance. Kratos is written in C++, and counts with an extensive Python interface.
Public Types | Static Public Member Functions | Static Public Attributes | List of all members
Kratos::MPMStressPrincipalInvariantsUtility Class Reference

#include <mpm_stress_principal_invariants_utility.h>

Collaboration diagram for Kratos::MPMStressPrincipalInvariantsUtility:

Public Types

typedef Matrix MatrixType
 
typedef Vector VectorType
 
typedef unsigned int IndexType
 
typedef unsigned int SizeType
 

Static Public Member Functions

static void SortPrincipalStress (Vector &rPrincipalStress, Vector &rMainStrain, Matrix &rMainDirections)
 Sort Principal Stresses, Strains, and Directions to magnitude order. More...
 
static void CalculateTensorInvariants (const Vector &rVector, double &rI1, double &rJ2)
 Calculate invariants I1 and J2 of a tensor. More...
 
static void CalculateTensorInvariants (const Vector &rVector, double &rI1, double &rJ2, double &rJ3)
 Calculate invariants I1, J2, and J3 of a tensor. More...
 
static void CalculateTensorInvariantsDerivatives (const Vector &rVector, Vector &rDI1, Vector &rDJ2, Vector &rDJ3)
 Calculate derivatives of invariants dI1/dtensor, dJ2/dtensor, and dJ3/dtensor. More...
 
static void CalculateTensorInvariantsSecondDerivatives (const Vector &rVector, Matrix &rD2I1, Matrix &rD2J2, Matrix &rD2J3)
 Calculate second derivatives of invariants d2I1/d2tensor, d2J2/d2tensor, and d2J3/d2tensor. More...
 
static void CalculateStressInvariants (const Vector &rStress, double &rMeanStressP, double &rDeviatoricQ)
 Calculate stress invariants p (volumetric equivalent) and q (deviatoric equivalent). More...
 
static void CalculateThirdStressInvariant (const Vector &rStress, double &rLodeAngle)
 Calculate the third stress invariants lode angle (we are using positive sine definition). More...
 
static void CalculateStressInvariants (const Vector &rStress, double &rMeanStressP, double &rDeviatoricQ, double &rLodeAngle)
 Calculate stress invariants p, q, and lode angle. More...
 
static void CalculateDerivativeVectors (const Vector rStress, Vector &rC1, Vector &rC2)
 Calculate stress invariant derivatives dp/dsigma (volumetric) and dq/dsigma (deviatoric). More...
 
static void CalculateDerivativeVectors (const Vector rStress, Vector &rC1, Vector &rC2, Vector &rC3)
 Calculate stress invariant derivatives dp/dsigma (volumetric), dq/dsigma (deviatoric), and dlodeangle/dsigma. More...
 
static void CalculateSecondDerivativeMatrices (const Vector rStress, Matrix &r2C1, Matrix &r2C2)
 Calculate second stress invariant derivatives d2p/d2sigma (volumetric) and d2q/d2sigma (deviatoric). More...
 
static void CalculateSecondDerivativeMatrices (const Vector rStress, Matrix &r2C1, Matrix &r2C2, Matrix &r2C3)
 Calculate second stress invariant derivatives d2p/d2sigma (volumetric), d2q/d2sigma (deviatoric), and d2lodeangle/d2sigma. More...
 
static Matrix PrincipalVectorToMatrix (const Vector &rVector, const unsigned int &rSize)
 Transform Stress or Principal stress tensor to Matrix form (fully assuming 3D space). More...
 
static Vector PrincipalMatrixtoVector (const Matrix &rMatrix, const unsigned int &rSize)
 Transform Stress or Principal stress tensor to Vector form (fully assuming 3D space). More...
 
static double CalculateMatrixDoubleContraction (const Matrix &rInput)
 
static double CalculateMatrixTrace (const Matrix &rInput)
 

Static Public Attributes

static constexpr double tolerance = 1.0e-9
 

Member Typedef Documentation

◆ IndexType

◆ MatrixType

◆ SizeType

◆ VectorType

Member Function Documentation

◆ CalculateDerivativeVectors() [1/2]

static void Kratos::MPMStressPrincipalInvariantsUtility::CalculateDerivativeVectors ( const Vector  rStress,
Vector rC1,
Vector rC2 
)
inlinestatic

Calculate stress invariant derivatives dp/dsigma (volumetric) and dq/dsigma (deviatoric).

Parameters
[in]rStressInput principal stress tensor.
[out]rC1Hydrostatic mean stress derivative with respect to principal stresses.
[out]rC2Deviatoric stress derivative with respect to principal stresses.

◆ CalculateDerivativeVectors() [2/2]

static void Kratos::MPMStressPrincipalInvariantsUtility::CalculateDerivativeVectors ( const Vector  rStress,
Vector rC1,
Vector rC2,
Vector rC3 
)
inlinestatic

Calculate stress invariant derivatives dp/dsigma (volumetric), dq/dsigma (deviatoric), and dlodeangle/dsigma.

Parameters
[in]rStressInput principal stress tensor.
[out]rC1Hydrostatic mean stress derivative with respect to principal stresses.
[out]rC2Deviatoric stress derivative with respect to principal stresses.
[out]rC3Derivative of lode angle with respect to principal stresses.

◆ CalculateMatrixDoubleContraction()

static double Kratos::MPMStressPrincipalInvariantsUtility::CalculateMatrixDoubleContraction ( const Matrix rInput)
inlinestatic

◆ CalculateMatrixTrace()

static double Kratos::MPMStressPrincipalInvariantsUtility::CalculateMatrixTrace ( const Matrix rInput)
inlinestatic

◆ CalculateSecondDerivativeMatrices() [1/2]

static void Kratos::MPMStressPrincipalInvariantsUtility::CalculateSecondDerivativeMatrices ( const Vector  rStress,
Matrix r2C1,
Matrix r2C2 
)
inlinestatic

Calculate second stress invariant derivatives d2p/d2sigma (volumetric) and d2q/d2sigma (deviatoric).

Parameters
[in]rStressInput principal stress tensor.
[out]r2C1Hydrostatic mean stress second derivative with respect to principal stresses.
[out]r2C2Deviatoric stress second derivative with respect to principal stresses.

◆ CalculateSecondDerivativeMatrices() [2/2]

static void Kratos::MPMStressPrincipalInvariantsUtility::CalculateSecondDerivativeMatrices ( const Vector  rStress,
Matrix r2C1,
Matrix r2C2,
Matrix r2C3 
)
inlinestatic

Calculate second stress invariant derivatives d2p/d2sigma (volumetric), d2q/d2sigma (deviatoric), and d2lodeangle/d2sigma.

Parameters
[in]rStressInput principal stress tensor.
[out]r2C1Hydrostatic mean stress second derivative with respect to principal stresses.
[out]r2C2Deviatoric stress second derivative with respect to principal stresses.
[out]r2C3Second Derivative of lode angle with respect to principal stresses.

◆ CalculateStressInvariants() [1/2]

static void Kratos::MPMStressPrincipalInvariantsUtility::CalculateStressInvariants ( const Vector rStress,
double rMeanStressP,
double rDeviatoricQ 
)
inlinestatic

Calculate stress invariants p (volumetric equivalent) and q (deviatoric equivalent).

Parameters
[in]rStressInput principal stress tensor.
[out]rMeanStressPHydrostatic mean stress.
[out]rDeviatoricQDeviatoric stress component.

◆ CalculateStressInvariants() [2/2]

static void Kratos::MPMStressPrincipalInvariantsUtility::CalculateStressInvariants ( const Vector rStress,
double rMeanStressP,
double rDeviatoricQ,
double rLodeAngle 
)
inlinestatic

Calculate stress invariants p, q, and lode angle.

Parameters
[in]rStressInput principal stress tensor.
[out]rMeanStressPHydrostatic mean stress.
[out]rDeviatoricQDeviatoric stress component.
[out]rLodeAngleThird stress invariant direction used for non-circular octahedral profile yield surface.

◆ CalculateTensorInvariants() [1/2]

static void Kratos::MPMStressPrincipalInvariantsUtility::CalculateTensorInvariants ( const Vector rVector,
double rI1,
double rJ2 
)
inlinestatic

Calculate invariants I1 and J2 of a tensor.

Parameters
[in]rVectorInput principal tensor.
[out]rI1First stress tensor invariant.
[out]rJ2Second stress deviator tensor invariant.

◆ CalculateTensorInvariants() [2/2]

static void Kratos::MPMStressPrincipalInvariantsUtility::CalculateTensorInvariants ( const Vector rVector,
double rI1,
double rJ2,
double rJ3 
)
inlinestatic

Calculate invariants I1, J2, and J3 of a tensor.

Parameters
[in]rVectorInput principal tensor.
[out]rI1First stress tensor invariant.
[out]rJ2Second stress deviator tensor invariant.
[out]rJ3Third stress deviator tensor invariant.

◆ CalculateTensorInvariantsDerivatives()

static void Kratos::MPMStressPrincipalInvariantsUtility::CalculateTensorInvariantsDerivatives ( const Vector rVector,
Vector rDI1,
Vector rDJ2,
Vector rDJ3 
)
inlinestatic

Calculate derivatives of invariants dI1/dtensor, dJ2/dtensor, and dJ3/dtensor.

Parameters
[in]rVectorInput principal tensor.
[out]rDI1First derivative of first stress tensor invariant.
[out]rDJ2First derivative of second stress deviator tensor invariant.
[out]rDJ3First derivative of third stress deviator tensor invariant.

◆ CalculateTensorInvariantsSecondDerivatives()

static void Kratos::MPMStressPrincipalInvariantsUtility::CalculateTensorInvariantsSecondDerivatives ( const Vector rVector,
Matrix rD2I1,
Matrix rD2J2,
Matrix rD2J3 
)
inlinestatic

Calculate second derivatives of invariants d2I1/d2tensor, d2J2/d2tensor, and d2J3/d2tensor.

Parameters
[in]rVectorInput principal tensor.
[out]rD2I1Second derivative of first stress tensor invariant.
[out]rD2J2Second derivative of second stress deviator tensor invariant.
[out]rD2J3Second derivative of third stress deviator tensor invariant.

◆ CalculateThirdStressInvariant()

static void Kratos::MPMStressPrincipalInvariantsUtility::CalculateThirdStressInvariant ( const Vector rStress,
double rLodeAngle 
)
inlinestatic

Calculate the third stress invariants lode angle (we are using positive sine definition).

Parameters
[in]rStressInput principal tensor.
[out]rLodeAngleThird stress invariant direction used for non-circular octahedral profile yield surface.

◆ PrincipalMatrixtoVector()

static Vector Kratos::MPMStressPrincipalInvariantsUtility::PrincipalMatrixtoVector ( const Matrix rMatrix,
const unsigned int rSize 
)
inlinestatic

Transform Stress or Principal stress tensor to Vector form (fully assuming 3D space).

Parameters
[in]rMatrixMatrix tensor to be transformed.
[in]rSizeMatrix size, 3 for only principal stresses, 6 for normal stresses.
Returns
transformed vector.

◆ PrincipalVectorToMatrix()

static Matrix Kratos::MPMStressPrincipalInvariantsUtility::PrincipalVectorToMatrix ( const Vector rVector,
const unsigned int rSize 
)
inlinestatic

Transform Stress or Principal stress tensor to Matrix form (fully assuming 3D space).

Parameters
[in]rVectorVector tensor to be transformed.
[in]rSizeMatrix size, 3 for only principal stresses, 6 for normal stresses.
Returns
transformed matrix.

◆ SortPrincipalStress()

static void Kratos::MPMStressPrincipalInvariantsUtility::SortPrincipalStress ( Vector rPrincipalStress,
Vector rMainStrain,
Matrix rMainDirections 
)
inlinestatic

Sort Principal Stresses, Strains, and Directions to magnitude order.

Parameters
[in/out]rPrincipalStress The principal stresses to be sorted in descending magnitude order.
[in/out]rMainStrain The principal strain corresponding to the stresses.
[in/out]rMainDirections The eigen directions corresponding to the stresses.

Member Data Documentation

◆ tolerance

constexpr double Kratos::MPMStressPrincipalInvariantsUtility::tolerance = 1.0e-9
staticconstexpr

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