Python Forum
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Irrational number
#9
Irrational, not imaginary. My mistake.

You can't check it from a float, because the float has no information if it's a rational or an irrational number.
A float has a finite precision.

If you get the value 3.141592653589793 as only information, no chance to say if it's rational or irrational.
We know that this value is pi and pi is irrational. From where should the computer know this without any context?

Im not very deep in math, but I think you can maybe detect if a result should be irrational or not after a calculation.
Almost dead, but too lazy to die: https://sourceserver.info
All humans together. We don't need politicians!
Reply


Messages In This Thread
Irrational number - by chpyel - May-07-2020, 05:51 PM
RE: Irrational number - by SheeppOSU - May-07-2020, 11:06 PM
RE: Irrational number - by chpyel - May-07-2020, 11:46 PM
RE: Irrational number - by bowlofred - May-07-2020, 11:56 PM
RE: Irrational number - by DeaD_EyE - May-08-2020, 07:57 AM
RE: Irrational number - by ndc85430 - May-08-2020, 09:39 AM
RE: Irrational number - by chpyel - May-08-2020, 10:17 AM
RE: Irrational number - by bowlofred - May-08-2020, 04:27 PM
RE: Irrational number - by pyzyx3qwerty - May-08-2020, 10:22 AM
RE: Irrational number - by DeaD_EyE - May-08-2020, 02:20 PM
RE: Irrational number - by SheeppOSU - May-08-2020, 05:15 PM
RE: Irrational number - by TomToad - May-08-2020, 06:23 PM

Forum Jump:

User Panel Messages

Announcements
Announcement #1 8/1/2020
Announcement #2 8/2/2020
Announcement #3 8/6/2020