An equation is a mathematical expression with an equals sign in it.
Other possible elements of an equation are:
- numbers
- variables
- binary operators (+, -, * or ÷)
- unary operators (+ or -)
- brackets
- powers (xy)
- functions (sin(),log() , etc.)
These are explained below:
numbers
There are different types of numbers, for instance:
- Integers - whole numbers
- Reals - (I may sometimes use the term scalars which strictly should be used when a real number is scaling a vector) - numbers which may have decimal point and/or exponent. In computers reals are stored using floating point values.
- Complex Numbers - numbers with real and imaginary parts.
- Matrices - arrays of numbers.
and these numbers may be coded in different ways:
- binary
- octal
- decimal
- hexadecimal
Unless otherwise specified we usually assume that numbers are decimal.
variables
Sometimes an equation contains a number but we don't yet know its value, or we may want to apply the equation to a range of values.
An example of the first is using x as the unknown, for example,
x + 1 = 3
An example of the second might be an equation of a line:
y = 2 * x + 3
In general we use:
x, y, z for unknowns.
a, b, c for values which are not yet specified.
binary operators
The operators:
- + add
- - subtract
- * multiply (was x but for computers has to be changed to distinguish it from 24th letter of the alphabet)
- ÷ or / divide
take the two numbers on either side and replace it by a single number.
Addition
In the following plot the height is given by a+b, this gives a flat plane at 45° to both a and b:

Of course the plane is infinite in all directions but here we have only shown a section of the plane.
Multiplication
In the following plot the height is given by a*b, this gives a surface made up of straight lines along a or b directions (bi-linear). If we take a direction at 45° to both a and b then we get a parabola.

unary operators
The operators:
- + plus
- - minus
apply to the number to the right. '-' inverts the number (subtracts from 0) '+' says the number to the right is positive (the default).
brackets
When we mix + and * then the answer we get depends on the order that we apply them.
For example
2 + 1 * 3
To clarify this we can put brackets around the operation to be applied first:
(2 + 1) * 3 = 9
2 + (1 * 3) = 5
If we don't specify which has precedence by using bracket then by default * and ÷ have precedence over + and -. So,
2 + 1 * 3 = 5
functions
A function takes one number and uses it to generate another number. For example the function sin() takes an angle as input and returns the ratio of opposite and hypotenuse in a right angled triangle.





