Document 249

Real outcome for cube root

Version: 3.0 - Scientific WorkPlace & Scientific Notebook

Problem

In SWP 3.0, if you enter Math: cube root of -100 and then choose Evaluate Numerically from the Maple menu, the value that is returned is an imaginary number instead of a real number.

Solution

The Maple function that is most appropriate here is the surd command. To access and use the function, follow these instructions:

  1. From the Maple menu, choose Define and then choose Define Maple Name.

  2. In the Maple name box, enter surd(x,n).

  3. In the Scientific WorkPlace name box, enter s(x,n).

  4. Choose OK.

    You have now defined a function with two parameters. The first is the radicand of the expression and the second is the radix.

  5. Test that you can properly access the command:

    1. From the Insert menu, choose Math, or click the Math/Text button.

    2. Enter s(8,3).

    3. From the Maple menu, choose Evaluate.

      If you get an answer of 2, you have properly accessed the surd command through the Maple library.

  6. Make sure you're in mathematics (the Math/Text button appears as M).

  7. Enter s(-100,3).

  8. From the Maple menu, choose Evaluate Numerically.

    The system should return -4.64... as the answer.

Revised 05/03/02

This document was created with Scientific WorkPlace.