Orthormality and functions

vs 0.2, 25/1/08 © Niels Walet

Work with Gaussians, use (∫_(-∞)^∞)(e^(-a (x^2)))dx=((Sqrt[π])/(Sqrt[a])) if a>0.

(∫_(-∞)^∞)(E^(-a (x^2)))\[DifferentialD]x

Now let us use a "basis" of Gaussians, as used in numerical calculations. This corresponds to a choice of a's. We shall compare a linear progression ((Subscript[a, i])=i h) abd a geometrix progression ((Subscript[a, i])=(h^i)(Subscript[a, 0])).

0 A smart shorthand

This command sums two elements of the list a and places those into an array (using the Outer command). The Map[N[((Sqrt[π])/(Sqrt[#1]))]& command replace each element in the array by the numerical value of ((Sqrt[π])/(Sqrt[element])). The overlap between two (unnormalised) Gaussians is

(∫_(-∞)^∞)(e^(-(a+b) (x^2)))dx=((Sqrt[π])/(Sqrt[a+b])),

so that we are really calculating the overlap matrix quite quickly if we give the list of coefficients (Subscript[a, i]) as input to ov[ ].

ov[a_]:=Map[N[((Sqrt[π])/(Sqrt[#1]))]&,Outer[Plus,a,a]]

Now compare the two following cases, and draw some conclusions. Which is best? Which might be complete? Which will fail numerically?

1 Linear progression

l={};Do[a=Table[2 i, {i,1,Ngs}];overlap=ov[a];Print[Eigenvalues[overlap]];l=Append[l,{Ngs,Last[Eigenvalues[overlap]]}],{Ngs,1,10}]

Plot the smallest eigenvalue versus N

ft=FindFit[l,c Exp[-d x],{c,d},x]

Show[ListLogPlot[l],LogPlot[c Exp[-d x]/.ft,{x,1,10}]]

Turn the eigenvectors into eigenfunctions by muktiplying with the relevant Gaussians

evs=Eigensystem[overlap][[1]];evmat=Eigensystem[overlap][[2]];ovh=Transpose[evmat] . DiagonalMatrix[(evs^(-1/2))].evmat;basis=ovh.Map[Exp[-#1 (x^2)]&,a];

And plot them

GraphicsColumn[Table[Plot[Table[basis[[i]]],{x,-2,2},PlotRange->{-2,2}],{i,1,10}]]

2 Geometric progression

l={};Do[a=Table[(3^i), {i,1,Ngs}];overlap=ov[a];Print[Eigenvalues[overlap]];l=Append[l,{Ngs,Last[Eigenvalues[overlap]]}],{Ngs,1,10}]

Plot the smallest eigenvalue versus N

Behavior seems powerlike, rather than exponential:

ft=FindFit[l,c (((x))^(-n)) ,{c,n},x]

Show[ListLogPlot[l],LogPlot[c (x^(-n))/.ft,{x,1,10}]]

Turn the eigenvectors into eigenfunctions by multiplying with the relevant Gaussians

evs=Eigensystem[overlap][[1]];evmat=Eigensystem[overlap][[2]];ovh=Transpose[evmat] . DiagonalMatrix[(evs^(-1/2))].evmat;basis=ovh.Map[Exp[-#1 (x^2)]&,a];

GraphicsColumn[Table[Plot[Table[basis[[i]]],{x,-2,2},PlotRange->{-2,2}],{i,1,10}]]