The Constitutive Library

simcoon.Ireal(*args, **kwargs)

Deprecated: use Tensor4.identity(‘stiffness’).mat.

simcoon.Ivol(*args, **kwargs)

Deprecated: use Tensor4.volumetric(‘stiffness’).mat.

simcoon.Idev(*args, **kwargs)

Deprecated: use Tensor4.deviatoric(‘stiffness’).mat.

simcoon.Ireal2(*args, **kwargs)

Deprecated: use Tensor4.identity(‘compliance’).mat.

simcoon.Idev2(*args, **kwargs)

Deprecated: use Tensor4.deviatoric(‘compliance’).mat.

simcoon.Ith(copy: bool = True) numpy.typing.NDArray[numpy.float64]

Returns the expansion vector \(I_{th}\).

Parameters:

copy (bool, optional) – If true, a copy of the vector is returned. Default is true.

Returns:

The expansion vector \(I_{th}\).

Return type:

pybind11::array_t<double>

Notes

The vector is defined as:

\[\begin{split}I_{th} = \begin{bmatrix} 1 \\ 1 \\ 1 \\ 0 \\ 0 \\ 0 \end{bmatrix}\end{split}\]

Examples

import numpy as np
import simcoon as sim

# Example for Ith
Ith = sim.Ith()
print(Ith)
simcoon.Ir2(copy: bool = True) numpy.typing.NDArray[numpy.float64]

Returns the operator from stress to strain in Voigt notation \(I_{r2}\).

Parameters:

copy (bool, optional) – If true, a copy of the operator is returned. Default is true.

Returns:

The operator \(I_{r2}\) in Voigt notation.

Return type:

pybind11::array_t<double>

Notes

The operator is defined as:

\[\begin{split}I_{r2} = \begin{bmatrix} 1 \\ 1 \\ 1 \\ 2 \\ 2 \\ 2 \end{bmatrix}\end{split}\]

Examples

import numpy as np
import simcoon as sim

# Example for Ir2
Ir2 = sim.Ir2()
print(Ir2)
simcoon.Ir05(copy: bool = True) numpy.typing.NDArray[numpy.float64]

Returns the operator from strain to stress in Voigt notation \(I_{r05}\).

Parameters:

copy (bool, optional) – If true, a copy of the operator is returned. Default is true.

Returns:

The operator \(I_{r05}\) in Voigt notation.

Return type:

pybind11::array_t<double>

Notes

The operator is defined as:

\[\begin{split}I_{r05} = \begin{bmatrix} 1 \\ 1 \\ 1 \\ 0.5 \\ 0.5 \\ 0.5 \end{bmatrix}\end{split}\]

Examples

import numpy as np
import simcoon as sim

# Example for Ir05
Ir05 = sim.Ir05()
print(Ir05)
simcoon.L_iso(props: Annotated[numpy.typing.ArrayLike, numpy.float64], conv: str, copy: bool = True) numpy.typing.NDArray[numpy.float64]

Provides the elastic stiffness tensor for an isotropic material.

Parameters:
  • props (pybind11::array_t<double>) – A 1D array containing the material properties (e.g., Lamé coefficients).

  • conv (str) – A string specifying the convention used for the material properties. Possible values include: ‘Enu’, ‘nuE’, ‘Kmu’, ‘muK’, ‘KG’, ‘GK’, ‘lambdamu’, ‘mulambda’, ‘lambdaG’, ‘Glambda’.

  • copy (bool, optional) – If true, a copy of the tensor is returned. Default is true.

Returns:

The 6x6 stiffness matrix in Voigt notation.

Return type:

pybind11::array_t<double>

Notes

The stiffness tensor is computed based on the provided material properties and convention.

Examples

import numpy as np
import simcoon as sim

# Example for L_iso
props = np.array([210000, 0.3])
L_iso = sim.L_iso(props, "Enu")
print(L_iso)
simcoon.M_iso(props: Annotated[numpy.typing.ArrayLike, numpy.float64], conv: str, copy: bool = True) numpy.typing.NDArray[numpy.float64]

Provides the elastic compliance tensor for an isotropic material.

Parameters:
  • props (pybind11::array_t<double>) – A 1D array containing the material properties (e.g., Lamé coefficients).

  • conv (str) – A string specifying the convention used for the material properties. Possible values include: ‘Enu’, ‘nuE’, ‘Kmu’, ‘muK’, ‘KG’, ‘GK’, ‘lambdamu’, ‘mulambda’, ‘lambdaG’, ‘Glambda’.

  • copy (bool, optional) – If true, a copy of the tensor is returned. Default is true.

Returns:

The 6x6 compliance matrix in Voigt notation.

Return type:

pybind11::array_t<double>

Notes

The compliance tensor is computed based on the provided material properties and convention.

Examples

import numpy as np
import simcoon as sim

# Example for M_iso
props = np.array([210000, 0.3])
M_iso = sim.M_iso(props, "Enu")
print(M_iso)
simcoon.L_cubic(props: Annotated[numpy.typing.ArrayLike, numpy.float64], conv: str, copy: bool = True) numpy.typing.NDArray[numpy.float64]

Provides the elastic stiffness tensor for a cubic material.

Parameters:
  • props (pybind11::array_t<double>) – A 1D array containing the stiffness coefficients (C11, C12, C44).

  • conv (str) – A string specifying the convention used for the material properties. Possible values include: ‘Cii’.

  • copy (bool, optional) – If true, a copy of the tensor is returned. Default is true.

Returns:

The 6x6 stiffness matrix in Voigt notation.

Return type:

pybind11::array_t<double>

Notes

The stiffness tensor is computed based on the provided stiffness coefficients and convention.

Examples

import numpy as np
import simcoon as sim

# Example for L_cubic
props_cubic = np.array([100000, 50000, 30000])
L_cubic = sim.L_cubic(props_cubic, "Cii")
print(L_cubic)
simcoon.M_cubic(props: Annotated[numpy.typing.ArrayLike, numpy.float64], conv: str, copy: bool = True) numpy.typing.NDArray[numpy.float64]

Provides the elastic compliance tensor for a cubic material.

Parameters:
  • props (pybind11::array_t<double>) – A 1D array containing the stiffness coefficients (C11, C12, C44).

  • conv (str) – A string specifying the convention used for the material properties. Possible values include: ‘Cii’.

  • copy (bool, optional) – If true, a copy of the tensor is returned. Default is true.

Returns:

The 6x6 compliance matrix in Voigt notation.

Return type:

pybind11::array_t<double>

Notes

The compliance tensor is computed based on the provided stiffness coefficients and convention.

Examples

import numpy as np
import simcoon as sim

# Example for M_cubic
props_cubic = np.array([100000, 50000, 30000])
M_cubic = sim.M_cubic(props_cubic, "Cii")
print(M_cubic)
simcoon.L_ortho(props: Annotated[numpy.typing.ArrayLike, numpy.float64], conv: str, copy: bool = True) numpy.typing.NDArray[numpy.float64]

Provides the elastic stiffness tensor for an orthotropic material.

Parameters:
  • props (pybind11::array_t<double>) – A 1D array containing the stiffness coefficients or material parameters.

  • conv (str) – A string specifying the convention used for the material properties. Possible values include: ‘Cii’, ‘EnuG’.

  • copy (bool, optional) – If true, a copy of the tensor is returned. Default is true.

Returns:

The 6x6 stiffness matrix in Voigt notation.

Return type:

pybind11::array_t<double>

Notes

The stiffness tensor is computed based on the provided coefficients or material parameters and convention.

Examples

import numpy as np
import simcoon as sim

# Example for L_ortho
props_ortho = np.array([100000, 50000, 30000, 0.3, 0.3, 0.3, 40000, 40000, 40000])
L_ortho = sim.L_ortho(props_ortho, "EnuG")
print(L_ortho)
simcoon.M_ortho(props: Annotated[numpy.typing.ArrayLike, numpy.float64], conv: str, copy: bool = True) numpy.typing.NDArray[numpy.float64]

Provides the elastic compliance tensor for an orthotropic material.

Parameters:
  • props (pybind11::array_t<double>) – A 1D array containing the stiffness coefficients or material parameters.

  • conv (str) – A string specifying the convention used for the material properties. Possible values include: ‘Cii’, ‘EnuG’.

  • copy (bool, optional) – If true, a copy of the tensor is returned. Default is true.

Returns:

The 6x6 compliance matrix in Voigt notation.

Return type:

pybind11::array_t<double>

Notes

The compliance tensor is computed based on the provided coefficients or material parameters and convention.

Examples

import numpy as np
import simcoon as sim

# Example for M_ortho
props_ortho = np.array([100000, 50000, 30000, 0.3, 0.3, 0.3, 40000, 40000, 40000])
M_ortho = sim.M_ortho(props_ortho, "EnuG")
print(M_ortho)
simcoon.L_isotrans(props: Annotated[numpy.typing.ArrayLike, numpy.float64], axis: SupportsInt | SupportsIndex, copy: bool = True) numpy.typing.NDArray[numpy.float64]

Provides the elastic stiffness tensor for an isotropic transverse material.

Parameters:
  • props (pybind11::array_t<double>) – A 1D array containing the material properties (e.g., EL, ET, nuTL, nuTT, GLT).

  • axis (int) – The axis of symmetry.

  • copy (bool, optional) – If true, a copy of the tensor is returned. Default is true.

Returns:

The 6x6 stiffness matrix in Voigt notation.

Return type:

pybind11::array_t<double>

Notes

The stiffness tensor is computed based on the provided material properties and axis of symmetry.

Examples

import numpy as np
import simcoon as sim

# Example for L_isotrans
props_isotrans = np.array([210000, 70000, 0.3, 0.3, 50000])
axis = 1
L_isotrans = sim.L_isotrans(props_isotrans, axis)
print(L_isotrans)
simcoon.M_isotrans(props: Annotated[numpy.typing.ArrayLike, numpy.float64], axis: SupportsInt | SupportsIndex, copy: bool = True) numpy.typing.NDArray[numpy.float64]

Provides the elastic compliance tensor for an isotropic transverse material.

Parameters:
  • props (pybind11::array_t<double>) – A 1D array containing the material properties (e.g., EL, ET, nuTL, nuTT, GLT).

  • axis (int) – The axis of symmetry.

  • copy (bool, optional) – If true, a copy of the tensor is returned. Default is true.

Returns:

The 6x6 compliance matrix in Voigt notation.

Return type:

pybind11::array_t<double>

Notes

The compliance tensor is computed based on the provided material properties and axis of symmetry.

Examples

import numpy as np
import simcoon as sim

# Example for M_isotrans
props_isotrans = np.array([210000, 70000, 0.3, 0.3, 50000])
axis = 1
M_isotrans = sim.M_isotrans(props_isotrans, axis)
print(M_isotrans)
simcoon.H_iso(props: Annotated[numpy.typing.ArrayLike, numpy.float64], copy: bool = True) numpy.typing.NDArray[numpy.float64]

Provides the viscous tensor for an isotropic material.

Parameters:
  • props_py (pybind11::array_t<double>) – A 1D array containing the viscous coefficients (bulk and shear).

  • copy (bool, optional) – If true, a copy of the tensor is returned. Default is true.

Returns:

The 6x6 viscous matrix in Voigt notation.

Return type:

pybind11::array_t<double>

Notes

The viscous tensor is computed based on the provided bulk and shear coefficients.

Examples

import numpy as np
import simcoon as sim

# Example for H_iso
props_viscous = np.array([0.1, 0.05])
H_iso = sim.H_iso(props_viscous)
print(H_iso)