import numpy import matplotlib.pyplot import scipy.special def generateAlgebra(w,o,bw,FWHM,R): sigma=FWHM/2.35 ctr=0.5*o.size #w=numpy.zeros([n,n]) q=bw/numpy.sqrt(2) for i in numpy.arange(o.size): for j in numpy.arange(o.size): w[i,j]=0.5*(scipy.special.erf(q*(j-i+0.5)/sigma)- scipy.special.erf(q*(j-i-0.5)/sigma)) #o=numpy.zeros(n) p=0 for i in numpy.arange(o.size): if numpy.abs(i-ctr)