Deep Learning · TEE · section

Negative numbers are direction

Mathematics revision

1. The minus sign can describe a number

Zero is the reference point. Positive numbers such as 1, 2 and 3 lie to its right on a number line. Negative numbers such as −1, −2 and −3 lie to its left. The number −3 is three units below zero; it is not an instruction to subtract until another number is supplied.

Read left as smaller and right as larger. Follow one signed movement at a time. Tap the diagram to enlarge.

In 5 − 2, the minus sign is an operation: subtract 2 from 5. In 5 + (−2), the sign inside the brackets belongs to the number negative 2. Both expressions finish at 3. Brackets keep the signed number together.

2. Adding a negative moves left

Start at 5. Adding positive 2 moves two places right, to 7. Adding negative 2 moves two places left, to 3.

\begin{aligned}5+2&=7\\5+(-2)&=3\end{aligned}LaTeX: \begin{aligned}5+2&=7\\5+(-2)&=3\end{aligned}

If both numbers are negative, keep moving left. Start at −3 and add −2: the answer is −5.

(-3)+(-2)=-5LaTeX: (-3)+(-2)=-5

3. Subtracting reverses that movement

Subtracting positive 2 moves left. Subtracting negative 2 reverses a leftward movement, so it moves right. A money example is removing a debt of 2: your balance increases by 2.

5-(-2)=5+2=7LaTeX: 5-(-2)=5+2=7

The shortcut “two negatives make a positive” is not a rule for every calculation. Negative 3 plus negative 2 is still −5. First identify the operation: addition, subtraction, multiplication or division.

4. Multiplication has its own sign rule

For multiplication and division, equal signs give a positive result and different signs give a negative result. Calculate the ordinary size, then attach the correct sign.

Signs being multipliedComplete calculationResult sign
Positive × positive3 × 2 = 6Positive
Negative × positive(−3) × 2 = −6Negative
Positive × negative3 × (−2) = −6Negative
Negative × negative(−3) × (−2) = 6Positive

Division uses the same sign pattern: (−6) ÷ 2 = −3 and (−6) ÷ (−2) = 3. The divisor must be nonzero.

5. Fully worked arithmetic

Question. Calculate −3 + 2, −3 − 2 and −3 − (−2).

Answer — step by step.

Given

Expressions: −3+2; −3−2; −3−(−2).

To find

Evaluate the three signed-number expressions.

Formula — which one and why

Order of operations. Grouping decides which operation is performed first. Evaluate brackets, then powers, then multiplication/division, then addition/subtraction.

A minus sign inside brackets belongs to that number. Subtracting a negative changes the operation to addition.

a-(-b)=a+bLaTeX: a-(-b)=a+b

Yaad rakhne ka cue: Bracket pehle; phir power; phir multiply/divide; aakhir mein plus-minus.

Solution — step by step

Step 1: evaluate the first expression. start at −3 and move two places right. The answer is −1.

-3+2=-1LaTeX: -3+2=-1

Step 2: evaluate the second expression. start at −3 and move two places left. The answer is −5.

-3-2=-5LaTeX: -3-2=-5

Step 3: evaluate the third expression. replace subtract-negative-2 with add-positive-2. The answer is −1.

\begin{aligned}-3-(-2)&=-3+2\\&=-1\end{aligned}LaTeX: \begin{aligned}-3-(-2)&=-3+2\\&=-1\end{aligned}

Later, a weight update subtracts a correction that can itself be negative. The third expression explains exactly why that update can increase a weight.