Module 2 - Computer Algebra
 
  Introduction | Lesson 1 | Lesson 2 | Lesson 3 | Self-Test
 
 Lesson 2.2: Variables
 

In this lesson, you will learn to define and delete variables. It is important to know the difference between a defined and an undefined variable when working with algebraic expressions.


The "New Problem" Command

The Clean Up toolbar menu on the Home screen contains the "New Problem" command, which lets you start a new calculation from a cleared state without resetting the calculator's memory.

  • Go to the Home screen and display the Clean Up menu by pressing
  • Paste the New Prob command into the Edit Line by pressing (or and )
  • Execute the command by pressing

The Home screen is cleared and all expressions and variables with one-letter names are deleted from memory, that is, "New Problem" undefines all one-letter variables.

Defining Variables

When defining a variable that you want to retain beyond the current problem, use more than one character in the name. This prevents it from being deleted inadvertently when you use the "New Problem" command.



Simplifying Expressions

The computer algebra system simplifies the result of an expression that contains undefined variables.

  • Enter the expression 3x + 5x by pressing

The variable x is undefined, so the calculator combines like terms and displays the result of 8x.

The With Command

The "with" command, which is accessed by pressing in the left column of keys, can be used to evaluate an expression for a specific value of a variable without storing the value into the variable permanently.

Evaluate 3x + 5x with x = 2 by using the "with" command.

With the expression 3x + 5x in the Edit line,

  • Modify the entry to evaluate the expression with x = 2 by pressing

The variable x is temporarily defined to be 2 in the expression 3x + 5x but will be undefined in future entries.

Copying from the History Area

When working with complicated expressions and equations, you need only enter the expression once. You can then copy it from the History Area instead of retyping the entry.

To copy the expression 3x + 5x from the History Area and paste it to the Edit Line,

  • Move the cursor up in the History Window and highlight 3x + 5x by pressing repeatedly
  • Paste the expression to the Edit Line by pressing
  • Evaluate the entry shown in the Edit Line by pressing

Notice that the value of the variable x is no longer 2.

Storing a Value into a Variable

Sometimes it will be convenient to define a variable to be a specific value. Define x to be 2 for future calculations by using the key.

  • Store 2 into x by pressing
  • Copy the expression 3x + 5x to the Edit Line by using to highlight it in the History Area again and press

Alternatively, you can use [1:Define] to define x to be 2.

The result was calculated as 3(2) + 5(2) because x is defined to be 2. The value of x will be 2 in all future calculations until a new value is stored in x or until the variable x is undefined.

Undefining a Variable

You can delete the value stored in a variable by using the DelVar command, which is found in the F4 menu of the Home screen. This command undefines a variable.

  • Paste DelVar into the Edit Line by pressing
  • Undefine the variable x by pressing

Now x is undefined and contains no value.

Evaluate 3x + 5x again to see that the result is 8x.

The variable x would also become undefined if the NewProb command was used.

2.2.1 Evaluate the expression 2x2 – 3x with x = 5b. Click here for the answer.


< Back | Next >
  ©Copyright 2007 All rights reserved. | Trademarks | Privacy Policy | Link Policy