# UserMatDevice

## Structure

       int* dp_internal_fail
       int* dp_eroded
       int* dp_curve_data
    double* dp_curve_val
    double* dp_strain
    double* dp_dstrain
    double* dp_stress
    double* dp_f_mat
    double* dp_u_mat
    double* dp_init_volume
    double* dp_volume
    double* dp_history
    double* dp_eos_pressure
    double* dp_cmat
    double* dp_shear
    double* dp_bulk
    double* dp_xi
    double* dp_bfac
        int eos
        int num_history
     size_t num_ip
     size_t num_tasks
     size_t stride
     double dt0
     double dt
     double tt

## Variables

    int* dp_internal_fail

Integration point failure flag.

Access pattern: Per-thread arrays

    int* dp_eroded

Element eroded flag.

Access pattern: Subgroup-shared array (element level)

    int* dp_curve_data

Curve data.

Access pattern: Curve arrays

    double* dp_curve_val

Curve data.

Access pattern: Curve arrays

    double* dp_strain

Strain tensor.

Access pattern: Per-thread tensor arrays

    double* dp_dstrain

Strain increment tensor.

Access pattern: Per-thread tensor arrays

    double* dp_stress

Stress tensor.

Access pattern: Per-thread tensor arrays

    double* dp_f_mat

Deformation gradient matrix. This array is in stride format.

Access pattern: Per-thread 3x3 matrix arrays

    double* p_u_mat

Right stretch tensor.

Access pattern: Per-thread tensor arrays

    double* dp_init_volume

Initial volume of integration point.

Access pattern: Per-thread arrays

    double* dp_volume

Current volume of integration point.

Access pattern: Per-thread arrays

    double* dp_history

State variable array.

Access pattern: Per-thread arrays

    double* dp_eos_pressure

If Grüneisen equation of state is active, use is the pressure.

Access pattern: Per-thread arrays

    double* dp_cmat

Not used, currently a `nullptr`

> Note: Reserved for future implementation.

    double* dp_shear

Shear array used for critical time step calculation.

Access pattern: Per-thread arrays

    double* dp_bulk

Bulk array used for critical time step calculation.

Access pattern: Per-thread arrays

    double* dp_xi

Xi array used for critical time step calculation.

Access pattern: Per-thread arrays

    double* dp_bfac

Bfac array used for critical time step calculation.

Access pattern: Per-thread arrays

    int eos

Flag to indicate whether Grüneisen equation-of-state is active or not.

Use this flag to determine whether to use pressure from `dp_eos_pressure` or not.

    int num_history

Number of state variables for the current material model.

    size_t num_ip

Number of integration points of the current element.

    size_t num_tasks

Number of threads to be launched for the current material model.

    size_t stride

Stride used for arrays in stride format.

    double dt0

Previous time step.

    double dt1

Current time step.

    double tt

Current time.