incorrect value for slope of Gamma(x) at x=1
|
08-03-2018, 10:09 AM
Post: #1
|
|||
|
|||
incorrect value for slope of Gamma(x) at x=1
Prime app for Android gives (incorrect) NaN for the slope of Gamma(x) at x=1, but valid slope for x=0.99 and x=1.01, etc. Refer to attached screenshots.
The slope of the Gamma function IS defined for at x=1. Refer to http://www.wolframalpha.com/input/?i=slo...D1&x=0&y=0 |
|||
08-03-2018, 02:44 PM
Post: #2
|
|||
|
|||
RE: incorrect value for slope of Gamma(x) at x=1
Try slope(tangent(plotfunc(Gamma(x)),1))
|
|||
08-03-2018, 04:19 PM
Post: #3
|
|||
|
|||
RE: incorrect value for slope of Gamma(x) at x=1
So what is probably going on here is that it is returning the symbolic constant internally in the plotter and it is not a numeric value, hence it reports Not a Number.
We probably need to handle attempting to convert to a numeric value in these few cases. TW Although I work for HP, the views and opinions I post here are my own. |
|||
08-03-2018, 04:25 PM
Post: #4
|
|||
|
|||
RE: incorrect value for slope of Gamma(x) at x=1
(08-03-2018 10:09 AM)pr1268 Wrote: Prime app for Android gives (incorrect) NaN for the slope of Gamma(x) at x=1, but valid slope for x=0.99 and x=1.01, etc. Refer to attached screenshots. Works well on real Prime. Gives 0. Guy R. KOMAN, hp 50G, hp Prime Rev. C |
|||
08-03-2018, 05:45 PM
Post: #5
|
|||
|
|||
RE: incorrect value for slope of Gamma(x) at x=1
(08-03-2018 04:25 PM)Komanguy Wrote:(08-03-2018 10:09 AM)pr1268 Wrote: Prime app for Android gives (incorrect) NaN for the slope of Gamma(x) at x=1, but valid slope for x=0.99 and x=1.01, etc. Refer to attached screenshots. The slope of Gamma(x) at x=1 is NOT 0. It's -0.57721... |
|||
08-03-2018, 05:47 PM
Post: #6
|
|||
|
|||
RE: incorrect value for slope of Gamma(x) at x=1 | |||
08-03-2018, 05:52 PM
(This post was last modified: 08-03-2018 05:54 PM by Dieter.)
Post: #7
|
|||
|
|||
RE: incorrect value for slope of Gamma(x) at x=1
(08-03-2018 04:19 PM)Tim Wessman Wrote: So what is probably going on here is that it is returning the symbolic constant Just to make this clear: The slope \(\Gamma~' (1) \) is –γ, i.e. the negative Euler-Mascheroni constant = –0,5772... Now... (08-03-2018 04:19 PM)Tim Wessman Wrote: ...internally in the plotter and it is not a numeric value, hence it reports Not a Number. ...does this mean that the symbolic result "–γ" is returned to the plotter app which in turn does not convert this into a numeric value and thus returns "NaN"? (08-03-2018 04:19 PM)Tim Wessman Wrote: We probably need to handle attempting to convert to a numeric value in these few cases. Sounds like a good idea. ;-) Dieter |
|||
08-04-2018, 11:48 AM
Post: #8
|
|||
|
|||
RE: incorrect value for slope of Gamma(x) at x=1
(08-03-2018 05:45 PM)pr1268 Wrote:(08-03-2018 04:25 PM)Komanguy Wrote: Works well on real Prime. Gives 0. You’re right but on mine it gives 0, not NaN. It’s weird, results are different here. Guy R. KOMAN, hp 50G, hp Prime Rev. C |
|||
08-04-2018, 01:36 PM
(This post was last modified: 08-04-2018 01:38 PM by DrD.)
Post: #9
|
|||
|
|||
RE: incorrect value for slope of Gamma(x) at x=1 | |||
08-04-2018, 02:05 PM
Post: #10
|
|||
|
|||
RE: incorrect value for slope of Gamma(x) at x=1 | |||
08-04-2018, 05:31 PM
Post: #11
|
|||
|
|||
RE: incorrect value for slope of Gamma(x) at x=1
(08-04-2018 02:05 PM)roadrunner Wrote: In cas, uncheck "change apparent integers into exact integers" and you get the expected result: Oups! I used CAS.Gamma(X) instead of Gamma(X), Slope is always 0. With the Gamma(X), slope is NaN at x=1 when "change apparent integers into exact integers" is checked, and slope is -0.577215..... when this option is unchecked. Thanks a lot. Guy R. KOMAN, hp 50G, hp Prime Rev. C |
|||
08-05-2018, 03:02 AM
Post: #12
|
|||
|
|||
RE: incorrect value for slope of Gamma(x) at x=1
So this pretty much confirms my suspicion regarding the symbolic object being returned. Similar things used to happen with some area calculations till we introduced a way to force numerical evaluation in all cases. The slope command however goes through a different path to handle evaluation. That needs the same type of fix.
TW Although I work for HP, the views and opinions I post here are my own. |
|||
08-05-2018, 11:32 AM
Post: #13
|
|||
|
|||
RE: incorrect value for slope of Gamma(x) at x=1
Not sure if it's related or not, but when (X-1)! is plotted the slope is 0 and tangent line is horizontal at all values of X. That is irrespective of the CAS check box setting.
|
|||
« Next Oldest | Next Newest »
|
User(s) browsing this thread: 1 Guest(s)