Documentation

The Basics

ScratchCalc is a macOS calculator designed to allow you to experiment with your computations. It acheives this by assigning your results unique names (which you can specify) and can be used in following equations. If you update the named result all the following computations are also updated.

The calculator also aids you by rendering the equations visually. This not only helps you catch mistakes, it also allows you to see the relationships in your expressions that are driving your results.

The full version of the app (which you can unlock via an in app purchase) enables you to have multiple worksheets. You can switch between these with a simple dropdown menu. So you can keep track of useful computations you've done in the past and update them to fit your current situation.

App Settings

Clicking the button brings up the application settings dialog which looks like this:



You may enable, disable or modify the application shortcut here which allows you to launch the app via a simple key combination on your keyboard (this assumes the app is already running in the background). The default is set to Command-Control-M.

You may also elect to launch the application when you log into your computer from this menu by selecting that checkbox and then applying the change.

Selecting Quit Application then applying will immediatly terminate the application.

Worksheet Settings

Clicking the button brings up the worksheet settings dialog which looks like this:

This dialog lets you enter settings for the specific worksheet you are currently working on, like whether angles are represented as radians or degrees, the worksheet name, and the number of decimal places to display in yhe results.

Other Top Row Functions

Some of the other top row buttons have the following functions:

Allows you to switch between your worksheets (full version required to make use of this function).

Allows you to add new worksheets (full version feature). You are given the choice to copy all the current worksheets inputs or to start with a blank worksheet.

Allows you to print and export PDFs (full version feature).

Allows you to either delete or clear the currently opened worksheet (you may never delete the Default worksheet.)

Entering and Updating Equations

Adding a new equation to your worksheet can be easily accomplished using the bottom toolbar of the ScratchCalc window. Just type in your equation into the equation field, optionally enter a name for the result of the equation and press enter (or click the plus button).

  • New equation field.
  • Result name field (optional).
  • Add equation button (or just press return).


Clicking a cell allows you to edit the equation and result name for that cell.


The format with which you enter equations is simular to the way you enter equations in other applications such as macOS spotlight, most programming languages (python, c, etc..), or wolfram alpha on the internet. Basically just type out the equation in the manner that seems natural. Use brackets ( and ) to group things together. Some examples:

3 + 2/3 is equivalent to

(3 + 2)/3 is equivalent to

(2 + (6 - 3)^2/2)/2 is equivalent to

SratchCalc also supports many built in functions for doing trigonometry and other standard math operations. Here are a few examples:

sin(pi/2) is equivalent to

tan((2 + (6 - 3)^2/2)/2 * pi) is equivalent to

sqrt(3 - 2/floor(4 - 3/2)) is equivalent to

Sometimes you may encounter numbers that are either very large or very small. For instance the speed of light is approximattly 300000000 meters per second. It would be tedious to type this out every time. A quicker way of representing this number is to type it as 3e8 which translates to 3*10^8.

ScratchCalc will render the equation to show you how it interpreted what you typed, so feel free to experiment. See the sections bellow for a full list supported constants, operators, and functions.

Equation Details

The following tables list some more details about the kinds of expressions you can enter into an equation.

Predefined Constants

Symbol Usage Description
π pi The ratio of a circles circumference to its diameter.
e e The limit of (1 + 1/n)n as n goes to infinity.

Operators

Operator Usage Description
+ 2 + 3 Addition
- 3 - 2 Subtraction
* 3 * 2 Multiplication
/ 2 / 3 Division
-x 2 - -3 Negative
^ 3^2 Power (xy)
! 3! Factorial (3! is equal to 3 * 2 * 1)
% 3%2 Modulus (The remainder when you divide the left expression with the right expression)

Functions

Function Usage Description
sqrt(x) sqrt(2) Square Root
sin(Θ) sin(pi) Sine
cos(Θ) cos(pi) Cosine
tan(Θ) tan(pi/4) Tangent
cot(Θ) cot(pi/4) Cotangent
sec(Θ) sec(pi/4) Secant
csc(Θ) csc(pi/4) Cosecant
atan(x), arctan(x) atan(3/4) Arc Tangent
asin(x), arcsin(x) asin(2/3) Arc Sine
acos(x), arccos(x) acos(5/6) Arc Cosine
exp(x) exp(1) Exponential
ln(x) ln(e) Natural Log (log base e)
log(x),
log10(x)
log(100) Log base 10
log(x, y) log(8,2) Log base y
abs(x) abs(-2) absolute value
atan2(x, y), arctan2(x, y) atan2(2, 3) Simular to atan(y/x).
min(x, y) min(10,2) Minimum of the 2 values.
max(x, y) max(10, 2) Maximum of the 2 values.
tanh(x) tanh(1) Hyperbolic Tangent
sinh(x) sinh(1) Hyperbolic Sine
cosh(x) cosh(1) Hyperbolic Cosine
atanh(x), arctanh(x) cosh(1) Hyperbolic Arc Tangent
asinh(x), arcsinh(x) cosh(1) Hyperbolic Arc Sine
acosh(x), arccosh(x) acosh(1) Hyperbolic Arc Cosine
round(x),
rnd(x)
round(1.5) Round to the nearest whole number.
floor(x) floor(1.8) Round down.
ceil(x),
ceiling(x)
ceil(1.2) Round up.
sign(x),
sgn(x)
sign(1.2) 1 when x is greater than 0, -1 when x is less than 1, and 0 otherwise.