<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: Bessel function yn appears only single-precision on IA64 in Operating System - HP-UX</title>
    <link>https://community.hpe.com/t5/operating-system-hp-ux/bessel-function-yn-appears-only-single-precision-on-ia64/m-p/3491267#M639963</link>
    <description>Running the attached program on PA 2.0 and&lt;BR /&gt;IA-64 shows that they both get the same&lt;BR /&gt;internal bit patterns for 0.987265... (so&lt;BR /&gt;it's not a compiler parsing or type&lt;BR /&gt;conversion problem), and the value&lt;BR /&gt;generated by yn() is indeed a different&lt;BR /&gt;bit pattern (so it's not a printf()&lt;BR /&gt;problem).  Curious.&lt;BR /&gt;</description>
    <pubDate>Thu, 24 Feb 2005 16:53:13 GMT</pubDate>
    <dc:creator>Gregory Fruth</dc:creator>
    <dc:date>2005-02-24T16:53:13Z</dc:date>
    <item>
      <title>Bessel function yn appears only single-precision on IA64</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/bessel-function-yn-appears-only-single-precision-on-ia64/m-p/3491260#M639956</link>
      <description>When I call the following Bessel function in a 'c' program on a PA-RISC and then a IA-64 box:&lt;BR /&gt;&lt;BR /&gt;  yn( 2, 0.98726577450859631657 )&lt;BR /&gt;&lt;BR /&gt;I get the following:&lt;BR /&gt;&lt;BR /&gt;  PA-32 =&amp;gt; -1.68339139976380280000&lt;BR /&gt;  IA-64 =&amp;gt; -1.68339139819686622879&lt;BR /&gt;&lt;BR /&gt;which differ starting at the 9th decimal. So is the IA-64 call only running float precision and not double precision?&lt;BR /&gt;&lt;BR /&gt;Thanks.&lt;BR /&gt;&lt;BR /&gt;--&lt;BR /&gt;  Bob</description>
      <pubDate>Tue, 22 Feb 2005 18:53:31 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/bessel-function-yn-appears-only-single-precision-on-ia64/m-p/3491260#M639956</guid>
      <dc:creator>BSSG</dc:creator>
      <dc:date>2005-02-22T18:53:31Z</dc:date>
    </item>
    <item>
      <title>Re: Bessel function yn appears only single-precision on IA64</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/bessel-function-yn-appears-only-single-precision-on-ia64/m-p/3491261#M639957</link>
      <description>The "0000" at the end of the PA-RISC&lt;BR /&gt;seems to indicate that those digits&lt;BR /&gt;are beyond PA's precision.  IA-64&lt;BR /&gt;supports the Intel 80-bit floating type;&lt;BR /&gt;perhaps libm uses it internally.  For&lt;BR /&gt;comparison, running your program on&lt;BR /&gt;IA-32 (Win2k/Cygwin/gcc) gives&lt;BR /&gt;-1.68339139976380280928, which has the same&lt;BR /&gt;# of digits as your IA-64 result but which&lt;BR /&gt;is closer in value to your PA result.&lt;BR /&gt;&lt;BR /&gt;Also, perhaps PHSS_32066 (Math Library&lt;BR /&gt;Cumulative Patch) will help.&lt;BR /&gt;</description>
      <pubDate>Wed, 23 Feb 2005 14:48:24 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/bessel-function-yn-appears-only-single-precision-on-ia64/m-p/3491261#M639957</guid>
      <dc:creator>Gregory Fruth</dc:creator>
      <dc:date>2005-02-23T14:48:24Z</dc:date>
    </item>
    <item>
      <title>Re: Bessel function yn appears only single-precision on IA64</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/bessel-function-yn-appears-only-single-precision-on-ia64/m-p/3491262#M639958</link>
      <description>Okay but I believe they should match out to about the 15th or 16th decimal for double-precision, even if the last digits are trucated or whatever. Based on the response to a ticket I went ahead and opened this morning, I did try applying that patch and I also just tried compiling with the -fpeval=double option, but had the same outcome. Anyway I'll see what they come up with. Thanks.&lt;BR /&gt;</description>
      <pubDate>Wed, 23 Feb 2005 15:08:00 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/bessel-function-yn-appears-only-single-precision-on-ia64/m-p/3491262#M639958</guid>
      <dc:creator>BSSG</dc:creator>
      <dc:date>2005-02-23T15:08:00Z</dc:date>
    </item>
    <item>
      <title>Re: Bessel function yn appears only single-precision on IA64</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/bessel-function-yn-appears-only-single-precision-on-ia64/m-p/3491263#M639959</link>
      <description>One thing I notice immediately is that you are passing in arguments with far more than double-precision granularity and are expecting meaningful results. The yn() function itself may be fine but the problem could be in the string to double conversion in the compiler or in the printf output conversion. In any event, your argument for yn() has too many significant figures unless you are working in quad precision.</description>
      <pubDate>Wed, 23 Feb 2005 15:47:41 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/bessel-function-yn-appears-only-single-precision-on-ia64/m-p/3491263#M639959</guid>
      <dc:creator>A. Clay Stephenson</dc:creator>
      <dc:date>2005-02-23T15:47:41Z</dc:date>
    </item>
    <item>
      <title>Re: Bessel function yn appears only single-precision on IA64</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/bessel-function-yn-appears-only-single-precision-on-ia64/m-p/3491264#M639960</link>
      <description>HP's C manual indicates the input will be converted to the nearest represented value appropriate for the data range. I've done the same type of thing with most of the other math routines between the IA-64 and the PA_RISC and never had a problem. But if that is the case, I'd expect the same conversion on both platforms, so wouldn't the result be the same even if there is a problem with the string to number translation?&lt;BR /&gt;&lt;BR /&gt;--&lt;BR /&gt;  Bob</description>
      <pubDate>Wed, 23 Feb 2005 18:02:52 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/bessel-function-yn-appears-only-single-precision-on-ia64/m-p/3491264#M639960</guid>
      <dc:creator>BSSG</dc:creator>
      <dc:date>2005-02-23T18:02:52Z</dc:date>
    </item>
    <item>
      <title>Re: Bessel function yn appears only single-precision on IA64</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/bessel-function-yn-appears-only-single-precision-on-ia64/m-p/3491265#M639961</link>
      <description>Try a simple test like...&lt;BR /&gt;&lt;BR /&gt;#include &lt;STDIO.H&gt;&lt;BR /&gt;&lt;BR /&gt;int main()&lt;BR /&gt;{&lt;BR /&gt;    double d = 1.2345678910111213141516;&lt;BR /&gt;    float  f = 1.2345678910111213141516;&lt;BR /&gt;&lt;BR /&gt;    printf("%.20f\n", d);&lt;BR /&gt;    printf("%.20f\n", f);&lt;BR /&gt;&lt;BR /&gt;    return(0);&lt;BR /&gt;}&lt;BR /&gt;&lt;BR /&gt;When I run compile (using gcc) and run (PA-RISC 11.11) this, I get&lt;BR /&gt;&lt;BR /&gt;1.23456789101112130000&lt;BR /&gt;1.23456788063049320000&lt;BR /&gt;&lt;BR /&gt;Which indicates I'm getting around 16 digits of precision for double and around 8 for float.&lt;BR /&gt;&lt;/STDIO.H&gt;</description>
      <pubDate>Thu, 24 Feb 2005 04:27:04 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/bessel-function-yn-appears-only-single-precision-on-ia64/m-p/3491265#M639961</guid>
      <dc:creator>Stephen Keane</dc:creator>
      <dc:date>2005-02-24T04:27:04Z</dc:date>
    </item>
    <item>
      <title>Re: Bessel function yn appears only single-precision on IA64</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/bessel-function-yn-appears-only-single-precision-on-ia64/m-p/3491266#M639962</link>
      <description>Yup, so that's why I'm wondering if the IA-64 version of the yn Bessel function is only returning single precision, even though the man page shows it as double precision. (There's also a single precision version listed as ynf.)&lt;BR /&gt;&lt;BR /&gt;BTW, I also get similar problems with the y1 function.&lt;BR /&gt;&lt;BR /&gt;--&lt;BR /&gt;  Bob</description>
      <pubDate>Thu, 24 Feb 2005 11:14:42 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/bessel-function-yn-appears-only-single-precision-on-ia64/m-p/3491266#M639962</guid>
      <dc:creator>BSSG</dc:creator>
      <dc:date>2005-02-24T11:14:42Z</dc:date>
    </item>
    <item>
      <title>Re: Bessel function yn appears only single-precision on IA64</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/bessel-function-yn-appears-only-single-precision-on-ia64/m-p/3491267#M639963</link>
      <description>Running the attached program on PA 2.0 and&lt;BR /&gt;IA-64 shows that they both get the same&lt;BR /&gt;internal bit patterns for 0.987265... (so&lt;BR /&gt;it's not a compiler parsing or type&lt;BR /&gt;conversion problem), and the value&lt;BR /&gt;generated by yn() is indeed a different&lt;BR /&gt;bit pattern (so it's not a printf()&lt;BR /&gt;problem).  Curious.&lt;BR /&gt;</description>
      <pubDate>Thu, 24 Feb 2005 16:53:13 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/bessel-function-yn-appears-only-single-precision-on-ia64/m-p/3491267#M639963</guid>
      <dc:creator>Gregory Fruth</dc:creator>
      <dc:date>2005-02-24T16:53:13Z</dc:date>
    </item>
    <item>
      <title>Re: Bessel function yn appears only single-precision on IA64</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/bessel-function-yn-appears-only-single-precision-on-ia64/m-p/5430707#M639964</link>
      <description>&lt;P&gt;&amp;gt;which differ starting at the 9th decimal. So is the IA-64 call only running float precision and not double precision?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;If it was float, it would differ in the 7th decimal place.&lt;/P&gt;&lt;P&gt;It looks like you found a known problem:&lt;/P&gt;&lt;P&gt;PHSS_33276: s700_800 11.23 Math Library Cumulative Patch&lt;/P&gt;&lt;P&gt;JAGaf55860: Bessel functions have precision problems&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;The corrected values:&lt;/P&gt;&lt;P&gt;-1.68339139976380275131 long double&lt;/P&gt;&lt;P&gt;-1.68339139976380280928 double&lt;BR /&gt;-1.68339145183563232422 float&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;gt;IA-64 supports the Intel 80-bit floating type; perhaps libm uses it internally.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Naturally, the Integrity Math Lib was rewritten to be faster and more accurate.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;gt;perhaps PHSS_32066 (Math Library Cumulative Patch) will help.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Unfortunately not until PHSS_33276.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Most math function are accurate to .5 ULP.&amp;nbsp; But Bessel and a few other functions don't meet this:&lt;/P&gt;&lt;P&gt;&lt;A target="_blank" href="http://www.hp.com/go/fp#5.5"&gt;http://www.hp.com/go/fp#5.5&lt;/A&gt;&lt;/P&gt;</description>
      <pubDate>Wed, 28 Dec 2011 12:10:28 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/bessel-function-yn-appears-only-single-precision-on-ia64/m-p/5430707#M639964</guid>
      <dc:creator>Dennis Handly</dc:creator>
      <dc:date>2011-12-28T12:10:28Z</dc:date>
    </item>
  </channel>
</rss>

