Menu

#78 better erf-erfinv approximations

open
nobody
None
5
2014-08-18
2012-03-24
andy_panov
No

Please find attached file with tests of boost erf-erfinv approximations against itpp. Here is the test output:

Testing erf - erfinv implementations

Case I (erf difference in [-6..6] range) - Detected max rel difference: 2.969353e-007
Case II (erfinv(erf) test in [-4 4] range) - max error (boost) 4.364868e-010 at 3.999939e+000
Case II (erfinv(erf) test in [-4 4] range) - max error (itpp) 1.599292e-007 at -2.264934e+000
Case III (erfinv range) - erfinv(erf(-5.0)) (boost) -5.000001e+000
Case III (erfinv range) - erfinv(erf(-5.0)) (itpp) -1.#INF00e+000
Case III (erfinv range) - erfinv(erf(5.0)) (boost) 5.000001e+000
Case III (erfinv range) - erfinv(erf(5.0)) (itpp) 4.996596e+000

I can patch itpp implementation if you are interested.

Discussion

  • andy_panov

    andy_panov - 2012-03-24
     
  • Bogdan Cristea

    Bogdan Cristea - 2013-05-23

    Hi Andy

    Are there any news about this issue ?

    Bogdan

     
  • andy_panov

    andy_panov - 2013-05-23

    Hi Bogdan,

    attached file provides better approximations for erf and erfinv functions borrowed from boost. These approximations compute erf and erfinv with better precision in a larger domain (test example illustrates this point).

    My primary motivation was to provide better accuracy for sine frequencies in generation of Rayleigh fading in ITPP channel models. Definitely, these functions are quite useful in other areas of communications theory and signal processing. I've posted this request more then a year ago but no one has shown an interest in it.

    I can patch itpp implementation of erf and erfinv functions if you think it worth the efforts.

    Andy.

     
  • Bogdan Cristea

    Bogdan Cristea - 2013-05-23

    Hi Andy

    I am trying only to close as many feature requests as possible for this release. If you could improve the current implementation that would be very good, but we could leave this feature for the next release, if there is not enough time.

    regards
    Bogdan

     
  • andy_panov

    andy_panov - 2013-05-23

    I fell we'd better leave this for the next release. I afraid I can not provide the patch in time :(

    Andy.

     
  • Bogdan Cristea

    Bogdan Cristea - 2013-05-23

    No problem Andy, I hope to make the release this week-end. Anyway, you have a major contribution to this release :)

     

Log in to post a comment.

Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.