H16 = matkn06[987,16];

vap16 = Eigenvalues[H16];

vep16=Eigenvectors[H16];

log16[x_,k_]:=If[x==vap16[[k]],0,Log[Abs[x-vap16[[k]]]]];

thouless16[x_]:=Sum[ N[log16[x,k]/987],{k,1,987}];
fiboseq[15]
H13 = matkn06[233,13];

H15=matkn06[610,15];

vap15=Eigenvalues[H15];

log15[x_,k_]:=If[x==vap15[[k]],0,Log[Abs[x-vap15[[k]]]]];
thouless15[x_]:=Sum[ N[log15[x,k]/610],{k,1,610}];

vap13 = Eigenvalues[H13];

log13[x_,k_]:=If[x==vap13[[k]],0,Log[Abs[x-vap13[[k]]]]];
thouless13[x_]:=Sum[ N[log13[x,k]/233],{k,1,233}];
H14=matkn06[377,14];
fiboseq[14]

log14[x_,k_]:=If[x==vap14[[k]],0,Log[Abs[x-vap14[[k]]]]];
thouless14[x_]:=Sum[ N[log14[x,k]/377],{k,1,377}];
thouless14[6]

Clear[H14,vap14,thouless14,log14]

vap14=Eigenvalues[H14];

corr1377dir :={};

For[k=1,k<987,k++,AppendTo[corr1377dir,Abs[vep16[[k,1]]*vep16[[k,377]]]]];

corr1377th3:={};
For[k=1,k<378,k++,AppendTo[corr1377th3,Abs[Exp[-377*thouless16[vap14[[k]]]]]]];

corr1377th:={};

alpha:=N[(1+Sqrt[5])/2];

Clear[corr1377th]

For[k=1,k<988,k++,AppendTo[corr1377th,Abs[Exp[-377*thouless16[alpha*vap16[[k]]]]]]];

ListPlot[{corr1377th,corr1377dir}]

ListPlot[corr1377th]

ListLinePlot[Log[corr1377th]]

corr1377th2:={};

For[k=1,k<988,k++,AppendTo[corr1377th2,Abs[Exp[-987*thouless13[vap16[[k]]]]]]];

DiscretePlot[thouless14[vap16[[n]]],{n,900}]

DiscretePlot[{thouless16[vap16[[n]]],N[377/987]*thouless14[vap16[[n]]]+N[610/987]*thouless15[vap16[[n]]]},{n,900}]

DiscretePlot[{thouless16[-2+n/250],thouless14[-2+n/250],thouless15[-2+n/250]},{n,1000}];

ListPlot[{vap16}];

thouless14bis[x_]:=Sum[ N[Log[Abs[x-vap14[[k]]]/377]],{k,1,377}];

thouless14bis[vap14[[1]]]

Log[0]

Clear[pair15]

pair16:={};

For[k=1,k<988,k++,AppendTo[pair16,{vap16[[k]],thouless16[vap16[[k]]]}]];

pair15:={};

For[k=1,k<988,k++,AppendTo[pair15,{vap16[[k]],2*thouless15[vap16[[k]]]}]];

ListPlot[{pair15,pair16}]

ratio[n_]:=If[thouless16[vap16[[n]]]==0,0,N[thouless15[vap16[[n]]]/thouless16[vap16[[n]]]]];

N[thouless15[vap16[[4]]]]/N[thouless16[vap16[[4]]]]

ratio[700]

DiscretePlot[ratio[n],{n,900}]

thouless16[vap16[[700]]]

Clear[ratio]