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-10 of 11 results. Next

A346197 a(n) is the minimum number of pebbles such that any assignment of those pebbles on K_5 is a next-player winning game in the two-player impartial (n+1,n) pebbling game.

Original entry on oeis.org

7, 15, 21, 27, 33, 39, 47, 53, 59, 67, 73, 79, 87, 93, 99, 107, 113, 119, 127, 133, 139
Offset: 1

Views

Author

Keywords

Comments

For n>0, an (n+1,n) pebbling move involves removing n+1 pebbles from a vertex in a simple graph and placing n pebbles on an adjacent vertex.
A two-player impartial (n+1,n) pebbling game involves two players alternating (n+1,n) pebbling moves. The first player unable to make a move loses.

Examples

			For n=1, a(1)=7 is the least number of pebbles for which every (2,1) game on K_5 is a next-player winning game regardless of assignment.
		

References

  • E. R. Berlekamp, J. H. Conway, and R. K. Guy, Winning Ways for Your Mathematical Plays, Vol. 1, CRC Press, 2001.

Crossrefs

Programs

  • Mathematica
    Do[remove = k + 1; add = k;
    (*Given n and m, list all possible assignments.*)
    alltuples[n_, m_] := IntegerPartitions[m + n, {n}] - 1;
    (*Given an assignment, list all resultant assignments after one pebbling move; only work for n>=3.*)
    pebblemoves[config_] :=  Block[{n, temp},
        n = Length[config];
        temp = Table[config, {i, n (n - 1)}] +
            Permutations[Join[{-remove, add}, Table[0, {i, n - 2}]]];
        temp = Select[temp, Min[#] >= 0 &];
        temp = ReverseSort[DeleteDuplicates[ReverseSort /@ temp]]];
    (*Given n and m, list all assignments that are P-games.*)
    Plist = {};
    plist[n_, m_] :=  Block[{index, tuples},
        While[Length[Plist] < n, index = Length[Plist];
            AppendTo[Plist, {{Join[{1}, Table[0,{i,index}]]}}]];
        Do[AppendTo[Plist[[n]], {}]; tuples = alltuples[n, i];
            Do[If[Not[IntersectingQ[pebblemoves[tuples[[j]]],
                    If[i > (remove - add), Plist[[n, i - (remove - add)]], {}]]],
                AppendTo[Plist[[n, i]], tuples[[j]]]], {j, Length[tuples]}],
        {i, Length[Plist[[n]]] + 1, m}]; Plist[[n, m]]];
    Do[m = 1; While[plist[n, m] != {}, m++]; Print[" k=", k, " m=", m], {n, 5, 5}],
    {k, 1, 21}]

A346401 a(n) is the minimum number of pebbles such that any assignment of those pebbles on a complete graph with n vertices is a next-player winning game in the two-player impartial (3, 2) pebbling game.

Original entry on oeis.org

13, 21, 15, 21, 17, 25, 21, 29, 25, 33, 29, 37, 33, 41, 37, 45, 41, 49, 45, 53, 49, 57
Offset: 3

Views

Author

Keywords

Comments

A (3,2) pebbling move involves removing 3 pebbles from a vertex in a simple graph and placing 2 pebbles on an adjacent vertex.
A two-player impartial (3,2) pebbling game involves two players alternating (3,2) pebbling moves. The first player unable to make a move loses.

Examples

			For n=6, a(6)=21 is the least number of pebbles for which every (3,2) game on K_6 is a next-player winning game regardless of assignment.
For n=7, a(7)=17 is the least number of pebbles for which every (3,2) game on K_7 is a next-player winning game regardless of assignment.
		

References

  • E. R. Berlekamp, J. H. Conway, and R. K. Guy, Winning Ways for Your Mathematical Plays, Vol. 1, CRC Press, 2001.

Crossrefs

Programs

  • Mathematica
    remove = 3; add = 2;
    (*Given n and m,list all possible assignments.*)
    alltuples[n_, m_] := IntegerPartitions[m + n, {n}] - 1;
    (*Given an assignment,list all resultant assignments after one pebbling move; only work for n>=3.*)
    pebblemoves[config_] := Block[{n, temp},
        n = Length[config];
        temp = Table[config, {i, n (n - 1)}] +
            Permutations[Join[{-remove, add}, Table[0, {i, n - 2}]]];
        temp = Select[temp, Min[#] >= 0 &];
        temp = ReverseSort[DeleteDuplicates[ReverseSort /@ temp]]];
    (*Given n and m,list all assignments that are P-games.*)
    Plist = {};
    plist[n_, m_] :=  Block[{index, tuples},
        While[Length[Plist] < n, index = Length[Plist];
            AppendTo[Plist, {{Join[{1}, Table[0, {i, index}]]}}]];
        Do[AppendTo[Plist[[n]], {}]; tuples = alltuples[n, i];
            Do[If[Not[IntersectingQ[pebblemoves[tuples[[j]]],
                    If[i > (remove - add), Plist[[n, i - (remove - add)]], {}]]],
                AppendTo[Plist[[n, i]], tuples[[j]]]], {j, Length[tuples]}],
        {i, Length[Plist[[n]]] + 1, m}]; Plist[[n, m]]];
    Do[m = 1; While[plist[n, m] != {}, m++]; Print[" n=", n, " m=", m], {n, 3, 24}]

Formula

a(n) = 2n+3 when n >= 7 is odd (conjectured).
a(n) = 2n+9 when n >= 6 is even (conjectured).

A342561 List points (x,y,z) having integer coordinates, sorted first by R^2 = x^2 + y^2 + z^2 and in case of ties, then by z and last by polar angle 0 <= phi < 2*Pi in a polar coordinate system. Sequence gives x-coordinates.

Original entry on oeis.org

0, 0, 1, 0, -1, 0, 0, 1, 0, -1, 0, 1, -1, -1, 1, 1, 0, -1, 0, 1, -1, -1, 1, 1, -1, -1, 1, 0, 2, 0, -2, 0, 0, 1, 0, -1, 0, 2, 0, -2, 0, 2, 1, -1, -2, -2, -1, 1, 2, 2, 0, -2, 0, 1, 0, -1, 0, 1, -1, -1, 1, 2, 1, -1, -2, -2, -1, 1, 2, 2, 1, -1, -2, -2, -1, 1, 2, 1, -1, -1, 1, 2, 0, -2, 0, 2, -2, -2, 2, 2, 0, -2, 0
Offset: 0

Views

Author

Hugo Pfoertner, Apr 27 2021

Keywords

Comments

This is a 3-dimensional generalization of A305575 and A305576.
y-coordinates are in A342562, z-coordinates are in A342563.
These lists can be read as an irregular table, where row r lists the respective coordinates of the points on the sphere with radius R = sqrt(r); their number (i.e., the row length) is given by A005875 = (1, 6, 12, 8, 6, 24, 24, 0, 12, 30, ...). - M. F. Hasler, Apr 27 2021

Examples

			   n    x    y    z  R^2  phi/Pi
   0    0    0    0   0   0.000
   1    0    0   -1   1   0.000
   2    1    0    0   1   0.000
   3    0    1    0   1   0.500
   4   -1    0    0   1   1.000
   5    0   -1    0   1   1.500
   6    0    0    1   1   0.000
   7    1    0   -1   2   0.000
   8    0    1   -1   2   0.500
   9   -1    0   -1   2   1.000
  10    0   -1   -1   2   1.500
  11    1    1    0   2   0.250
  12   -1    1    0   2   0.750
  13   -1   -1    0   2   1.250
  14    1   -1    0   2   1.750
  15    1    0    1   2   0.000
  16    0    1    1   2   0.500
  17   -1    0    1   2   1.000
  18    0   -1    1   2   1.500
  19    1    1   -1   3   0.250
  20   -1    1   -1   3   0.750
  21   -1   -1   -1   3   1.250
  22    1   -1   -1   3   1.750
  23    1    1    1   3   0.250
  24   -1    1    1   3   0.750
  25   -1   -1    1   3   1.250
  26    1   -1    1   3   1.750
  27    0    0   -2   4   0.000
  28    2    0    0   4   0.000
  29    0    2    0   4   0.500
		

Crossrefs

Cf. A343630, A340631, A340632, A343633 for a variant which "connects" corresponding poles of successive shells, A343640, A340641, A340642, A343643 for a square spiral variant.

Programs

  • PARI
    shell(n, Q=Qfb(1,0,1), L=List())={for(z=if(n, sqrtint((n-1)\3)+1), sqrtint(n), my(S=if(n>z^2, Set(apply(vecsort, abs(qfbsolve(Q, n-z^2, 3)))), [[0,0]])); foreach(S, s, forperm(concat(s,z), p, listput(L, p)))); for(i=1,3, for(j=1,#L, my(X=L[j]); (X[i]*=-1) && listput(L,X))); vecsort(L, (p,q)->if( p[3]!=q[3], p[3]-q[3], p[1]==q[1], q[2]-p[2], p[2]*q[2]<0, q[2]-p[2], (q[1]-p[1])*(p[2]+q[2])))} \\ Gives list of all points with Euclidean norm sqrt(n).
    A342561_vec=concat([[P[1] | P <- shell(n)] | n<-[0..7]]) \\ M. F. Hasler, Apr 27 2021

A361517 The value of n for which the two-player impartial {0,1}-Toggle game on a generalized Petersen graph GP(n,2) with a (1,0)-weight assignment is a next-player winning game.

Original entry on oeis.org

3, 4, 5, 11, 17, 27, 35, 37, 49, 59, 69, 81, 91, 103, 115, 123, 135, 137, 167, 175, 189, 199, 207, 287, 295, 307, 361, 1051, 2507, 2757, 2917, 3057, 3081, 7255, 7361, 7871, 16173
Offset: 3

Views

Author

Keywords

Comments

The two-player impartial {0,1}-Toggle game is played on a simple connected graph G where each vertex is assigned an initial weight of 0 or 1.
A Toggle move consists of selecting a vertex v and switching its weight as well as the weights of each of its neighbors. This move is only legal provided the weight of vertex v is 1 and the total sum of the vertex weights decreases.
In the special case G=GP(n,2), a (1,0)-weight assignment is one in which each vertex of the outer polygon is assigned weight 1 and each vertex of the inner polygon(s) is assigned weight 0.

Examples

			For n = 3, the {0,1}-Toggle game on GP(3,2) with a (1,0)-weight assignment is a next-player winning game.
For n = 5, the {0,1}-Toggle game on GP(5,2) with a (1,0)-weight assignment is a next-player winning game.
		

References

  • E. R. Berlekamp, J. H. Conway, and R. K. Guy, Winning Ways for Your Mathematical Plays, Vol. 1, CRC Press, 2001.

Crossrefs

Programs

  • CGSuite
    # See Levandosky link

A374810 Values k such that the two-player impartial {0,1}-Toggle game on a path P(k+2) = v(1)v(2)...v(k+2) with a (1^k,0,1)-weight assignment is a second-player winning game.

Original entry on oeis.org

1, 6, 7, 12, 13, 18, 23, 24, 38, 39, 44, 45, 50, 51, 56, 62, 77, 115, 121, 153, 312, 333, 350, 427, 553, 554, 579
Offset: 1

Views

Author

Keywords

Comments

The two-player impartial {0,1}-Toggle game is played on a simple connected graph G where each vertex is assigned an initial weight of 0 or 1.
A Toggle move consists of selecting a vertex v and switching its weight as well as the weight of each of its neighbors. This move is legal only provided the weight of vertex v is 1 and the total sum of the vertex weights decreases.
In the special case G = P(k+2), a (1^k, 0, 1)-weight assignment is one in which vertex v(k+1) is assigned weight 0 and all remaining vertices are assigned weight 1.

Examples

			For n = 6, the {0,1}-Toggle game on P(8) with a (1,1,1,1,1,1,0,1)-weight assignment is a second-player winning game.
For n = 12, the {0,1}-Toggle game on P(14) with a (1,1,1,1,1,1,1,1,1,1,1,1,0,1)-weight assignment is a second-player winning game.
		

References

  • E. R. Berlekamp, J. H. Conway, and R. K. Guy, Winning Ways for Your Mathematical Plays, Vol. 1, CRC Press, 2001.

Crossrefs

Programs

  • Python
    # See Cohen link.

A374910 Values k such that the two-player impartial {0,1}-Toggle game on a path P(k+4) = v(1)v(2)...v(k+4) with a (1^k,0,1,0,1)-weight assignment is a second-player winning game.

Original entry on oeis.org

1, 25, 26, 31, 32, 37, 38, 63, 64, 69, 70, 76, 101, 102, 139, 145, 177, 189, 215, 235, 252, 253, 267, 284, 290, 305, 311, 328, 360, 668
Offset: 1

Views

Author

Keywords

Comments

The two-player impartial {0,1}-Toggle game is played on a simple connected graph G where each vertex is assigned an initial weight of 0 or 1.
A Toggle move consists of selecting a vertex v and switching its weight as well as the weight of each of its neighbors. This move is only legal provided the weight of vertex v is 1 and the total sum of the vertex weights decreases.
In the special case G=P(k+4), a (1^k,0,1,0,1)-weight assignment is one in which vertices v(k+1) and v(k+3) are assigned weight 0 and all remaining vertices are assigned weight 1.
The path P(k+4m) where vertices v(k+1), v(k+3), ..., v(k+4m-1) are assigned weight 0 and all remaining vertices are assigned weight 1 will have the same Grundy numbers as G.

References

  • E. R. Berlekamp, J. H. Conway, and R. K. Guy, Winning Ways for Your Mathematical Plays, Vol. 1, CRC Press, 2001.

Crossrefs

Programs

  • Python
    # See Cohen link.

A374920 Values k such that the two-player impartial {0,1}-Toggle game on a path P(k+6) = v(1)v(2)...v(k+6) with a (1^k,0,1,0,1,0,1)-weight assignment is a second-player winning game.

Original entry on oeis.org

1, 6, 7, 12, 13, 18, 23, 24, 39, 44, 45, 50, 51, 57, 62, 77, 115, 281, 319, 350, 389
Offset: 1

Views

Author

Keywords

Comments

The two-player impartial {0,1}-Toggle game is played on a simple connected graph G where each vertex is assigned an initial weight of 0 or 1.
A Toggle move consists of selecting a vertex v and switching its weight as well as the weight of each of its neighbors. This move is only legal provided the weight of vertex v is 1 and the total sum of the vertex weights decreases.
In the special case G=P(k+6), a (1^k,0,1,0,1,0,1)-weight assignment is one in which vertices v(k+1), v(k+3), and v(k+5) are assigned weight 0 and all remaining vertices are assigned weight 1.
The path P(k+4m+2) where vertices v(k+1), v(k+3), ..., v(k+4m+1) are assigned weight 0 and all remaining vertices are assigned weight 1 will have the same Grundy numbers as G.

References

  • E. R. Berlekamp, J. H. Conway, and R. K. Guy, Winning Ways for Your Mathematical Plays, Vol. 1, CRC Press, 2001.

Crossrefs

Programs

  • Python
    # See Cohen link.

A347637 Table read by ascending antidiagonals. T(n, k) is the minimum number of pebbles such that any assignment of those pebbles on a complete graph with n vertices is a next-player winning game in the two-player impartial (k+1, k) pebbling game. T(n, k) for n >= 5 and k >= 1.

Original entry on oeis.org

7, 13, 15, 9, 21, 21, 15, 17, 35, 27, 11, 25, 25, 37, 33, 17, 21, 41, 33, 59, 39, 13, 29, 31, 45, 41, 53
Offset: 5

Views

Author

Keywords

Comments

A (k+1, k) pebbling move involves removing k + 1 pebbles from a vertex in a simple graph and placing k pebbles on an adjacent vertex.
A two-player impartial (k+1, k) pebbling game involves two players alternating (k+1, k) pebbling moves. The first player unable to make a move loses.
T(3, k) = A016921(k) for k >= 0. The proof will appear in a paper that is currently in preparation.
It is conjectured that T(4, k) for odd k>=3 is infinite, so we start with n = 5.
T(5, k) = A346197(k) for k >= 1.
T(n, 1) = A340631(n) for n >= 3.
T(n, 2) = A346401(n) for n >= 3.

Examples

			The data is organized in a table beginning with row n = 5 and column k = 1. The data is read by ascending antidiagonals. The formula binomial(n + k - 5, 2) + k converts the indices from table form to sequence form.
The table T(n, k) begins:
  [n/k]  1   2   3   4   5   6  ...
  ---------------------------------
  [ 5]   7, 15, 21, 27, 33, 39, ...
  [ 6]  13, 21, 35, 37, 59, 53, ...
  [ 7]   9, 17, 25, 33, 41, 51, ...
  [ 8]  15, 25, 41, 45, 61, ...
  [ 9]  11, 21, 31, 41, 51, ...
  [10]  17, 29, 45, 53, 71, ...
  [11]  13, 25, 37, 49, 61, ...
  [12]  19, 33, 51, ...
  [13]  15, 29, 43, ...
  [14]  21, 37, ...
  [15]  17, 33, ...
  [16]  23, 41, ...
		

References

  • E. R. Berlekamp, J. H. Conway, and R. K. Guy, Winning Ways for Your Mathematical Plays, Vol. 1, CRC Press, 2001.

Crossrefs

Programs

  • Mathematica
    (* m represents number of vertices in the complete graph. Each pebbling move removes k+1 pebbles from a vertex and adds k pebbles to an adjacent vertex. *)
    Do[(* Given m and a, list all possible assignments with a pebbles. *)
    alltuples[m_, a_] := IntegerPartitions[a + m, {m}] - 1;
    (* Given an assignment, list all resultant assignments after one pebbling move; only works for m>=3. *)
    pebblemoves[config_] :=
      Block[{m, temp}, m = Length[config];
       temp = Table[config, {i, m (m - 1)}] +
         Permutations[Join[{-(k + 1), k}, Table[0, {i, m - 2}]]];
       temp = Select[temp, Min[#] >= 0 &];
       temp = ReverseSort[DeleteDuplicates[ReverseSort /@ temp]]];
    (* Given m and a, list all assignments that are P-games. *)
    Plist = {};
    plist[m_, a_] :=
      Block[{index, tuples},
       While[Length[Plist] < m, index = Length[Plist];
        AppendTo[Plist, {{Join[{1}, Table[0, {i, index}]]}}]];
       Do[AppendTo[Plist[[m]], {}]; tuples = alltuples[m, i];
        Do[If[
          Not[IntersectingQ[pebblemoves[tuples[[j]]],
            If[i > 2, Plist[[m, i - 1]], {}]]],
          AppendTo[Plist[[m, i]], tuples[[j]]]], {j, Length[tuples]}], {i,
          Length[Plist[[m]]] + 1, a}]; Plist[[m, a]]];
    (* Given m, print out the minimum a such that there are no P-games with a pebbles *)
    Do[a = 1; While[plist[m, a] != {}, a++];
      Print["k=", k, " m=", m, " a=", a], {m, 5, 10}], {k, 1, 6}]

A363893 Number of weakly connected components of an addsub configuration graph with respect to integers mod n over a path with two vertices.

Original entry on oeis.org

1, 2, 1, 4, 2, 3, 1, 5, 4, 4, 2, 6, 3, 11, 1, 11, 5, 6, 4, 12, 4, 7, 2, 13, 6, 14, 3, 10, 11, 25, 1, 29, 11, 18, 5, 12, 6, 21, 4, 25, 12, 34, 4, 32, 7, 13, 2, 17, 13, 48, 6, 16, 14, 25, 3, 47, 10, 16, 11, 18, 25, 87, 1, 95, 29, 18, 11, 32, 18, 19, 5
Offset: 2

Views

Author

Keywords

Comments

The addsub game is played on a path with two vertices {u,v}. We define a configuration of the integers mod n on {u,v} by assigning weights wt(u) and wt(v).
An addsub move from u to v is a reassignment of weights given by wt(u) -> wt(u) - wt(v) (mod n) and wt(v) -> wt(u) + wt(v) (mod n). An addsub move from v to u is defined analogously.
The addsub configuration graph with respect to the integers mod n over {u,v} is the directed graph in which each node corresponds to a configuration (wt(u),wt(v)) and a directed edge from a configuration to the resulting configuration is attainable via a single addsub move.

Examples

			For n=3, the (u,v) sequence of addsub moves forms the directed cycle (0,1)->(2,1)->(1,0)->(1,1)->(0,2)->(1,2)->(2,0)->(2,2)->(0,1). The (v,u) sequence of addsub moves forms the directed cycle (0,1)->(1,1)->(2,0)->(2,1)->(0,2)->(2,2)->(1,0)->(1,2)->(0,1). These two directed cycles form one weakly connected component. The isolated vertex (0,0) is a loop and forms the second weakly connected component. Therefore, a(3)=2.
		

References

  • E. R. Berlekamp, J. H. Conway, and R. K. Guy, Winning Ways for Your Mathematical Plays, Vol. 1, CRC Press, 2001.

Crossrefs

Programs

  • Mathematica
    Upto=25;
    Table[
      VertexSet:={};
      EdgeSet:={};
      (* Compute configuration graph for integers mod n *)
      Do[
        Do[AppendTo[VertexSet,{i,j}];
          AppendTo[EdgeSet,{i,j}\[DirectedEdge]{Mod[i-j,n],Mod[i+j,n]}];
          AppendTo[EdgeSet,{i,j}\[DirectedEdge]{Mod[j+i,n],Mod[j-i,n]}],
          {j,0,n-1}],
        {i,0,n-1}];
      (* Print n-th term *)
      Length[WeaklyConnectedComponents[Graph[VertexSet,EdgeSet]]],
      {n,2,Upto}]

A361315 a(n) is the minimum number of pebbles such that any assignment of those pebbles on a complete graph with n vertices is a next-player winning game in the two-player impartial (3;1,1) pebbling game.

Original entry on oeis.org

31, 26, 19, 17, 17, 19, 21, 23, 25, 27, 29, 31, 33, 35, 37, 39, 41
Offset: 4

Views

Author

Gabrielle Demchak, Eugene Fiorini, Michael J. Herrera, Samuel Murray, Rhaldni Sayaman, Brittany Shelton and Wing Hong Tony Wong, Mar 14 2023

Keywords

Comments

A (3;1,1) move in an impartial two-player pebbling game consists of removing three pebbles from a vertex and adding a pebble to each of two distinct adjacent vertices. The winning player is the one who makes the final allowable move. We start at n = 4 because we have shown that a(3) does not exist while a(2) is clearly undefined.

Examples

			For n = 4, a(4) = 31 is the least number of pebbles for which every game is a next-player winning game regardless of assignment.
		

References

  • E. R. Berlekamp, J. H. Conway, and R. K. Guy, Winning Ways for Your Mathematical Plays, Vol. 1, CRC Press, 2001.

Crossrefs

Programs

  • Mathematica
    (*Given n and m, list all possible assignments.*)alltuples[n_, m_] := IntegerPartitions[m + n, {n}] - 1;
    (*Given an assignment, list all resultant assignments after one (3;1,1)-pebbling move; only work for n>=3.*)
    pebblemoves[config_] :=  Block[{n, temp}, n = Length[config];   temp = Table[config, {i, n (n - 1) (n - 2)/2}] +     Permutations[Join[{-3, 1, 1}, Table[0, {i, n - 3}]]];   temp = Select[temp, Min[#] >= 0 &];   temp = ReverseSort[DeleteDuplicates[ReverseSort /@ temp]]];
    (*Given n and m, list all assignments that are P-games.*)
    Plist = {};plist[n_, m_] :=  Block[{index, tuples},   While[Length[Plist] < n, index = Length[Plist];    AppendTo[Plist, {{Join[{1}, Table[0, {i, index}]]}}]];   Do[AppendTo[Plist[[n]], {}]; tuples = alltuples[n, i];    Do[If[Not[       IntersectingQ[pebblemoves[tuples[[j]]],        Plist[[n, i - 1]]]],      AppendTo[Plist[[n, i]], tuples[[j]]]], {j, Length[tuples]}], {i,      Length[Plist[[n]]] + 1, m}]; Plist[[n, m]]];
    (*Given n, print out the minimum m such that there are no P-games with m pebbles*)Do[m = 1; While[plist[n, m] != {}, m++];
     Print["n=", n, " m=", m], {n, 4, 20}]
Showing 1-10 of 11 results. Next