## 3.3. Formal Parameters

Most of the user subroutines have formal parameters. There are comments at the head of the subroutines defining each parameter, stating whether the parameter is an input parameter, an output parameter, or both. In the simplest case, the writing of a user subroutine might consist of computing the output parameter(s) from the input parameter(s) as in the MD_STR_USER_1 example in How to Invoke User Subroutines. If the user subroutine requires the use of other variables that are not formal parameters then we must obtain them in some other manner. If a variable is global in nature (for example, cycle number, material data, time) this information is obtained through the USE statement, referencing the appropriate Autodyn module. If the desired variable is associated with a Part (for example, cell pressures, velocities, and so on), these are obtained most readily by using Autodyn supplied functions to retrieve Part data.

Release 18.2 - © ANSYS, Inc. All rights reserved.