Activity 7

Mathematica doesn't allow operations on equations as illustrated in the book.

(a == b) - c

(a == b) - c

One can map a function over an equation.  In this case we use the function that subtracts c from anything. That's a bit cumbersome, however.

Map[# - c &, a == b]

a - c == b - c

A somewhat simpler approach is to use Thread:

Thread[c + (a == b), Equal]

a + c == b + c

Thread[-8 x + (5 x - 2 (x - 7) == 8 (x + 2) - 17), Equal]

-2 (x - 7) - 3 x == -8 x + 8 (x + 2) - 17

Simplification by expansion isn't automatic.  We use the percentage sign, %, which represents the previous output to simplify the process.

Simplify[%]

5 (x - 3) == 0

Thread[(1/5) * %, Equal]

x - 3 == 0

Thread[3 + %, Equal]

x == 3

•Alternate Mathematica Versions

Here is an alternative sequence of steps prepared by Sherry Nolan and Christian Djacheci, UMass Lowell.

Step One, simplify each side of the equation using a CAS

ExpandAll[5 x - 2 (x - 7) == 8 (x + 2) - 17]

3 x + 14 == 8 x - 1

Step Two, subtract 8x from both sides and simplify using a CAS ( I was unable to find a way to do this with the CAS in one step).

Simplify[14 + 3 x - 8 x]

14 - 5 x

Simplify[(-1 + 8 x) - 8 x]

-1

So, 14 - 5 x = -1.
Step Three, subtract fourteen from both sides and simplify

Simplify[(14 - 5 x) - 14]

-5 x

Simplify[(-1) - 14]

-15

So, -5 x = -15.
Step Four, use previous sides of equation to solve

Solve[-5 x == -15, x]

{{x -> 3}}

Step Five, Check Answer

(5 x - 2 (x - 7) == 8 (x + 2) - 17 ) /. x -> 3

True

So 5 x - 2 (x - 7) == 8 (x + 2) - 17 when x = 3.

•Comments/Extensions

This entire process can also be done in one step by using one of the following commands:

Solve[5 x - 2 (x - 7) == 8 (x + 2) - 17]

{{x -> 3}}

Reduce[5 x - 2 (x - 7) == 8 (x + 2) - 17]

x == 3

This can also be done skipping some steps by using the following commands:

Simplify[5 x - 2 (x - 7) == 8 (x + 2) - 17]

5 (-3 + x) == 0

Reduce[5 (-3 + x) == 0]

x == 3

This activity was an example of using the CAS to solve for a single variable after simplifying an equation. Many students are able to solve equations once they are put into a form with the single variable on one side and a zero on the other side of the equality. Most of the mistakes that students make come from simplifying the equations and collecting like terms.   This activity was good in that the first step showed how to use a CAS to expand and collect on each side of the equation and check their work, without having the CAS solve the whole equation for them.   The students, once they get this far, can step by step solve for the unknown variable and check their work against the CAS.



Converted by Mathematica  (May 12, 2003)