Math Commands: Difference between revisions
m (explan) |
|||
Line 1: | Line 1: | ||
<u>All</u> of these commands work with and / or return a generic type [[Number]]. | |||
In scripting language (unlike config's) there is no specialty types such as float or integer. All numeric values are represented solely as a [[Number]] type. | |||
'''However''', specific commands listed below 'expect' specific types of value. Eg [[Number#Radians|Radians]], [[Number#Degrees|Degrees]], and floats. | |||
Be aware that although not directly related to the list below '''many''' commands in the scripting language restrict the range of possible values. Particularly commands wanting ratio's between 0.0 and 1.0 (eg no integer > 1 is possible). Check individual documentation for the command itself) | |||
Also, the [[Boolean]] is a true type in command syntax. The results (the return value) of the below list should not be used directly in a boolean type expression | |||
a=abs -3 | |||
? (a) : exit | |||
bad | |||
? (a>0): exit | |||
good | |||
*[[abs]] | *[[abs]] |
Revision as of 04:48, 5 September 2007
All of these commands work with and / or return a generic type Number.
In scripting language (unlike config's) there is no specialty types such as float or integer. All numeric values are represented solely as a Number type.
However, specific commands listed below 'expect' specific types of value. Eg Radians, Degrees, and floats.
Be aware that although not directly related to the list below many commands in the scripting language restrict the range of possible values. Particularly commands wanting ratio's between 0.0 and 1.0 (eg no integer > 1 is possible). Check individual documentation for the command itself)
Also, the Boolean is a true type in command syntax. The results (the return value) of the below list should not be used directly in a boolean type expression
a=abs -3 ? (a) : exit
bad
? (a>0): exit
good
- abs
- acos
- asin
- atan
- atan2
- atg
- ceil
- cos
- deg
- exp
- floor
- ln
- log
- min
- max
- mod
- pi
- rad
- random
- round
- sin
- sqrt
- tan