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-9 of 9 results.

A078630 Numerators of coefficients of asymptotic expansion of probability p(n) (see A002816) in powers of 1/n.

Original entry on oeis.org

1, -4, 0, 20, 58, 796, 7858, 40324, 140194, 2444744, 40680494, -7117319032, -149539443124, -223750776484, -4960419494993024, -46146161037854692, -689434674121075448, -132496988938839119444, -9686633414582239854958, -442788087926096759821484
Offset: 0

Views

Author

N. J. A. Sloane, Dec 13 2002

Keywords

Examples

			p(n) = exp(-2)*(1 - 4/n + 20/(3n^3) + 58/(3n^4) + ...).
		

Crossrefs

Programs

  • Mathematica
    t = 15;
    y[n_]:=(1+Sum[Subscript[p,k]/n^k,{k,1,t}]);
    mul=1;start=9; If[t>9,mul=n^(t-9);start=t];
    w=Apart[Expand[mul*Simplify[
    y[n]*n*(n-1)*(n-2)*(n-3)*(n-4)*(n-5)*(n-6)*(n-7)*(n-8)*(n-9)*(n-10)
    -((3*n-30)*y[n-11]
    +(6*n-45)*y[n-10]*(n-10)
    +(5*n+18)*y[n-9]*(n-9)*(n-10)
    -(8*n-139)*y[n-8]*(n-8)*(n-9)*(n-10)
    -(26*n-204)*y[n-7]*(n-7)*(n-8)*(n-9)*(n-10)
    -(4*n-30)*y[n-6]*(n-6)*(n-7)*(n-8)*(n-9)*(n-10)
    +(26*n-148)*y[n-5]*(n-5)*(n-6)*(n-7)*(n-8)*(n-9)*(n-10)
    +(8*n-74)*y[n-4]*(n-4)*(n-5)*(n-6)*(n-7)*(n-8)*(n-9)*(n-10)
    -(9*n-18)*y[n-3]*(n-3)*(n-4)*(n-5)*(n-6)*(n-7)*(n-8)*(n-9)*(n-10)
    -(2*n-15)*y[n-2]*(n-2)*(n-3)*(n-4)*(n-5)*(n-6)*(n-7)*(n-8)*(n-9)*(n-10)
    +(n+2)*y[n-1]*(n-1)*(n-2)*(n-3)*(n-4)*(n-5)*(n-6)*(n-7)*(n-8)*(n-9)*(n-10))],n],n];
    sol=Solve[Table[Coefficient[w,n,j]==0,{j,start,start-t+1,-1}]];
    asympt=y[n]/.sol[[1]];
    Table[Numerator[Coefficient[asympt,n,-j]],{j,0,t}] (* Vaclav Kotesovec, Apr 06 2012 *)

Extensions

Terms a(5)-a(19) from Vaclav Kotesovec, Apr 06 2012 (terms a(5)-a(7) were wrong, see A089222 for more information)

A078631 Denominators of coefficients of asymptotic expansion of probability p(n) (see A002816) in powers of 1/n.

Original entry on oeis.org

1, 1, 1, 3, 3, 15, 45, 63, 63, 405, 14175, 51975, 93555, 15795, 42567525, 49116375, 91216125, 2170943775, 19538493975, 109185701625, 3093594879375, 10257709336875, 428772250281375, 281764621613475, 158210081654625, 160789593855515625
Offset: 0

Views

Author

N. J. A. Sloane, Dec 13 2002

Keywords

Examples

			p(n) = exp(-2)*(1 - 4/n + 20/(3n^3) + 58/(3n^4) + ...).
		

Crossrefs

Programs

  • Mathematica
    t = 15;
    y[n_]:=(1+Sum[Subscript[p,k]/n^k,{k,1,t}]);
    mul=1;start=9; If[t>9,mul=n^(t-9);start=t];
    w=Apart[Expand[mul*Simplify[
    y[n]*n*(n-1)*(n-2)*(n-3)*(n-4)*(n-5)*(n-6)*(n-7)*(n-8)*(n-9)*(n-10)
    -((3*n-30)*y[n-11]
    +(6*n-45)*y[n-10]*(n-10)
    +(5*n+18)*y[n-9]*(n-9)*(n-10)
    -(8*n-139)*y[n-8]*(n-8)*(n-9)*(n-10)
    -(26*n-204)*y[n-7]*(n-7)*(n-8)*(n-9)*(n-10)
    -(4*n-30)*y[n-6]*(n-6)*(n-7)*(n-8)*(n-9)*(n-10)
    +(26*n-148)*y[n-5]*(n-5)*(n-6)*(n-7)*(n-8)*(n-9)*(n-10)
    +(8*n-74)*y[n-4]*(n-4)*(n-5)*(n-6)*(n-7)*(n-8)*(n-9)*(n-10)
    -(9*n-18)*y[n-3]*(n-3)*(n-4)*(n-5)*(n-6)*(n-7)*(n-8)*(n-9)*(n-10)
    -(2*n-15)*y[n-2]*(n-2)*(n-3)*(n-4)*(n-5)*(n-6)*(n-7)*(n-8)*(n-9)*(n-10)
    +(n+2)*y[n-1]*(n-1)*(n-2)*(n-3)*(n-4)*(n-5)*(n-6)*(n-7)*(n-8)*(n-9)*(n-10))],n],n];
    sol=Solve[Table[Coefficient[w,n,j]==0,{j,start,start-t+1,-1}]];
    asympt=y[n]/.sol[[1]];
    Table[Denominator[Coefficient[asympt,n,-j]],{j,0,t}] (* Vaclav Kotesovec, Apr 06 2012 *)

Extensions

Terms a(8)-a(25) from Vaclav Kotesovec, Apr 06 2012

A078628 Number of ways of arranging the numbers 1..n in a circle so that there is no consecutive triple i, i+1, i+2 or i, i-1, i-2 (mod n).

Original entry on oeis.org

1, 1, 0, 4, 12, 76, 494, 3662, 30574, 284398, 2918924, 32791604, 400400062, 5281683678, 74866857910, 1135063409918, 18330526475060, 314169905117860, 5695984717957246, 108921059813769710, 2190998123920252622, 46250325111346491694
Offset: 1

Views

Author

N. J. A. Sloane, Dec 12 2002

Keywords

Comments

This sequence can be related to A165964 by the use of auxiliary sequences (and the auxiliary sequences can themselves be calculated by recurrence relations). So if we desire we can determine any value of this sequence. [From Isaac Lambert, Oct 07 2009]

Examples

			a(4) = 4: 4 2 1 3, 4 3 1 2, 4 1 3 2, 4 2 3 1.
a(5) = 12: 5 3 1 2 4, 5 2 3 1 4, 5 4 2 1 3, 5 2 4 1 3, 5 1 4 2 3, 5 2 1 4 3, 5 1 3 4 2, 5 3 1 4 2, 5 4 1 3 2, 5 3 4 1 2, 5 2 4 3 1, 5 3 2 4 1.
		

References

  • Wayne M. Dymacek, Isaac Lambert and Kyle Parsons, Arithmetic Progressions in Permutations, http://math.ku.edu/~ilambert/CN.pdf, 2012. - From N. J. A. Sloane, Sep 14 2012

Crossrefs

Cf. A078673. See A002816, A078603 for analogous sequence with restrictions only on pairs.

Extensions

a(11)-a(13) from John W. Layman, Nov 15 2004
a(14) from Isaac Lambert, Oct 07 2009

A089222 Number of ways of seating n people around a table for the second time without anyone sitting next to the same person as they did the first time.

Original entry on oeis.org

1, 0, 0, 0, 0, 10, 36, 322, 2832, 27954, 299260, 3474482, 43546872, 586722162, 8463487844, 130214368530, 2129319003680, 36889393903794, 675098760648204, 13015877566642418, 263726707757115400, 5603148830577775218, 124568968969991162100, 2892414672938546871250
Offset: 0

Views

Author

Udi Hadad (somebody(AT)netvision.net.il), Dec 22 2003

Keywords

Comments

A078603 counts these arrangements up to circular symmetry (i.e., two arrangements are the same if one can be rotated to give the other). A002816 counts them up to dihedral symmetry (i.e., two arrangements are the same if one can be rotated or reflected to give the other). - Joel B. Lewis, Jan 28 2010

Examples

			a(4)=0 because trying to arrange 1,2,3,4 around a table will always give a couple who is sitting next to each other and differ by 1.
		

References

  • J. Snell, Introduction to Probability, e-book, pp. 101 Q. 20.

Crossrefs

Programs

  • Mathematica
    Same[cperm_, n_] := ( For[same = False; i = 2, (i <= n) && ! same, i++, same = ((Mod[cperm[[i - 1]], n] + 1) == cperm[[i]]) || ((Mod[cperm[[ i]], n] + 1) == cperm[[i - 1]])]; same = same || ((Mod[cperm[[n]], n] + 1) == cperm[[1]]) || ((Mod[ cperm[[1]], n] + 1) == cperm[[n]]); Return[same]); CntSame[n_] := (allPerms = Permutations[Range[n]]; count = 0; For[j = 1, j <= n!, j++, perm = allPerms[[j]]; If[ ! Same[perm, n], count++ ]]; Return[count]);
    (* or direct computation of terms *)
    Table[If[n<3, 0, n! + (-1)^n*2n + Sum[(-1)^r*(n/(n-r))^2 * (n-r)! * Sum[2^c * Binomial[r-1,c-1] * Binomial[n-r,c], {c,1,r}], {r,1,n-1}]], {n,1,25}] (* Vaclav Kotesovec, Apr 06 2012 *)

Formula

Inclusion-exclusion gives that for n > 2, we have a(n) = n! + 2*n*(-1)^n + Sum_{1 <= k <= m < n} (-1)^m * (n/k) * binomial(n-m-1, k-1) * binomial(m-1, k-1) * 2^k * n * (n-m-1)!. - Joel B. Lewis, Jan 28 2010
a(n) = (3*n-30)*a(n-11) + (6*n-45)*a(n-10) + (5*n+18)*a(n-9) - (8*n-139)*a(n-8) - (26*n-204)*a(n-7) - (4*n-30)*a(n-6) + (26*n-148)*a(n-5) + (8*n-74)*a(n-4) - (9*n-18)*a(n-3) - (2*n-15)*a(n-2) + (n+2)*a(n-1), n >= 14. - Vaclav Kotesovec, Apr 13 2010
The asymptotic expansion from article by Aspvall and Liang (also cited in article by Tauraso) is wrong. Bad terms are 736/(15*n^5) + 8428/(45*n^6) + 40174/(63*n^7). Right asymptotic formula is a(n) ~ (n!/e^2)*(1 - 4/n + 20/(3*n^3) + 58/(3*n^4) + 796/(15*n^5) + 7858/(45*n^6) + 40324/(63*n^7) + 140194/(63*n^8) + ...). Verified also numerically. For example, for n=200, exact/asymptotic results are 1.0000000000125542243 (Aspvall + Liang), 1.0000000000000008990 (Kotesovec 7 terms) or 1.0000000000000000121 (Kotesovec 8 terms). - Vaclav Kotesovec, Apr 06 2012
a(n) = 2*n*A002816(n) for n > 1. - Martin Renner, Apr 01 2022

Extensions

Tauraso reference from Parthasarathy Nambi, Dec 21 2006
More terms from Vladeta Jovovic, Nov 29 2009
a(0)=1 prepended by Alois P. Heinz, Jul 31 2019

A326411 Triangle T(n,k) read by rows: T(n,k) = the number of ways of seating n people around a table for the second time so that k pairs are maintained. Reflected and rotated sequences are counted as one.

Original entry on oeis.org

1, 0, 1, 0, 0, 1, 0, 0, 0, 1, 0, 0, 2, 0, 1, 1, 0, 5, 5, 0, 1, 3, 12, 15, 20, 9, 0, 1, 23, 70, 112, 91, 49, 14, 0, 1, 177, 544, 740, 640, 302, 96, 20, 0, 1, 1553, 4500, 6003, 4725, 2439, 747, 165, 27, 0, 1, 14963, 41740, 53585, 41420, 20810, 7076, 1550, 260, 35, 0, 1
Offset: 0

Views

Author

Witold Tatkiewicz, Aug 07 2019

Keywords

Comments

Poulet (1919) arrives at this triangle of numbers by considering n-sided polygons whose vertices lie on a circle. Call a side of such a polygon simple if its endpoints are adjacent on the circle. Then T(n,k) is the number of such polygons with k simple sides. There is also a connection with A002464 (see that entry). - N. J. A. Sloane, Mar 08 2022
Definition requires "pairs" and for n=0 it is assumed that there is 1 way of seating 0 people around a table for the second time so that 0 pairs are maintained and 1 person forms only one pair with him/herself. Therefore T(0,0)=1, T(1,0)=0 and T(1,1)=1.
The weighted average of each row using k as weights converges to 2 for large n and appears to be given by (Sum_{k} k*T(n,k))/n! = 2/(n-1) + 2.

Examples

			Assuming the initial order was {1,2,3,4,5} (therefore 1 and 5 form a pair as the first and last persons are neighbors in the case of a round table) there are 5 sets of ways of seating them again so that 3 pairs are conserved: {1,2,3,5,4}, {2,3,4,1,5}, {3,4,5,2,1}, {4,5,1,3,2}, {5,1,2,4,3}. Since within each set we do not allow for circular symmetry (e.g., {1,2,3,5,4} and its rotation to form {2,3,5,4,1} are counted as one) nor reflection ({1,2,3,5,4} and {4,5,3,2,1} are also counted as one), the total number of ways is 5 and therefore T(5,3)=5.
Unfolded table with n individuals (rows) forming k pairs (columns):
    0    1    2    3    4    5    6    7
0   1
1   0    1
2   0    0    1
3   0    0    0    1
4   0    0    2    0    1
5   1    0    5    5    0    1
6   3   12   15   20    9    0   1
7  23   70  112   91   49   14   0   1
		

Crossrefs

Cf. A002816 (column k=0).
Row sums: A001710(n-1) = Sum_k T(n,k).
Cf. also A326390 (accounting for rotation and reflection symmetry), A326397 (disregards reflection symmetry but allows rotation), A326407 (disregards rotation symmetry but allows reflection).
See in addition A002464.

Programs

  • Java
    See Links section
    
  • Maple
    A326411 := proc(n,k)
        option remember;
        if k > n or k < 0 then
            0;
        elif k = n then
            1;
        elif k =0 then
            if n < 5 then
                0 ;
            elif n = 5 then
                1 ;
            elif n = 6 then
                3 ;
            elif n = 7 then
                23 ;
            else
                # Poulet eq (6) page 120, shifted n->n-2
                -(n^3-8*n^2+18*n-21)*procname(n-1,0)
                -4*(n^2-5*n)*procname(n-2,0)
                +2*(n^3-11*n^2+33*n-18)*procname(n-3,0)
                -(n^2-7*n+9)*procname(n-4,0)
                -(n^3-10*n^2+28*n-15)*procname(n-5,0) ;
                -%/(n^2-7*n+9) ;
            end if;
        elif n <= 3 then
            0;
        else
            # Poulet eq (3) page 119
            2*(n-k)*procname(n-1,k-1)/(n-1)+2*k*procname(n-1,k)/(n-1)
                +(k-2)*procname(n-2,k-2)/(n-2) - 2*(k-1)*procname(n-2,k-1)/(n-2) + k*procname(n-2,k)/(n-2) ;
            %*n/k ;
        end if;
    end proc:
    for n from 0 to 12 do
        for k from 0 to n do
            printf("%a ",A326411(n,k)) ;
        end do:
        printf("\n") ;
    end do: # R. J. Mathar, Mar 17 2022
  • Mathematica
    T[n_, k_] := T[n, k] = Which[k > n || k < 0, 0, k == n, 1, k == 0, Which[n<5, 0, n == 5, 1, n == 6, 3, n == 7, 23, True,
        pc = -(n^3 - 8*n^2 + 18*n - 21)*T[n-1, 0]
          - 4*(n^2 - 5*n)*T[n - 2, 0]
          + 2*(n^3 - 11*n^2 + 33*n - 18)*T[n-3, 0]
          - (n^2 - 7*n + 9)*T[n-4, 0]
          - (n^3 - 10*n^2 + 28*n - 15)*T[n-5, 0];
        -pc/(n^2 - 7*n + 9)], n <= 3, 0, True,
       pc = 2*(n-k)*T[n-1, k-1]/(n-1) + 2*k*T[n-1, k]/(n-1) +
         (k - 2)*T[n-2, k-2]/(n-2) -
         2*(k-1)*T[n-2, k-1]/(n-2) + k*T[n-2, k]/(n-2);
        pc*n/k];
    Table[T[n, k], {n, 0, 12}, {k, 0, n}] // Flatten (* Jean-François Alcover, Mar 17 2023, after R. J. Mathar *)
  • PARI
    Q(n,k)={k*subst(serlaplace(polcoef((1 - 2*x -x^2)/((1 + x)*(1 + (1 - y)*x + y*x^2)) + O(x^n), n-1)), y, k)}
    row(n)={Vec(if(n<3, 1, (Q(n,y/(y-1))/2 + (-1)^n)*(y-1)^n), -n-1)} \\ Andrew Howroyd, Mar 01 2024

Formula

It appears that Poulet gives recurrences that generate the whole triangle. - N. J. A. Sloane, Mar 09 2022
T(n,n) = 1;
T(n,n-1) = 0 for n >= 1;
T(n,n-2) = n*(n-3)/2 for n >= 4 [Poulet];
T(n,n-3) = n*(n-4)*(2*n-7)/3 for n >= 4 [Poulet, corrected by N. J. A. Sloane, Mar 09 2022]
T(n,n-4) = (25/24)*n^4 + (23/12)*n^3 - (169/24)*n^2 + (85/12)*n - 3 for n > 5 (conjectured); [see Poulet]
T(n,n-5) = (26/15)*n^5 + (25/6)*n^4 - (83/6)*n^3 + (221/6)*n^2 - (299/10)*n + 13 for n > 5 (conjectured); [see Poulet]
T(n,n-6) = (707/240)*n^6 + (2037/240)*n^5 - (413/16)*n^4 + (2233/16)*n^3 - (2777/15)*n^2 + (3739/20)*n - 57 for n > 6 (conjectured). [See Poulet]

A002493 Number of ways to arrange n non-attacking kings on an n X n board, with 2 sides identified to form a cylinder, with 1 in each row and column.

Original entry on oeis.org

1, 0, 0, 0, 10, 60, 462, 3920, 36954, 382740, 4327510, 53088888, 702756210, 9988248956, 151751644590, 2454798429600, 42130249479562, 764681923900260, 14636063499474054, 294639009867223880
Offset: 1

Views

Author

Keywords

Comments

Number of directed Hamiltonian paths in the complement of C_n where C_n is the n-cycle graph. - Andrew Howroyd, Mar 15 2016
Number of ways of arranging n consecutive integers in a circle such that no pair of adjacent integers differ by 1, rotations are distinct. - Graham Holmes, Sep 03 2020

References

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

Crossrefs

Right diagonal of A338838.

Programs

  • Maple
    b1:= proc(n, r) local gu, x; if r=0 then RETURN(0): fi: gu := (x*diff(x*(1+x)/(1-x),x))* (x*(1 + x)/(1 - x))^(r-1); gu := taylor(gu, x = 0, n +1); coeff(gu, x, n ) end: b:=proc(n) local r: if n=1 then 1 elif n=2 then 0 else add((-1)^(n-r)*r!*b1(n,r),r=0..n): fi: end: # Doron Zeilberger, Nov 14 2007
  • Mathematica
    b[n_]:=(If[n>0, n!+Sum[(-1)^r*(n-r)!*Sum[2^c*Binomial[r-1, c-1]*Binomial[n-r,c], {c, 1, r}], {r, 1, n-1}], 0]); Table[If[n>2, b[n]-2*Sum[b[n-1-2k], {k, 0, Floor[n/2]}], If[n==1, 1, 0]], {n, 1, 25}] (* Vaclav Kotesovec after Vladeta Jovovic, Apr 06 2012 *)

Formula

The linear recurrence operator annihilating this sequence is (N is the shift operator Na(n):=a(n + 1)) is - 3*(43*n + 197)*(n - 2)*(n + 1)/( - 1222 + 753*n + 349*n^2) - 5*(n - 1)*(44*n^2 + 477*n + 1222)/( - 1222 + 753*n + 349*n^2)*N + 2*(n + 1)*(239*n^2 + 873*n - 1232)/( - 1222 + 753*n + 349*n^2)*N^2 + 4*(394 - 259*n + 215*n^2 + 55*n^3)/( - 1222 + 753*n + 349*n^2)*N^3 - ( - 7342 + 3699*n + 2718*n^2 + 349*n^3)/( - 1222 + 753*n + 349*n^2)*N^4 + N^5. - Doron Zeilberger, Nov 14 2007
a(n) = Sum((-1)^(n-k)*k!*A102413(n,k),k=1..n), n>2. - Vladeta Jovovic, Nov 23 2007
a(n) = b(n+1) - 2*Sum_{k=0..floor(n/2)} b(n-2*k) for n>1, where b(n)=A002464(n) if n>0 else b(0)=0. - Vladeta Jovovic, Nov 24 2007
Asymptotic: a(n) ~ n!/e^2*(1 - 2/n - 2/n^2 - 4/(3n^3) + 8/(3n^4) + 326/(15n^5) + 4834/(45n^6) + 154258/(315n^7) + 232564/(105n^8) + ...). - Vaclav Kotesovec, Apr 06 2012
a(n) = n! + Sum_{i=1..n-1} ((-1)^i * (n-i-1)! * n * Sum_{j=0..i-1} (2^(j+1) * C(i-1,j) * C(n-i,j+1))), for n>=5. - Andrew Woods, Jan 08 2015

A231091 Number of distinct (modulo rotation) unicursal star polygons (not necessarily regular, no edge joins adjacent vertices) that can be formed by connecting the vertices of a regular n-gon.

Original entry on oeis.org

0, 0, 0, 0, 1, 1, 5, 27, 175, 1533, 14361, 151575, 1735869, 21594863, 289365383, 4158887007, 63822480809, 1041820050629, 18027531255745, 329658402237171, 6352776451924233, 128686951765990343, 2733851297673484765, 60781108703102022027, 1411481990523638719737
Offset: 1

Views

Author

Stewart Gordon, Nov 03 2013

Keywords

Comments

For polygons in general see A000939 and A000949, and especially the Golomb-Welch reference. - N. J. A. Sloane, Nov 21 2013

Examples

			For n=5, only solution is the regular pentagram.
For n=6, only solution is the unicursal hexagram (see Wikipedia link).
For n=7, two regular heptagrams and three irregular forms are possible.
		

Crossrefs

Cf. A000939 (if edges may join adjacent vertices), A000940, A002816 (rotations and reflections counted separately), A326411, A370459 (up to rotations and reflections), A370068 (directed edges).
Cf. A283184.

Programs

  • PARI
    \\ Requires a370068 from A370068, b(n) is A283184.
    b(n)={subst(serlaplace(polcoef((1 - x)/(1 + (1 - 2*y)*x + 2*y*x^2) + O(x*x^n), n)), y, 1)}
    a(n)={(if(n%2==0 && n > 2, b(n/2-1)/2) + a370068(n))/2} \\ Andrew Howroyd, Mar 01 2024

Formula

a(n) = (A370068(n) + A283184(n/2-1)/2)/2 for even n >= 4; a(n) = A370068(n)/2 for odd n. - Andrew Howroyd, Feb 24 2024

Extensions

a(15) onwards from Andrew Howroyd, Feb 23 2024

A078603 Number of ways of arranging the numbers 1..n in a circle so that adjacent numbers do not differ by 1 mod n.

Original entry on oeis.org

1, 0, 0, 0, 2, 6, 46, 354, 3106, 29926, 315862, 3628906, 45132474, 604534846, 8680957902, 133082437730, 2169964347282, 37505486702678, 685046187718022, 13186335387855770, 266816610979894058, 5662225862272325550
Offset: 1

Views

Author

N. J. A. Sloane, Dec 11 2002

Keywords

Examples

			a(5) = 2: 1 3 5 2 4, 1 4 2 5 3; a(6) = 6: 1 4 6 2 5 3, 1 5 2 4 6 3, 1 5 3 6 2 4, 1 3 6 4 2 5, 1 4 2 6 3 5, 1 3 5 2 6 4.
		

Crossrefs

Twice A002816.
The sequence n*a(n) is A089222.
See also A078628.

Formula

For n>1, a(n) = 2*A002816(n).

Extensions

The sequence was missing a zero; also added a cross-reference Joel B. Lewis, Jan 28 2010

A370459 Number of unicursal stars with n vertices.

Original entry on oeis.org

0, 0, 1, 1, 5, 19, 112, 828, 7441, 76579, 871225, 10809051, 144730446, 2079635889, 31912025537, 520913578812, 9013780062785, 164829273635749, 3176388519597555, 64343477504391475, 1366925655386979893, 30390554390984325019, 705740995420852895453
Offset: 3

Views

Author

Adam M. Scherlis, Feb 19 2024

Keywords

Comments

A unicursal star is a closed loop formed by diagonals of a regular n-gon.
These are Hamiltonian cycles on the graph complement of the n-cycle.
Allowing polygon diagonals, but not sides, is equivalent to requiring every edge to cross at least one other edge.
These are counted up to rotation and reflection, i.e., modulo dihedral symmetry of the n-gon.
Inspired by a unicursal dodecagram drawn by Gordon FitzGerald (see links).

Examples

			For n=5, there is only the regular pentagram {5/2}.
For n=6, there is only the unicursal hexagram.
For n=7, in addition to the two regular heptagrams {7/2} and {7/3}, there are three nontrivial unicursal heptagrams represented by:
 (0, 2, 4, 1, 6, 3, 5, 0)
 (0, 2, 5, 1, 3, 6, 4, 0)
 (0, 2, 5, 1, 4, 6, 3, 0).
		

Crossrefs

Cf. A000940 (polygon sides allowed).
Cf. A055684 (cases with dihedral symmetry only).
Cf. A002816 (rotations and reflections counted separately).
Cf. A231091 (up to rotations only), A370769 (achiral).

Programs

  • PARI
    \\ Requires a370068 from A370068.
    Ro(n)=-(-1)^n + subst(serlaplace(polcoef(((1 - x)^2)/(2*(1 + x)*(1 + (1 - 2*y)*x + 2*y*x^2)) + O(x*x^n), n)), y, 1)
    Re(n)=subst(serlaplace(polcoef((1 - x - 2*x^2)/(4*(1 + (1 - 2*y)*x + 2*y*x^2)) + O(x*x^n), n)), y, 1)
    a(n)={if(n<3, 0, (if(n%2, 2*Ro(n\2), Re(n/2)) + a370068(n))/4)} \\ Andrew Howroyd, Mar 01 2024

Formula

a(n) = (A231091(n) + A370769(n))/2. - Andrew Howroyd, Mar 06 2024

Extensions

a(14) onwards from Andrew Howroyd, Feb 26 2024
Showing 1-9 of 9 results.