# Table Calculator (Shapes)

V.Olaya (c) 2004, O.Conrad (c) 2011
The table calculator calculates a new attribute from existing attributes based on a mathematical formula. Attributes are addressed by the character 'f' (for 'field') followed by the field number (i.e.: f1, f2, ..., fn) or by the field name in square brackets (e.g.: [Field Name]).
Examples:
sin(f1) * f2 + f3
[Population] / [Area]
The following operators are available for the formula definition:
+ Addition
- Subtraction
* Multiplication
/ Division
^ power
abs(x) - absolute value
sqrt(x) - square root
ln(x) - natural logarithm
log(x) - base 10 logarithm
exp(x) - exponential
sin(x) - sine
cos(x) - cosine
tan(x) - tangent
asin(x) - arcsine
acos(x) - arccosine
atan(x) - arctangent
atan2(x, y) - arctangent of x/y
gt(x, y) - if x>y the result is 1.0, else 0.0
lt(x, y) - if x<y the result is 1.0, else 0.0
eq(x, y) - if x=y the result is 1.0, else 0.0
mod(x, y) - returns the floating point remainder of x/y
ifelse(c, x, y) - if c=1 the result is x, else y
int(x) - integer part of floating point value x
pi() - returns the value of Pi

## Parameters

Formula
Text
Field Name
Text
Shapes
Input Shapes
Result
Output Shapes