ZetoPad includes a powerful calculator that evaluates mathematical expressions inline.
Opening the Calculator Panel
- Press
Cmd+Shift+C or
- Click the calculator icon in the toolbar
- Or use Command Palette: “Toggle Calculator”
Inline Evaluation
The calculator evaluates expressions as you type in your snippets:
Supported Operations
Basic Arithmetic
| Operator | Example | Result |
|---|
+ | 5 + 3 | 8 |
- | 10 - 4 | 6 |
* | 6 * 7 | 42 |
/ | 20 / 4 | 5 |
% | 17 % 5 | 2 |
^ or ** | 2^10 | 1024 |
Mathematical Functions
| Function | Example | Result |
|---|
sqrt(x) | sqrt(16) | 4 |
abs(x) | abs(-5) | 5 |
round(x) | round(3.7) | 4 |
floor(x) | floor(3.9) | 3 |
ceil(x) | ceil(3.1) | 4 |
log(x) | log(100) | 2 |
ln(x) | ln(e) | 1 |
exp(x) | exp(1) | 2.718... |
Trigonometry
| Function | Description |
|---|
sin(x) | Sine (radians) |
cos(x) | Cosine (radians) |
tan(x) | Tangent (radians) |
asin(x) | Inverse sine |
acos(x) | Inverse cosine |
atan(x) | Inverse tangent |
Constants
| Constant | Value |
|---|
pi | 3.14159… |
e | 2.71828… |
Practical Examples
Percentage Calculations
500 * 0.2 = 100 # 20% of 500
250 / 0.8 = 312.5 # Number that 250 is 80% of
Unit Conversions
Programming Math
# Array index calculation
(15 * 1024) + 256 = 15616
Tips
- Results update in real-time as you type
- Use parentheses for complex expressions
- Calculator respects your snippet content - results appear as comments
Disabling
Toggle the calculator panel to disable inline evaluation when not needed.