MathGroup Archive 2001

[Date Index] [Thread Index] [Author Index]

Search the Archive

Re: Problem to evaluate cube root of a negative cube nember where a real value is expected

  • To: mathgroup at smc.vnet.net
  • Subject: [mg28068] Re: Problem to evaluate cube root of a negative cube nember where a real value is expected
  • From: "Allan Hayes" <hay at haystack.demon.co.uk>
  • Date: Fri, 30 Mar 2001 04:12:21 -0500 (EST)
  • References: <99urns$5nv@smc.vnet.net>
  • Sender: owner-wri-mathgroup at wolfram.com

Gary,

There's a standard package:

<<Miscellaneous`RealOnly`

(-8)^(1/3)

-2

--
Allan
---------------------
Allan Hayes
Mathematica Training and Consulting
Leicester UK
www.haystack.demon.co.uk
hay at haystack.demon.co.uk
Voice: +44 (0)116 271 4198
Fax: +44 (0)870 164 0565

"Gary" <garylga at magix.com.sg> wrote in message
news:99urns$5nv at smc.vnet.net...
> Hi,
>
> Does anyone know a simplier way to simplify (-8)^(1/3)=(-2) other than
what
> I did below because no complex answer is expected in the solution.
>
> In[161]:=
> p=(-8)^(1/3)
> q=Abs[p]
> Level[p,3]
> r=Extract[Level[p,3],2]
> (* if p is real, then p should be as below *)
> q*r
>
> Out[161]=
> \!\(2\ \((\(-1\))\)\^\(1/3\)\)
>
> Out[162]=
> 2
>
> Out[163]=
> \!\({2, \(-1\), 1\/3, \((\(-1\))\)\^\(1/3\)}\)
>
> Out[164]=
> -1
>
> Out[165]=
> -2
>
>
> ______________________________________
> Gary Lee Guanan (garylga at magix.com.sg)
> Director - Business Development
> IQExplorers.com Pte Ltd
> Tel 874-1345/6
> ========================C/o Address============================
> Incubation Centre, School of Computing(SoC),  NUS.
> S15 #01-09, 1 Science Drive 2 (along Lower Kent Ridge Road), S117543
> ===============================================================
>
>




  • Prev by Date: Re: How do I add rows to a text table?
  • Next by Date: mathlink compile problem
  • Previous by thread: Re: Problem to evaluate cube root of a negative cube nember where a real value is expected
  • Next by thread: Strange behavior of NSum on 4.0