Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Plotting x^(2/3), etc

1 view
Skip to first unread message

John Fouhy

unread,
Sep 9, 1997, 3:00:00 AM9/9/97
to

The graph of y = x^(2/3) has a more/less parabolic shape.

However, my HP48 (and a friend's Casio graphical calculator also) is only
capable of graphing the right hand side (ie: x >= 0).

(quick test: -1^(2/3) = 1 )

My teacher mumbled something about calculators working it out using logs,
but didn't elaborate. ('sides, the HP can log a -ve..?)

Is there any 'quick fix'? Alternately, are there any plotting programs out
there that will handle it?
(and does the dreaded arch-enemy, the TI-92, handle it properly? :-)
(don't seem to get TI-92s in New Zealand..))

nb: Please cc. any replies to jfo...@actrix.gen.nz - my newsfeed is very
shaky at the moment (I'll count it a victory if this post is ever seen
outside New Zealand).
--
"Come, let us hasten to a higher plane, | John Fouhy, Wgtn, New Zealand
Where dyads tread the fairy fields of Venn, | e-mail: jfo...@actrix.gen.nz
Their indices bedecked from 1 to n, | The Turtle Moves! <*> (tinc)
Commingled in an endless Markov chain!" --- Stanislaw Lem, _Cyberiad_

Bernd Grubert

unread,
Sep 9, 1997, 3:00:00 AM9/9/97
to


----------
> Von: John Fouhy <jfo...@atlantis.actrix.gen.nz>
> Newsgroups: comp.sys.hp48
> Betreff: Plotting x^(2/3), etc
> Datum: Dienstag, 9. September 1997 09:34


>
> The graph of y = x^(2/3) has a more/less parabolic shape.
>
> However, my HP48 (and a friend's Casio graphical calculator also) is only
> capable of graphing the right hand side (ie: x >= 0).
>
> (quick test: -1^(2/3) = 1 )
>
> My teacher mumbled something about calculators working it out using logs,
> but didn't elaborate. ('sides, the HP can log a -ve..?)
>
> Is there any 'quick fix'? Alternately, are there any plotting programs out
> there that will handle it?
> (and does the dreaded arch-enemy, the TI-92, handle it properly? :-)
> (don't seem to get TI-92s in New Zealand..))

Try 'XROOT(3,x^2)' or '(x^2)^(1/3)'.
These expressions just change the order of the application of the powers.
Hope this helps.

Greetings Bernd.


Steve Lineberry

unread,
Sep 9, 1997, 3:00:00 AM9/9/97
to John Fouhy

John Fouhy wrote:
>
> The graph of y = x^(2/3) has a more/less parabolic shape.
>
> However, my HP48 (and a friend's Casio graphical calculator also) is only
> capable of graphing the right hand side (ie: x >= 0).
>
> (quick test: -1^(2/3) = 1 )
>
> My teacher mumbled something about calculators working it out using logs,
> but didn't elaborate. ('sides, the HP can log a -ve..?)
>
> Is there any 'quick fix'? Alternately, are there any plotting programs out
> there that will handle it?
> (and does the dreaded arch-enemy, the TI-92, handle it properly? :-)
> (don't seem to get TI-92s in New Zealand..))
>
> nb: Please cc. any replies to jfo...@actrix.gen.nz - my newsfeed is very
> shaky at the moment (I'll count it a victory if this post is ever seen
> outside New Zealand).
> --
> "Come, let us hasten to a higher plane, | John Fouhy, Wgtn, New Zealand
> Where dyads tread the fairy fields of Venn, | e-mail: jfo...@actrix.gen.nz
> Their indices bedecked from 1 to n, | The Turtle Moves! <*> (tinc)
> Commingled in an endless Markov chain!" --- Stanislaw Lem, _Cyberiad_
Have you tried doing two graphs. A plus and a minus. When something is
raised to the 2/3 power that is it squared then cube rooted. When you
square something it will always turn positive so you have to do plus or
minus. As with the log thing your teacher meant Natural Log. The HP
probably graphs EXP(2/3*Ln(X)). When X < 0 Ln(X) returns imaginary so
the graph would not show up with X < 0.
--
Steve

Dave Arnett

unread,
Sep 9, 1997, 3:00:00 AM9/9/97
to John Fouhy

Replying by e-mail and by post to comp.sys.hp48


John Fouhy wrote:
>
> The graph of y = x^(2/3) has a more/less parabolic shape.
>
> However, my HP48 (and a friend's Casio graphical calculator also) is only
> capable of graphing the right hand side (ie: x >= 0).
>
> (quick test: -1^(2/3) = 1 )

There are three equally-correct answers, and two are complex numbers:
1
-0.5,0.866025...
-0.5,-0.866025...

For various reasons, the HP will return the second answer rather than
the first.

In fact, for any non-zero value of x, x^(2/3) has three answers, and all
of them lie on a parabaloid. For x>0, the HP returns a result which
happens to be real. Remember that all three answers ARE equally valid.


<snip>


>
> Is there any 'quick fix'? Alternately, are there any plotting programs out
> there that will handle it?

The fact you have run across is that the HP48 in normal graphing mode
wants to plot a pair of real-valued numbers. When x>0, the plot routine
has a real-vauled result, which can be plotted. For x<0, the plot gets
a complex number, which it cannot plot.

One quick fix is to modify the equation you are trying to plot, so that
its result is always real, such as

y = ABS(x^(2/3))

I think this will give you a result more to your liking.

Best of success!
Dave.
-----
I don't speak for HP when I post here.

WaltSHARK

unread,
Sep 9, 1997, 3:00:00 AM9/9/97
to

>Is there any 'quick fix'? Alternately, are there any plotting programs out
>there that will handle it?
>(and does the dreaded arch-enemy, the TI-92, handle it properly? :-)
>(don't seem to get TI-92s in New Zealand..))

I don't know about the TI-92 for sure, but the earlier TI's do indeed
handle this properly. My roommate (a high school math teacher) pointed
this very problem to me a few months ago. We were both shocked that a TI
could do something better than the '48!

Sharkey

John H Meyers

unread,
Sep 12, 1997, 3:00:00 AM9/12/97
to

In article <3414f...@news.actrix.gen.nz>,
jfo...@actrix.gen.nz (John Fouhy) writes:

> The graph of y = x^(2/3) has a more/less parabolic shape.

Less. The derivative has a discontinuity at (0,0), and the
graph looks more like a "tornado" or "funnel cloud."

> However, my HP48 (and a friend's Casio graphical calculator also)
> is only capable of graphing the right hand side (ie: x >= 0).

> My teacher mumbled something about calculators working it out
> using logs, but didn't elaborate.

Ah, that "mumbling technique" taught at the better teachers' colleges,
used to deflect students' excessive desire to understand things :)

This whole thread also has the typical Usenet "look and feel" :)

If you entered the equation as 'Y=X^(2/3)' or just 'X^(2/3)'
then the fact that (2/3) is in parentheses forces (2/3) to
be calculated first (resulting in .666666666667) before the
exponentiation is attempted; if you express the formula
in a different manner, say '(X^2)^(1/3)' then the results
will be what you want, on any calculator, and you can
forget about all the following explanations of why the expression
'X^(2/3)' gives the hiccups to various calculators.

On calculators not having a "complex mode," evaluating 'X^(2/3)'
for negative arguments will generally produce an error, which will
generally omit plotting anything for negative arguments. The
cause of the error is that a^b is calculated as exp(b*ln(a))
or as 10^(b*log(a)) [Casio seems to like the latter idea].

When (a) is negative and (b) is not an integer, most calculators
cry foul at this point [except Casio's, which sometimes check
whether 1/b is nearly an integer, and if so revert to computing
a[root](1/b) instead, thus (-1)^(2/3) errors on my Casio,
while (-1)^(1/3) does not!]. A number of calculators, including Casio
and most HP's not having complex mode, make a special exception for
integer exponents/roots of negative arguments, and attach the
negative sign to the final answer (for odd powers/roots),
instead of to the argument (even powers are always positive,
of course, but even roots of negative arguments still error).

On the HP48, "complex mode" is always in effect; as Dave Arnett
points out, the HP48 returns the answer for negative arguments
raised to the .666666666667 power, still using the exp(b*ln(a)) formula,
by using the "principal value" of each intermediate result in turn,
which finally ends up with a complex answer at 120 degrees, even
though there exists another possible answer at about zero degrees,
which you might have hoped to be the "principal value" for the final
result, but isn't. After all this fussing, however, a non-real answer
still produces no plot point, just as with most other calculators.

Bernd Grubert suggested using either XROOT (taking the real cube root
first, avoiding complex results) or (X^2)^(1/3); the latter is available
on all graphing calculators, and overcomes all problems.

This is an excellent demonstration of why blind use of formulas
does not replace thinking, which some people even extrapolate to
why blind application to the letter of policy or law does not
replace experience, judgment, or wisdom.

-----------------------------------------------------------
With best wishes from: John H Meyers <jhme...@mum.edu>

0 new messages