## Procedimiento numérico

Número de moléculas N1 que tienen una energía menor que Ec

$\begin{array}{l}{N}_{1}=\frac{4N}{\sqrt{\pi }}\left(-\frac{1}{2}y\mathrm{exp}\left(-{y}^{2}\right)+\frac{1}{2}\underset{0}{\overset{\sqrt{{x}_{c}}}{\int }}\mathrm{exp}\left(-{y}^{2}\right)dy\right)=\\ \frac{2N}{\sqrt{\pi }}\left(-\sqrt{{x}_{c}}\mathrm{exp}\left(-{x}_{c}\right)+\frac{\sqrt{\pi }}{2}\text{erf}\left(\sqrt{{x}_{c}}\right)\right)\end{array}$

donde xc=Ec/kT

erf(x) se denomina integral de los errores

$\text{erf}\left(x\right)=\frac{2}{\sqrt{\pi }}\underset{0}{\overset{x}{\int }}\mathrm{exp}\left(-{y}^{2}\right)dy$

 double erfcc(double x) { double t,z,ans; z=Math.abs(x); t=1.0/(1.0+0.5*z); ans=t*Math.exp(-z*z-1.26551223+t*(1.00002368+t*(0.37409196+t*(0.09678418+ t*(-0.18628806+t*(0.27886807+t*(-1.13520398+t*(1.48851587+ t*(-0.82215223+t*0.17087277))))))))); return x >= 0.0 ? ans : 2.0-ans; } double proporcion(double Ec){ double xc=Ec*11604.49/T; double y=2*(Math.sqrt(Math.PI)*(1.0-erfcc(Math.sqrt(xc)))/2-Math.sqrt(xc)*Math.exp(-xc))/Math.sqrt(Math.PI); return (1.0-y); //proporción de partículas con energía mayor que Ec }