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.

A007569 Number of nodes in regular n-gon with all diagonals drawn.

Original entry on oeis.org

1, 2, 3, 5, 10, 19, 42, 57, 135, 171, 341, 313, 728, 771, 1380, 1393, 2397, 1855, 3895, 3861, 6006, 5963, 8878, 7321, 12675, 12507, 17577, 17277, 23780, 16831, 31496, 30945, 40953, 40291, 52395, 47017, 66082, 65019, 82290, 80921, 101311, 84883, 123453, 121485
Offset: 1

Views

Author

N. J. A. Sloane, Bjorn Poonen (poonen(AT)math.princeton.edu)

Keywords

Comments

I.e., vertex count of the n-polygon diagonal intersection graph. - Eric W. Weisstein, Mar 08 2018
Also the circumference of the n-polygon diagonal intersection graph (since these graphs are Hamiltonian). - Eric W. Weisstein, Mar 08 2018
a(n) = n + sum of row n of triangle A292105. - N. J. A. Sloane, Jun 01 2025

References

  • N. J. A. Sloane and Simon Plouffe, The Encyclopedia of Integer Sequences, Academic Press, 1995 (includes this sequence).

Crossrefs

Cf. A006561, A007678 (regions), A292105.
Sequences related to chords in a circle: A001006, A054726, A006533, A006561, A006600, A007569, A007678. See also entries for chord diagrams in Index file.

Programs

  • Mathematica
    del[m_,n_]:=If[Mod[n,m]==0,1,0]; Int[n_]:=If[n<4, n, n + Binomial[n,4] + del[2,n](-5n^3+45n^2-70n+24)/24 - del[4,n](3n/2) + del[6,n](-45n^2+262n)/6 + del[12,n]*42n + del[18,n]*60n + del[24,n]*35n - del[30,n]*38n - del[42,n]*82n - del[60,n]*330n - del[84,n]*144n - del[90,n]*96n - del[120,n]*144n - del[210,n]*96n]; Table[Int[n], {n,1,1000}] (* T. D. Noe, Dec 21 2006 *)
  • PARI
    apply( {A007569(n)=A006561(n)+n}, [1..44]) \\ M. F. Hasler, Aug 06 2021
  • Python
    def d(n,m): return not n % m
    def A007569(n): return 2 if n == 2 else n*(42*d(n,12) - 144*d(n,120) + 60*d(n,18) - 96*d(n,210) + 35*d(n,24)- 38*d(n,30) - 82*d(n,42) - 330*d(n,60) - 144*d(n,84) - 96*d(n,90)) + (n**4 - 6*n**3 + 11*n**2 + 18*n -d(n,2)*(5*n**3 - 45*n**2 + 70*n - 24) - 36*d(n,4)*n - 4*d(n,6)*n*(45*n - 262))//24 # Chai Wah Wu, Mar 08 2021
    

Formula

a(n) = A006561(n)+n. - T. D. Noe, Dec 23 2006
If n is odd, a(n) = binomial(n,4) + n. - N. J. A. Sloane, Aug 30 2021