next up previous contents index
Next: Deferred Expressions and Random Up: Operands in Expressions Previous: Variable labels   Contents   Index

Element or command attributes

In arithmetic expressions the attributes of physical elements or commands can occur as operands. They are named respectively by

element-name->attribute-name
command-name->attribute-name
If they are arrays, they are denoted by

element-name->attribute-name[index]
command-name->attribute-name[index]
Values are assigned to attributes in element definitions or commands.

Example:


D1:DRIFT,L=1.0;
D2:DRIFT,L=2.0-D1->L;
D1->L refers to the length L of the drift space D1.



MAD User Guide, http://wwwslap.cern.ch/mad/