Sub topic 9
Negative Numbers and Exponents: `-3^2` versus `(-3)^2`
Assume you can work with positive and negative integers, understand multiplication, and know that an exponent shows repeated multiplication. This chapter focuses on how a minus sign interacts with an exponent.
The key distinction
In standard order of operations, exponents are evaluated before a leading minus sign. The expression -3^2 therefore means:
\[ -(3^2) = -9 \]
The exponent applies to 3, not to the minus sign.
Parentheses change the base. In (-3)^2, the entire number -3 is raised to the power of 2:
\[ (-3)^2 = (-3)(-3) = 9 \]
The two expressions look similar, but they have different values.
| Expression | What is squared? | Value |
|---|---|---|
| `-3^2` | `3`, then apply the minus sign | `-9` |
| `(-3)^2` | the whole number `-3` | `9` |
| `-3^3` | `3`, then apply the minus sign | `-27` |
| `(-3)^3` | the whole number `-3` | `-27` |
Why odd and even powers behave differently
A negative number multiplied by itself an even number of times gives a positive result. An odd number of factors leaves one negative sign:
\[ (-a)^2 = a^2 \]
\[ (-a)^3 = -a^3 \]
For example:
\[ (-2)^4 = 16 \]
because four negative factors produce a positive result. However:
\[ (-2)^5 = -32 \]
because five negative factors produce a negative result.
The parentheses are essential when the negative number is intended to be the base.
print(-3 ** 2) # -9
print((-3) ** 2) # 9
print(-3 ** 3) # -27
print((-3) ** 3) # -27Python follows the same convention used in standard algebra: exponentiation happens before a leading minus sign.
A reliable evaluation method
For an expression containing a negative number and an exponent:
- Look for parentheses around the negative number.
- Identify the exact base of the exponent.
- Evaluate the exponent.
- Apply any remaining leading minus sign.
- Continue with multiplication, division, addition, or subtraction.
Consider:
\[ -2^3 + (-2)^2 \]
First evaluate -2^3:
\[ -(2^3) = -8 \]
Then evaluate (-2)^2:
\[ (-2)(-2) = 4 \]
Finally add:
\[ -8 + 4 = -4 \]
A common mistake is to treat every minus sign beside a number as part of the base. The notation determines the meaning. Parentheses make the intended grouping explicit.
Exercise
Evaluate -4^2 + (-4)^2.
Show answer
-16 + 16 = 0. In -4^2, the exponent applies to 4; in (-4)^2, the whole negative number is squared.