Previous Up Next

6.10.11  La fonction erf : erf

erf a comme argument un nombre a.
erf calcule les valeurs de la fonction erf au point a.
On a par définition :

erf(x)=
2
π
x


0
et2dt

On a :

erf(+∞)=1
erf(−∞)=−1

En effet on sait que :

+∞


0
et2dt=
π
2

On tape :

erf(1)

On obtient :

0.84270079295

On tape :

erf(1/(sqrt(2)))*1/2+0.5

On obtient :

0.841344746069

Remarque
Il y a une relation entre les fonctions erf et normal_cdf :
normal_cdf(x)=1/2+1/2erf(x/√2)
En effet :
normal_cdf(x)=1/2+1/√0xet2/2dt
donc avec le changement de variables t=u* √2 on a :
normal_cdf(x)=1/2+1/√π0x/√2eu2du=1/2+1/2erf(x/√2)
On vérifie en tapant :
normal_cdf(1)=0.841344746069


Previous Up Next