Binomials[n_] := Table[{m, 2^(-n) n!/(m! (n-m)!)}, {m, 0, n}]
Binomials[2]
Binomials[5]
ListPlot[Binomials[5], PlotJoined->True]
GaussianApprox[x_] := Exp[-(x-n/2)^2 / (n/2)] / Sqrt[n Pi/2]
n := 5
Plot[GaussianApprox[x], {x,0,n}]
ListPlot[Binomials[n], PlotJoined->True]
Show[%,%%]
n := 10
...
n := 20
...
fstar[x_] := Exp[-x^2/2]/Sqrt[2 Pi]
fstar[0.3]
Plot[fstar[x],{x,-4,4}]
(* Show that it's normalized *)
Integrate[fstar[x],{x, -Infinity, Infinity}]
(* Define convolution *)
Convolve[f_,g_][x_]:= Integrate[f[yvar] g[x-yvar],{yvar,-Infinity,Infinity}]
Convolve[fstar, fstar][x]
T[f_][x_] := Sqrt[2] Convolve[f,f][Sqrt[2] x] T[fstar][x] T[fstar][x] == fstar[x]
T[fstar+delta][x](* Unfortunately, this version of Mathematica gets tied up in knots if we expand inside the integral. Let's pull out the integrand first and work with it directly. *)
Integrand = %[[1]] %[[2,1]]
% /. (delta + fstar)[z_] -> (delta[z] + fstar[z])
Expand[%]
%[[2]] + %[[3]]
Integrate[%, {yvar, -Infinity, Infinity}]
DT[delta_][x_] = %;
DT[fstar][x] delta[0][x_] = fstar[x] DT[delta[0]][x] / delta[0][x](* Second eigenfunction is the derivative of fstar with respect to x. What probability distribution is approximated by fstar + epsilon fstar'? What physical significance does this eigenvalue have? Relate it to the known fact that the mean of the sum of two random variables is the sum of the means. *)
delta[1][x_] = D[fstar[x],x] DT[delta[1]][x] / delta[1][x](* Next eigenvector is derivative of Gaussian wrt it's width! Normalized Gaussian of standard deviation sigma/Sqrt[2] is fstar[x/sigma]/sigma What physical significance does this have? *)
D[fstar[x/sigma]/sigma, sigma] // Simplify delta[2][x_] = (% /. sigma -> 1) Simplify[DT[delta[2]][x] / delta[2][x]] (* Slow! *)(* Notice, that in the first three cases, the eigenfunctions were fstar times Hermite polynomials: let's experiment with some more ... *)
HermiteH[2,x] HermiteH[2,x/Sqrt[2]] HermiteH[2,x/Sqrt[2]] fstar[x] delta[2][x] delta[n_][x_] = HermiteH[n,x/Sqrt[2]] fstar[x] e[n_] := e[n] = Simplify[DT[delta[n]][x] / delta[n][x]] e[0] e[1] e[2] (* 52.43 Second *) e[3] (* 54.37 Second *) e[4] (* XXX Second *)(* There is no good reason for this to be so slow: the old version of Mathematica did it much faster. I'm guessing that they tried to make the integration routines more powerful, and they got bogged down. Maple doesn't seem to simplify the expressions, but it's faster. It probably would be faster to do the integrals for DT by hand, especially if you use the properties of Hermite polynomials. Feel free ... *) (* Leading irrelevant eigenvalue is e[3], plot eigenfunction *)
Plot[delta[3][x],{x,-2,2}]
(* Leading irrelevant eigenvalue for symmetric perturbations is e[4],
plot eigenfunction *)
Plot[delta[4][x],{x,-2,2}]
Plot[2^(-10)*10!/(x! * (10-x)!), {x, 0, 10}]
Plot[(2/Sqrt[10])*fstar[(x-5)/(Sqrt[10]/2)], {x, 0, 10}]
Plot[2^(-10)*10!/(x! * (10-x)!)
- (2/Sqrt[10])*fstar[(x-5)/(Sqrt[10]/2)], {x, 0, 10}]
Plot[2^(-20)*20!/(x! * (20-x)!)
- (2/Sqrt[20])*fstar[(x-10)/(Sqrt[20]/2)], {x, 0, 20}]
(* After twice as many coin flips, the perturbation shrinks in height by
2 Sqrt[2], but (remember) it grows in width by Sqrt[2], so the eigenvalue
of DT makes sense ...
The renormalization group not only provides an explanation for the
central limit theorem, it also gives us a description of the approach
to the "Gaussian fixed point".
Converting from eigenvalues of the renormalization group to
universal critical exponents involves a small calculation.
With what power of N does the N-coin flip distribution converge to the
Gaussian form? *)
n = 10
Plot[{2^(-n) n!/(x! (n-x)!) - (2/Sqrt[n]) delta[0][(x-n/2)/(Sqrt[n]/2)],
delta[4][(x-n/2)/(Sqrt[n]/2)]/(-24) n^(-3/2)}, {x, 0, n}]
Jim Sethna, sethna@lassp.cornell.edu
Statistical Mechanics: Entropy, Order Parameters, and Complexity,
now available at
Oxford University Press
(USA,
Europe).