There are no absolute rules for writing your own user subroutines. What we will do here is to outline some of the techniques that may be used and the tools that are available to help create user subroutines. If we look at the examples given in User Subroutine Examples, we will see some of the common techniques and tools used to create user subroutines. These include:
Formal parameters passed to and from the user subroutine
Accessing global variables in the Autodyn modules (for example: time, material data, cycle number, and so on)
Accessing Part grid variables (for example: pressure, density, velocity, and so on)
Calling Autodyn utility functions/subroutines
Terminating execution from a user subroutine
We will look at each of these items in more detail.