Is there an easily available implementation of erf() for Python?

后端 未结 8 1997
日久生厌
日久生厌 2020-12-24 04:54

I can implement the error function, erf, myself, but I\'d prefer not to. Is there a python package with no external dependencies that contains an implementation of this func

8条回答
  •  既然无缘
    2020-12-24 05:37

    I have a function which does 10^5 erf calls. On my machine...

    scipy.special.erf makes it time at 6.1s

    erf Handbook of Mathematical Functions takes 8.3s

    erf Numerical Recipes 6.2 takes 9.5s

    (three-run averages, code taken from above posters).

提交回复
热议问题