On 28.11.2013 19:43, Axel Vogt wrote: > On 28.11.2013 00:20, firstname.lastname@example.org wrote: >> On Tuesday, November 26, 2013 3:10:29 PM UTC-5, Axel Vogt wrote: >>> On 26.11.2013 16:10, dspguy2t wrote: > ... > > "erf" is the error function (a variation of the cumulative normal distribution) > and you should find *good* code to evaluate it (look up Wikipedia) and if you > use gcc then it comes within its libraries, IIRC. > > If you insist to do integration, then transform to Int( (exp(-s^2), s = .. infinity). > exp(-s^2) <= DBL_ESP for s <= 6.0, so you live on a quite finite range (it will > depend on your constand 0 < A). > > Or you use the other method for infinite ranges, look up Abramowitz & Stegun > (or Wikipedia), there should be codes ready to run.
Without discussing your A and translating that to a simple recipe: replace you original 0 by A/36.