1.7. Include Decks

In addition to the subroutines and functions described in this chapter, most of the include decks (files with the extension .inc) used by Mechanical APDL are on your product distribution medium. The include decks, also called commons, contain important but relatively small amounts of data. The program also handles large amounts of data using various access routines (GET and PUT), described elsewhere in this document.


Note:  When you compile a user-programmable feature (UPF) in a shared library (ANSUSERSHARED.bat), you cannot access the common block variables. (All such variables will return a value of zero.)


To insert include decks in a subroutine or function, use the INCLUDE (or an analogous) statement. Do not modify an include deck under any circumstances. The following table lists some of the more commonly used include files and the definitions they contain:

Include FileDescription
acelcm.inc Contains accelerations and angular velocities
ansysdef.inc Defines general Mechanical APDL parameters. You must include this common to retrieve the parameter values of MEM_INTEGER, MEM_DOUBLE, MEM_COMPLEX, or MEM_REAL.
cmopt.inc Contains optimization variables
echprm.inc Defines parameters for element characteristics
elccmt.inc Defines element characteristics (comments only)
elecom.inc Contains element-specific information
elparm.inc Defines pointers for the element data array
elucom.inc Defines the element degree of freedom pointers
etycom.inc Element type data
impcom.inc Used by all routines and functions in the program
outpcm.inc Defines output control information
soptcm.inc Contains solution options and keys
stack.inc Defines stack storage. You must include this common in any routines that access stack space.
stepcm.inc Contains load step information
usvrcm.inc Defines storage of user-defined variables