Skip to content

stag

gripyth.solving.stag

Staggered solver.

MODULE DESCRIPTION
integration

Helper routines for numerical integration.

CLASS DESCRIPTION
StagParameters

Parameters for the staggered solver.

StagVariables

Variables table of the staggered solver.

FUNCTION DESCRIPTION
post_iter_update

Update after iteration of the staggered solver.

StagParameters dataclass

Parameters for the staggered solver.

ATTRIBUTE DESCRIPTION
max_iter

maximum number of iterations

TYPE: int

tol

tolerance

TYPE: float

max_iter class-attribute instance-attribute

max_iter: int = 1000

maximum number of iterations

tol class-attribute instance-attribute

tol: float = 0.0001

tolerance

StagVariables dataclass

Variables table of the staggered solver.

METHOD DESCRIPTION
__init__

Creates staggered solver variables.

__init__

__init__(parameters: StagParameters)

Creates staggered solver variables.

Arrays of length max_iter are allocated for each variable.

post_iter_update

post_iter_update(
    split_type: SplitType,
    i_stag: int,
    variables: StagVariables,
    mesh: Mesh,
    geometry: Geometry,
    material: Material,
    elasticity_tensor: NDArray[float64],
    stress_state: StressState,
    dofs: Dofs,
    quadrature: Quadrature,
    stiffness_matrix: StiffnessMatrix,
    dissipation: DissipationFunction,
    d_rhs_tract: NDArray[float64],
    p_field: NDArray[float64],
    displ: NDArray[float64],
    res_pf_0: float,
    res_pf: float,
    res_displ_0: float,
    parameters: StagParameters,
) -> tuple[
    StagVariables, NDArray[float64], bool, NDArray[float64]
]

Update after iteration of the staggered solver.