third root of -8...

Post here to share useful tips and tricks, to ask questions about using your DM42 or to report software-related problems
mcc
Posts: 277
Joined: Fri Jun 23, 2017 5:10 am

third root of -8...

Post by mcc »

Hi,

All credits goes to Scott Collins - he found this. See his video
https://www.youtube.com/watch?v=iNR7kcA08As

In short:

-2 * -2 * -2 = -8

On many calculators cuberoot( -8 ) gives -2...as above.

On the DM42 with CRES enabled this gives:
1.0 + i1.73205...
which is one correct answer.

But with RRES enabled, the cuberoot( -8 ) gives
"Invalid data" (therefore: an error),

which is ... not exactly correct.

What do you think?

Too nerdy or fixable...?

Cheers!
mcc
DM 42 - SN: 00373, Firmware release v.:3.22. / DMCP 3.24. as compiled by SwissMicros
Thomas Okken
Posts: 1101
Joined: Tue May 02, 2017 5:48 pm
Location: Netherlands
Contact:

Re: third root of -8...

Post by Thomas Okken »

mcc wrote:
Sat Jan 30, 2021 4:59 pm
But with RRES enabled, the cuberoot( -8 ) gives
"Invalid data" (therefore: an error),

which is ... not exactly correct.
Unless you found an actual cube root function somewhere on the DM42, what you're actually calculating is -8 to the 1/3 power, and that is not a real number. So Invalid Data, in RRES mode, is "exactly correct."
Peet
Posts: 257
Joined: Tue Sep 29, 2020 12:01 am
Location: Germany

Re: third root of -8...

Post by Peet »

A few days ago the was nearly the same thread (the last one before this thread): viewtopic.php?f=17&t=2806
mcc wrote:
Sat Jan 30, 2021 4:59 pm
Too nerdy or fixable...?
It's a programmable calculator :mrgreen:
My programmable calculators - former: CBM PR100, HP41CV, HP28S, HP11C - current: HP48G(256kB), HP35S, Prime, DM41X, DM42
User avatar
Calambres
Posts: 48
Joined: Wed Dec 16, 2020 6:49 pm
Location: Madrid, Spain
Contact:

Re: third root of -8...

Post by Calambres »

Most calculators will give -2 as a result for -8^1/3...

I'm new to the DM42 (and Free42 for that matter) but I still think that with RRES enabled, "Invalid data" is a wrong answer or, at least, misleading.

Please correct me if I'm wrong.
Thomas Okken
Posts: 1101
Joined: Tue May 02, 2017 5:48 pm
Location: Netherlands
Contact:

Re: third root of -8...

Post by Thomas Okken »

Calambres wrote:
Sun Jan 31, 2021 10:14 am
Most calculators will give -2 as a result for -8^1/3...

I'm new to the DM42 (and Free42 for that matter) but I still think that with RRES enabled, "Invalid data" is a wrong answer or, at least, misleading.

Please correct me if I'm wrong.
Y to the power 1/X is not the same as the X-th root of Y.

-8^(1/3) = e^(ln(-8)/3) = 1+i√3. That is not a real number, and therefore Invalid Data is the correct result in RRES mode.

It's not the calculator that is wrong here, but your understanding of mathematics.
User avatar
Calambres
Posts: 48
Joined: Wed Dec 16, 2020 6:49 pm
Location: Madrid, Spain
Contact:

Re: third root of -8...

Post by Calambres »

I stand corrected...

...now I wonder why most other calculators show -8^(1/3) = -2
Peet
Posts: 257
Joined: Tue Sep 29, 2020 12:01 am
Location: Germany

Re: third root of -8...

Post by Peet »

Calambres wrote:
Sun Jan 31, 2021 1:17 pm
...now I wonder why most other calculators show -8^(1/3) = -2
One can speculate that it was a philosophical decision by the developers, but I fear it is due to the technical implementation of the routines.
I prefer the results from the 42 because I prefer warnings to half-knowledge. If I see the danger of getting complex results in real algebra, then I deal with the sign at the end of the calculation.
My programmable calculators - former: CBM PR100, HP41CV, HP28S, HP11C - current: HP48G(256kB), HP35S, Prime, DM41X, DM42
User avatar
ManuMa
Posts: 24
Joined: Sun Mar 15, 2020 10:14 pm
Contact:

Re: third root of -8...

Post by ManuMa »

Thomas Okken wrote:
Sun Jan 31, 2021 11:41 am
...
-8^(1/3) = e^(ln(-8)/3) = 1+i√3. ...
Hi Thomas,
I think a number fell out of your equation, as:
-8^(1/3) = e^(ln(-8)/3)) = 2e^(i pi/3) = 1+1.7321i

Regards,
Manuel.
Thomas Okken
Posts: 1101
Joined: Tue May 02, 2017 5:48 pm
Location: Netherlands
Contact:

Re: third root of -8...

Post by Thomas Okken »

ManuMa wrote:
Sun Jan 31, 2021 7:19 pm
Thomas Okken wrote:
Sun Jan 31, 2021 11:41 am
...
-8^(1/3) = e^(ln(-8)/3) = 1+i√3. ...
Hi Thomas,
I think a number fell out of your equation, as:
-8^(1/3) = e^(ln(-8)/3)) = 2e^(i pi/3) = 1+1.7321i

Regards,
Manuel.
Nothing fell out. What I wrote is correct.
User avatar
ManuMa
Posts: 24
Joined: Sun Mar 15, 2020 10:14 pm
Contact:

Re: third root of -8...

Post by ManuMa »

Hi Thomas,
Sorry, but in my monitor, the square root symbol appears almost exactly the same as the division one, and that confused me. In fact I had to apply a very big zoom before realizing that you in fact wrote 1+i sqrt(3), and not 1+i/3, as I first read.
Captura.JPG
Captura.JPG (11.13 KiB) Viewed 2882 times
Sorry again.
Regards,
Manuel.
Post Reply