Error in Computing Undefined
04-02-2017, 09:56 AM
Post: #1
 rsr20 Junior Member Posts: 2 Joined: Sep 2015
Error in Computing Undefined
Hey all, sorry if this has been answered before. I've been searching for a solution on here and Google for over an hour to no avail. My calculator returns a number for what should be an undefined problem. This has happened for others but the specific problem I'm working on currently is:

(When set to Radians) ==> tan(pi/2) = -195,948,537,906
_____--- and --- ________ tan(-pi/2) = 195,948,537,906

(When set to Degrees) ==> tan(90) = Error: /inf result

I would expect the same answer that appears in degrees to appear in the radians setting. I've also noticed that the calculator sometimes returns a very small number when the answer should be zero. This doesn't happen frequently and I haven't noticed a pattern yet, but it's enough of an issue to cause problems when computing engineering problems that require accuracy.

Is this a common problem and is there a fix for it?

Thanks,

-Roscoe
04-02-2017, 02:08 PM
Post: #2
 Joe Horn Senior Member Posts: 1,579 Joined: Dec 2013
RE: Error in Computing Undefined
It's not a bug or even a problem. It's actually the correct answer. Here's why.

In Home view (not CAS), with Standard display mode set, type pi/2 and see what you get. It says 1.5707963268 and it's very important to know that it's EXACTLY 1.5707963268, no more and no less. It's NOT pi/2, but an approximation of pi/2, rounded to 12 significant digits. Therefore, when you key TAN(pi/2), you're REALLY asking for the tangent of 1.5707963268, not the tangent of pi/2. As verified by a computer, TAN(1.5707963268) is -195948537905.97787... which, when rounded to 12 significant digits, is -195948537906, which is precisely what Prime returned.

The reason that TAN(90°) returns infinity is that 90° is an exact value. In Home, pi/2 is not exactly pi/2.

If you want to calculate with the exact value of pi, use CAS instead of Home. You'll notice that tan(pi/2) nicely returns infinity, as expected.

<0|ɸ|0>
-Joe-
04-02-2017, 04:53 PM (This post was last modified: 04-02-2017 05:02 PM by compsystems.)
Post: #3
 compsystems Senior Member Posts: 1,201 Joined: Dec 2013
RE: Error in Computing Undefined
DEG & CAS MODE
TAN(90°); returns +Inf
TAN(90); returns 16331239353200000
eval( TAN(90_deg) ); returns TAN(90_deg)
EVAL( TAN(90_deg) ); returns 60171254653300

/!\ In the following image EVAL and eval cmd is displayed in UPPERCASE, (This generates confusion in the screenshots)

The GRADES symbol is lost on the history, if you copy it to the entry line the response will be another

04-03-2017, 02:06 AM
Post: #4
 rsr20 Junior Member Posts: 2 Joined: Sep 2015
RE: Error in Computing Undefined
OH! I see. That makes sense. Thanks a lot for explaining. It was extremely frustrating for no reason apparently haha.

Regards!

-Roscoe
 « Next Oldest | Next Newest »

User(s) browsing this thread: 1 Guest(s)