Evaluating
expressions that have variables in them.
So far, we've
looked at expressions that have numbers, mathematical actions like addition and
subtraction and mathematical relationships like equals in them. However,
mathematical expressions can also have variable names in them, as we've seen in
the precipitation scenario from section 3.10. Consider the following equation:
3 + 4 =
MyNumber
In this case,
MyNumber is a variable name.
Let's take a
moment to fully understand what is happening in this expression.
First of all,
let's consider the variable name MyNumber. Remember from section 3.4 that a
variable name is the name you give to an object. Sometimes, when you supply the
variable name, you aren't sure exactly which object you are talking about, but
you do at least know something about the object. For example, you don't know
which exact fish is TheFishThatGotAway, but you know it was a fish. Remember
also, from section 3.11 that sometimes the actual object associated with the
variable name might change from time to time. Sometimes TheCandyInMyHand was a
jellybean, and sometimes it was a gummy bear.
In this case,
we don't know too much about MyNumber. All we really know at the moment is that
it's in a mathematical expression, so the variable name MyNumber is going to be
naming a mathematical object of some kind. Also, since it wouldn't make much
sense if it was naming a circle or a line, we can conclude that it is naming a
number.
What else is
in the expression? Since there's an equal sign, we know that the expression is
an equation, and must evaluate to TRUE or FALSE.
We also know
that there are some numbers and an addition sign, and that we're allowed to
evaluate and replace this part of the expression with the number it evaluates
to (see sections 3.14 for the reason why this is so).
Suppose we do
replace the 3 + 4:
since 3 + 4
evaluates to 7 we can change
3 + 4 =
MyNumber
to
7 = MyNumber.
Now what?
Suppose that I told you the equation was TRUE. Once you knew that, could you do
some reasoning to determine what value MyNumber must have?
Here are some
possible mathematical objects to chose from:
a)

b) 3
c)

d) 7
Which of
these, if named by the variable name MyNumber, makes the equation
7 = MyNumber.
TRUE?
(Answer 1)
Now suppose
that I told you the expression
7 = MyNumber
is FALSE
What number
values can the variable MyNumber name in order to make this equation FALSE?
(Answer 2)
Determining
which value or values can make an equation true is a major activity in
mathematics, and it will be an important activity in your economics course, as
you use mathematical equations to model various situations in economics. In the
next section we'll look at a real world example of modeling a situation
mathematically and determining which values make an equation TRUE.
-----
Answer 1: If
the value of the variable MyNumber is the number 7, then the equation 7 =
MyNumber is true.
Answer 2:
There are many number values the variable MyNumber can name to make the
equation FALSE. It could be 10, 3 or 127. Any of these values will make the
expression 7 = MyNumber FALSE. Can you think of any number value other than 7
that would make this expression TRUE?)