def make_gauss(N, sigma, mu):
    k = N / (sigma * math.sqrt(2 * math.pi))
s = -1.0 / (2 * sigma * sigma)

def f(x):
    return k * math.exp(s * (x - mu) * (x - mu))
return f
Best way to write a Python function that integrates a gaussian?