cp's OEIS Frontend

This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.

A067956 Number of nodes in virtual, "optimal", chordal graphs of diameter 4 and degree n+1.

Original entry on oeis.org

9, 16, 41, 66, 129, 192, 321, 450, 681, 912, 1289, 1666, 2241, 2816, 3649, 4482, 5641, 6800, 8361, 9922, 11969, 14016, 16641, 19266, 22569, 25872, 29961, 34050, 39041, 44032, 50049, 56066, 63241, 70416, 78889
Offset: 1

Views

Author

S. Bujnowski & B. Dubalski (slawb(AT)atr.bydgoszcz.pl), Mar 08 2002

Keywords

Examples

			For n=5, n is odd; t=3; a(5) = (2*3*(3+1)*(3^2+3+4)/3)+1 = ((6*4*16)/3)+1 = 129.
For n=6, n is even; t=3; a(6) = a(5) + ((2*3+1)*(2*t^2+2*t+3))/3 = 129 + (7*27)/3 = 192.
		

References

  • Concrete Mathematics, R. L. Graham, D. E. Knuth, O. Patashnik, 1994, Addison-Wesley Company, Inc.

Crossrefs

Cf. A006007.

Programs

  • Maple
    for n from 1 to k do if ((n mod 2 ) = 1) then t := (n+1)/2; a[n] := ((2*(t*(t+1)*(t^2+t+4))/3)+1); else t := (n)/2; a[n] := ((2*(t*(t+1)*(t^2+t+4)/3)+1)+(2*t+1)*(2*t^2+2*t+3)/3); fi; print(a[n]); od;
  • Mathematica
    Array[((2 #2 (#2 + 1) (#2^2 + #2 + 4))/3) + 1 + (Boole[EvenQ[#1]]*((2 #2 + 1) (2 #2^2 + 2 #2 + 3))/3) & @@ {#, (# + Boole[OddQ[#]])/2} &, 35] (* Michael De Vlieger, Jul 29 2022 *)

Formula

For n odd, t = (n+1)/2, a(n) = ((2*t*(t+1)*(t^2+t+4))/3)+1;
for n even, t = n/2, a(n) = (((2*t*(t+1)*(t^2+t+4))/3)+1)+((2*t+1)*(2*t^2+2*t+3))/3.
G.f.: -x*(9-2*x-9*x^2+6*x^3+11*x^4-6*x^5-3*x^6+2*x^7)/(1+x)^3/(x-1)^5 . - R. J. Mathar, Apr 07 2025