%I #47 Jul 29 2023 07:13:48
%S 0,7,16,1,40,55,8,91,112,5,160,187,8,247,280,35,352,391,16,475,520,7,
%T 616,667,80,775,832,11,952,1015,40,1147,1216,143,1360,1435,56,1591,
%U 1672,65,1840,1927,224,2107,2200,85,2392,2491,32,2695,2800,323,3016,3127
%N Numerator of 1/9 - 1/n^2.
%C The denominators are given in A061040.
%C From Paschen spectrum of hydrogen. Wavelengths in hydrogen spectrum are given by Rydberg's formula 1/wavelength = constant*(1/m^2 - 1/n^2).
%D J. E. Brady and G. E. Humiston, General Chemistry, 3rd. ed., Wiley; p. 78.
%H Reinhard Zumkeller, <a href="/A061039/b061039.txt">Table of n, a(n) for n = 3..1000</a>
%H J. J. O'Connor and E. F. Robertson, <a href="http://www-groups.dcs.st-andrews.ac.uk/~history/Mathematicians/Rydberg.html">Johannes Robert Rydberg</a>
%H Eric Weisstein's World of Physics, <a href="http://scienceworld.wolfram.com/physics/BalmerFormula.html">Balmer Formula</a>
%H <a href="/index/Rec#order_81">Index entries for linear recurrences with constant coefficients</a>, signature (0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1).
%F a(n) <= n^2 - 9; if n is not divisible by 3 then a(n) = n^2 - 9. - _Stefan Steinerberger_, Apr 16 2006
%F a(n) = 3*a(n-27) - 3*a(n-54) + a(n-81) for n > 83. - _Colin Barker_, Oct 09 2016
%F a(n) = (n^2 - 9)/9^2 if n == 3 or 24 (mod 27), a(n) = (n^2 - 9)/(3*9) if n == 6 or 24 or 15 or 21 (mod 27), a(n) = (n^2 - 9)/9 if n == 0 (mod 9) and n^2 - 9 otherwise. From the period length 27 sequence gcd(n^2 - 9, 9*n^2). - _Wolfdieter Lang_, Mar 15 2018
%p A061039:=n->numer(1/9-1/n^2): seq(A061039(n), n=3..80); # _Wesley Ivan Hurt_, Apr 12 2017
%t Table[Numerator[1/9 - 1/n^2], {n, 3, 60}] (* _Stefan Steinerberger_, Apr 16 2006 *)
%o (Haskell)
%o import Data.Ratio ((%), numerator)
%o a061039 n = numerator $ 1%9 - 1%n ^ 2 -- _Reinhard Zumkeller_, Jan 03 2012
%o (PARI) a(n)=numerator(1/9-1/n^2) \\ _Charles R Greathouse IV_, Nov 20 2012
%o (Python)
%o from math import gcd
%o def A061039(n): return (n**2-9)//gcd(n**2-9,9*n**2) # _Chai Wah Wu_, Apr 02 2021
%Y Cf. A061035..A061050.
%K nonn,frac,nice,easy
%O 3,2
%A _N. J. A. Sloane_, May 26 2001