<!-- source-page: 341 -->

```txt
2 KSPT, KSTEP, KINC, NDI, NSHR, COORD, JMAC, JMATYP, MATLABO, LACCFLA)
C
INCLUDE 'ABA_PARAM.INC'
C
CHARACTER*80 CMNAME, ORNAME
CHARACTER*3 FLGRAY(15)
DIMENSION FIELD(NFIELD), STATEV(NSTATV), DIRECT(3,3),
1 T(3,3), TIME(2)
DIMENSION ARRAY(15), JARRAY(15), JMAC(*), JMATYP(*), COORD(*)
user coding to define FIELD and, if necessary, STATEV and PNEWDT
RETURN
END 
```

# Variable to be defined

# FIELD(NFIELD)

An array containing the field variables at the current material point. These are passed in with the values interpolated from the nodes at the end of the current increment, as specified with initial condition definitions, predefined field variable definitions, or user subroutine UFIELD. The interpolation is performed using the same scheme used to interpolate temperatures: an average value is used for linear elements; an approximate linear variation is used for quadratic elements (also see “Solid (continuum) elements,” Section 28.1.1 of the Abaqus Analysis User’s Guide). The updated values are used to calculate the values of material properties that are defined to depend on field variables and are passed into other user subroutines (CREEP, HETVAL, UEXPAN, UHARD, UHYPEL, UMAT, UMATHT, and UTRS) that are called at this material point.

# Variables that can be updated

# STATEV(NSTATV)

An array containing the solution-dependent state variables. These are passed in as the values at the beginning of the increment. In all cases STATEV can be updated in this subroutine, and the updated values are passed into other user subroutines (CREEP, HETVAL, UEXPAN, UMAT, UMATHT, and UTRS) that are called at this material point. The number of state variables associated with this material point is defined as described in “Allocating space” in “User subroutines: overview,” Section 18.1.1 of the Abaqus Analysis User’s Guide.

# PNEWDT

Ratio of suggested new time increment to the time increment being used (DTIME, see below). This variable allows you to provide input to the automatic time incrementation algorithms in Abaqus/Standard (if automatic time incrementation is chosen).

<!-- source-page: 342 -->

PNEWDT is set to a large value before each call to USDFLD.

If PNEWDT is redefined to be less than 1.0, Abaqus/Standard must abandon the time increment and attempt it again with a smaller time increment. The suggested new time increment provided to the automatic time integration algorithms is PNEWDT × DTIME, where the PNEWDT used is the minimum value for all calls to user subroutines that allow redefinition of PNEWDT for this iteration.

If PNEWDT is given a value that is greater than 1.0 for all calls to user subroutines for this iteration and the increment converges in this iteration, Abaqus/Standard may increase the time increment. The suggested new time increment provided to the automatic time integration algorithms is PNEWDT × DTIME, where the PNEWDT used is the minimum value for all calls to user subroutines for this iteration.

If automatic time incrementation is not selected in the analysis procedure, values of PNEWDT that are greater than 1.0 will be ignored and values of PNEWDT that are less than 1.0 will cause the job to terminate.

# Variables passed in for information

# DIRECT(3,3)

An array containing the direction cosines of the material directions in terms of the global basis directions. DIRECT(1,1), DIRECT(2,1), DIRECT(3,1) give the (1, 2, 3) components of the first material direction; DIRECT(1,2), DIRECT(2,2), DIRECT(3,2) give the second material direction, etc. For shell and membrane elements, the first two directions are in the plane of the element and the third direction is the normal. This information is not available for beam elements.

# T(3,3)

An array containing the direction cosines of the material orientation components relative to the element basis directions. This is the orientation that defines the material directions (DIRECT) in terms of the element basis directions. For continuum elements T and DIRECT are identical. For shell and membrane elements T(1,1) , T(1,2) , T(2,1) , T(2,2) , T(3,3) , and all other components are zero, where is the counterclockwise rotation around the normal vector that defines the orientation. If no orientation is used, T is an identity matrix. Orientation is not available for beam elements.

# CELENT

Characteristic element length. This is a typical length of a line across an element for a first-order element; it is half of the same typical length for a second-order element. For beams and trusses it is a characteristic length along the element axis. For membranes and shells it is a characteristic length in the reference surface. For axisymmetric elements it is a characteristic length in the plane only.

# TIME(1)

Value of step time at the beginning of the current increment.

# TIME(2)

Value of total time at the beginning of the current increment.

<!-- source-page: 343 -->

# DTIME

Time increment.

# CMNAME

User-specified material name, left justified.

# ORNAME

User-specified local orientation name, left justified.

# NFIELD

Number of field variables defined at this material point.

# NSTATV

User-defined number of solution-dependent state variables (see “Allocating space” in “User subroutines: overview,” Section 18.1.1 of the Abaqus Analysis User’s Guide).

# NOEL

Element number.

# NPT

Integration point number.

# LAYER

Layer number (for composite shells and layered solids).

# KSPT

Section point number within the current layer.

# KSTEP

Step number.

# KINC

Increment number.

# NDI

Number of direct stress components at this point.

# NSHR

Number of shear stress components at this point.

# COORD

Coordinates at this material point.

# JMAC

Variable that must be passed into the GETVRM utility routine to access an output variable.

<!-- source-page: 344 -->

# JMATYP

Variable that must be passed into the GETVRM utility routine to access an output variable.

# MATLAYO

Variable that must be passed into the GETVRM utility routine to access an output variable.

# LACCFLA

Variable that must be passed into the GETVRM utility routine to access an output variable.

# Example: Damaged elasticity model

Included below is an example of user subroutine USDFLD. In this example a truss element is loaded in tension. A damaged elasticity model is introduced: the modulus decreases as a function of the maximum tensile strain that occurred during the loading history. The maximum tensile strain is stored as a solution-dependent state variable—see “Defining solution-dependent field variables” in “Predefined fields,” Section 34.6.1 of the Abaqus Analysis User’s Guide.

Input file   
```csv
*HEADING
DAMAGED ELASTICITY MODEL WITH USER SUBROUTINE USDFLD
*ELEMENT, TYPE=T2D2, ELSET=ONE
1, 1, 2
*NODE
1, 0., 0.
2, 10., 0.
*SOLID SECTION, ELSET=ONE, MATERIAL=ELASTIC
1.
*MATERIAL, NAME=ELASTIC
*ELASTIC, DEPENDENCIES=1
** Table of modulus values decreasing as a function
** of field variable 1.
2000., 0.3, 0., 0.00
1500., 0.3, 0., 0.01
1200., 0.3, 0., 0.02
1000., 0.3, 0., 0.04
*USER DEFINED FIELD
*DEPVAR
1
*BOUNDARY
1, 1, 2
2, 2
*STEP
*STATIC 
```

<!-- source-page: 345 -->

```csv
0.1, 1.0, 0.0, 0.1
*CLOAD
2, 1, 20.
*END STEP
*STEP
*STATIC
0.1, 1.0, 0.0, 0.1
*CLOAD
2, 1, 0.
*END STEP
*STEP, INC=20
*STATIC
0.1, 2.0, 0.0, 0.1
*CLOAD
2, 1, 40.
*END STEP 
```

User subroutine   
```fortran
SUBROUTINE USDFLD(FIELD,STATEV,PNEWDT,DIRECT,T,CELENT,
1 TIME,DTIME,CMNAME,ORNAME,NFIELD,NSTATV,NOEL,NPT,LAYER,
2 KSPT,KSTEP,KINC,NDI,NSHR,COORD,JMAC,JMATYP,MATLAYO,
3 LACCFLA)
C
INCLUDE 'ABA_PARAM.INC'
C
CHARACTER*80 CMNAME,ORNAME
CHARACTER*3 FLGRAY(15)
DIMENSION FIELD(NFIELD),STATEV(NSTATV),DIRECT(3,3),
1 T(3,3),TIME(2)
DIMENSION ARRAY(15),JARRAY(15),JMAC(*),JMATYP(*),
1 COORD(*)
C
C Absolute value of current strain:
CALL GETVRM('E',ARRAY,JARRAY,FLGRAY,JRCD,JMAC,JMATYP,
MATLAYO,LACCFLA)
EPS = ABS( ARRAY(1) )
C Maximum value of strain up to this point in time:
CALL GETVRM('SDV',ARRAY,JARRAY,FLGRAY,JRCD,JMAC,JMATYP,
MATLAYO,LACCFLA)
EPSMAX = ARRAY(1)
C Use the maximum strain as a field variable
FIELD(1) = MAX( EPS , EPSMAX ) 
```

<!-- source-page: 346 -->

```txt
C Store the maximum strain as a solution dependent state
C variable
    STATEV(1) = FIELD(1)
C If error, write comment to .DAT file:
    IF(JRCD.NE.0) THEN
    WRITE(6,*) 'REQUEST ERROR IN USDFLD FOR ELEMENT NUMBER ', 1    NOEL,'INTEGRATION POINT NUMBER ',NPT
    ENDIF
C
    RETURN
    END 
```

<!-- source-page: 347 -->

# 1.1.54 UTEMP: User subroutine to specify prescribed temperatures.

# Product: Abaqus/Standard

# References

• “Predefined fields,” Section 34.6.1 of the Abaqus Analysis User’s Guide   
• \*TEMPERATURE  
• “LE11: Solid cylinder/taper/sphere—temperature loading,” Section 4.2.11 of the Abaqus Benchmarks Guide   
• “UTEMP, UFIELD, UMASFL, and UPRESS,” Section 4.1.25 of the Abaqus Verification Guide

# Overview

User subroutine UTEMP:

• allows you to prescribe temperatures at the nodes of a model;   
• will be called whenever a current value of temperature is needed for a node that is listed under a user-defined temperature field definition;   
• ignores any temperatures provided for the associated temperature field definition outside the user subroutine; and   
• can be used to modify any temperatures read in from a results file.

# User subroutine interface

```txt
SUBROUTINE UTEMP(TEMP,NSECPT,KSTEP,KINC,TIME,NODE,COORDS)
C
INCLUDE 'ABA_PARAM.INC'
C
DIMENSION TEMP(NSECPT), TIME(2), COORDS(3)
C
user coding to define TEMP
RETURN
END 
```

<!-- source-page: 348 -->

# TEMP(NSECPT)

Array of temperature values at node number NODE. If the node is not connected to a beam or shell element, only one value of temperature must be returned (NSECPT=1). Otherwise, the number of temperatures to be returned depends on the mode of temperature and field variable input selected for the beam or shell section. The following cases are possible:

1. Temperatures and field variables for a beam section are given as values at the points shown in the beam section descriptions. The number of values required, NSECPT, is determined by the particular section type specified, as described in “Beam cross-section library,” Section 29.3.9 of the Abaqus Analysis User’s Guide.   
2. Temperatures and field variables are given as values at n equally spaced points through each layer of a shell section. The number of values required, NSECPT, is equal to n.   
3. Temperatures and field variables for a beam section are given as values at the origin of the crosssection together with gradients with respect to the 2-direction and, for three-dimensional beams, the 1-direction of the section; or temperatures and field variables for a shell section are given as values at the reference surface together with gradients with respect to the thickness. The number of values required, NSECPT, is 3 for three-dimensional beams, 2 for two-dimensional beams, and 2 for shells. Give the midsurface value first, followed by the first and (if necessary) second gradients, as described in “Beam elements,” Section 29.3 of the Abaqus Analysis User’s Guide, and “Shell elements,” Section 29.6 of the Abaqus Analysis User’s Guide.

You can also request temperatures to be set in one of two other ways: from a previously generated results file or via direct data input. When array TEMP is passed into user subroutine UTEMP, it will contain temperatures obtained from the results file only. You can modify these values within this routine. Any values given as direct data input will be ignored.

# Variables passed in for information

# NSECPT

Maximum number of section values required for any node in the model.

# KSTEP

Step number.

# KINC

Increment number.

# TIME(1)

Current value of step time.

# TIME(2)

Current value of total time.

<!-- source-page: 349 -->

# NODE

Node number.

# COORDS

An array containing the current coordinates of this point. These are the current coordinates if geometric nonlinearity is accounted for during the step (see “Defining an analysis,” Section 6.1.2 of the Abaqus Analysis User’s Guide); otherwise, the array contains the original coordinates of the node.

<!-- source-page: 350 -->
