(* Code for calculating the zeta function for the pinball *) Get["orbits.m"] t[n_] := Exp[s Tp[n]] z^np[n]/Abs[lam[n]] zeta = Series[Product[(1-t[i]), {i,0,40}], {z,0,7}] gamma[m_] := Block[{zeta1}, zeta1 = Normal[Series[zeta, {z,0,m}]] /.z->1; N[s /. FindRoot[zeta1==0, {s, 0.4}], 16] ] gam = Table[gamma[i], {i,1,7}] Print["Escape rate = ", gam] zeta1 = zeta /. s -> gamma[7] Plot[Evaluate[Normal[zeta1]], {z, -100, 100}] ListPlot[Log[Abs[CoefficientList[zeta1, z]]]]