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.

Showing 1-2 of 2 results.

A208774 Number of n-bead necklaces labeled with numbers 1..5 not allowing reversal, with no adjacent beads differing by more than 1.

Original entry on oeis.org

5, 9, 13, 24, 41, 91, 185, 435, 1009, 2445, 5945, 14813, 36977, 93465, 237313, 606465, 1556033, 4010205, 10367897, 26891385, 69930457, 182302161, 476262761, 1246710303, 3269321393, 8587489185, 22590646417, 59511087087, 156973954865, 414552479249, 1096017973385, 2900753690865, 7684758676201, 20377462520193
Offset: 1

Views

Author

R. H. Hardin, Mar 01 2012

Keywords

Examples

			All solutions for n=3:
..5....1....3....2....2....4....4....4....1....3....2....3....1
..5....1....4....2....2....4....5....4....1....3....3....3....2
..5....1....4....3....2....5....5....4....2....3....3....4....2
		

Crossrefs

Column 5 of A208777.
Cf. A215337 (cyclically smooth Lyndon words with 5 colors).

Programs

  • Mathematica
    sn[n_, k_] := 1/n*Sum[DivisorSum[n, EulerPhi[#]*(1 + 2*Cos[i*Pi/(k + 1)])^(n/#)&], {i, 1, k}]; Table[sn[n, 5], {n, 1, 34}] // Simplify (* Jean-François Alcover, Oct 31 2017, after Joerg Arndt *)
  • PARI
    /* from the Knopfmacher et al. reference */
    default(realprecision,99); /* using floats */
    sn(n,k)=1/n*sum(i=1,k,sumdiv(n,j,eulerphi(j)*(1+2*cos(i*Pi/(k+1)))^(n/j)));
    vector(66,n, round(sn(n,5)) )
    /* Joerg Arndt, Aug 09 2012 */

Formula

a(n) = Sum_{ d | n } A215337(d). - Joerg Arndt, Aug 13 2012
a(n) = (1/n) * Sum_{d | n} totient(n/d) * A124698(n). - Andrew Howroyd, Mar 18 2017

A136493 Triangle of coefficients of characteristic polynomials of symmetrical pentadiagonal matrices of the type (1,-1,1,-1,1).

Original entry on oeis.org

1, -1, 1, 1, -2, 0, -1, 3, 0, 0, 1, -4, 1, 2, 0, -1, 5, -3, -5, 1, 1, 1, -6, 6, 8, -5, -2, 1, -1, 7, -10, -10, 14, 4, -4, 0, 1, -8, 15, 10, -29, -4, 12, 0, 0, -1, 9, -21, -7, 50, -4, -30, 4, 4, 0, 1, -10, 28, 0, -76, 28, 61, -20, -15, 2, 1
Offset: 0

Views

Author

Roger L. Bagula, Mar 21 2008

Keywords

Comments

From Georg Fischer, Mar 29 2021: (Start)
The pentadiagonal matrices have 1 in the main diagonal, -1 in the first lower and upper diagonal, 1 in the second lower and upper diagonal, and 0 otherwise.
The linear recurrences that yield A124805, A124806, A124807 and similar can be derived from the rows of this triangle (the first element of a row must be removed and multiplied onto the remaining elements).
This observation extends to other sequences. For example the linear recurrence signature (5,-6,2,4,0) of A124698 "Number of base 5 circular n-digit numbers with adjacent digits differing by 1 or less" can be derived from the coefficients of the characteristic polynomial of a tridiagonal (type -1,1,-1) 5 X 5 matrix.
(End)

Examples

			Triangle begins:
   1;
  -1,   1;
   1,  -2,   0;
  -1,   3,   0,   0;
   1,  -4,   1,   2,   0;
  -1,   5,  -3,  -5,   1,  1;
   1,  -6,   6,   8,  -5, -2,   1;
  -1,   7, -10, -10,  14,  4,  -4,   0;
   1,  -8,  15,  10, -29, -4,  12,   0,   0;
  -1,   9, -21,  -7,  50, -4, -30,   4,   4,  0;
   1, -10,  28,   0, -76, 28,  61, -20, -15,  2,  1;
		

References

  • Anthony Ralston and Philip Rabinowitz, A First Course in Numerical Analysis, 1978, ISBN 0070511586, see p. 256.

Crossrefs

Programs

  • Mathematica
    T[n_, m_]:= Piecewise[{{-1, 1+m==n || m==1+n}, {1, 2+m==n || m==n || m==2+n}}];
    MO[d_]:= Table[T[n, m], {n,d}, {m,d}];
    CL[n_]:= CoefficientList[CharacteristicPolynomial[MO[n], x], x];
    Join[{{1}}, Table[Reverse[CL[n]], {n,10}]]//Flatten
    (* For the signature of A124698 added by Georg Fischer, Mar 29 2021 : *)
    Reverse[CoefficientList[CharacteristicPolynomial[{{1,-1,0,0,0}, {-1, 1,-1,0,0}, {0,-1,1,-1,0}, {0,0,-1,1,-1}, {0,0,0,-1,1}}, x], x]]

Formula

Sum_{k=1..n} T(n, k) = (-1)^(n mod 3) * A087509(n+1) + [n=1].
From G. C. Greubel, Aug 01 2023: (Start)
T(n, n) = A011658(n+2).
T(n, 1) = (-1)^(n-1).
T(n, 2) = A181983(n-1).
T(n, 3) = (-1)^(n-3)*A161680(n-3). (End)

Extensions

Edited by Georg Fischer, Mar 29 2021
Showing 1-2 of 2 results.