## Keyboard shortcuts

Press `←` or `→` to navigate between chapters

Press `S` or `/` to search in the book

Press `?` to show this help

Press `Esc` to hide this help

# UserMatInitCPU

## Structure

       int* p_curve_data
    double* p_curve_val
    double* p_strain
    double* p_stress
    double* p_coord
    double* p_history
    double* p_cmat
    double* p_stiffness
        int elem_id
        int ip_id
        int type
        int part_id
       int* p_face_ids
    double* p_face_area
    double* p_face_normal

## Variables

    int* p_curve_data

Curve data, used together with load_curve.

    double* p_curve_val

Curve data, used together with load_curve.

    double* p_strain

Strain tensor.

    double* p_stress

Stress tensor.

    double* p_coord

Node coordinate.

    double* p_history

History state variable array.

    double* p_cmat

Material parameters array.

    double* p_stiffness

Used for time step calculation.

- `0 = shear`
- `1 = bulk`
- `2 = xi`
- `3 = bfac`

    int elem_id

Element ID.

    int ip_id

Integration point ID.

    int type

Element type.

    int part_id

Part ID.

    int* p_face_ids

Array of (maximum 3) face IDs tied to the current integration point. Non-zero value for each external face.

    double* p_face_area

Area of the corresponding external face from `p_face_ids`. Use the index of `p_face_ids` where the value is not `0`.

    double* p_face_normal

Normal vector of the corresponding external face from `p_face_ids`. Use the index of `p_face_ids` where the value is not `0`.