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 12 results. Next

A006852 Step at which n is expelled in Kimberling's puzzle (A035486).

Original entry on oeis.org

1, 25, 2, 4, 3, 22, 6, 8, 10, 5, 32, 83, 44, 14, 7, 66, 169, 11, 49595, 9, 69, 16, 24, 12, 43, 47, 7598, 15, 133, 109, 13, 198, 19, 33, 18, 23, 58, 65, 60, 93167, 68, 17, 1523, 39, 75, 20, 99, 34, 117, 123
Offset: 1

Views

Author

Keywords

References

  • R. K. Guy, Unsolved Problems Number Theory, Sect E35.
  • N. J. A. Sloane and Simon Plouffe, The Encyclopedia of Integer Sequences, Academic Press, 1995 (includes this sequence).

Crossrefs

Cf. A007063.
Cf. A175312. - Enrique Pérez Herrero, Mar 28 2010

Programs

  • Mathematica
    L[n_] := L[n] = (
    i = Floor[(n + 4)/3];
    j = Floor[(2*n + 1)/3];
    While[(i != j), j = Max[2*(i - j), 2*(j - i) - 1]; i++ ];
    Return[i];
    ) A006852[n_] := L[n]
    (* Enrique Pérez Herrero, Mar 28 2010 *)
  • PARI
    A006852(n)=
    {
    my(i,j);
    i=floor((n+4)/3);
    j=floor((2*n+1)/3);
    while((i!=j),
    j=max(2*i-2*j,-1-2*i+2*j);
    i++;
    ); return(i); }
    \\ Enrique Pérez Herrero, Feb 25 2010

Formula

a(n) >= floor((n+4)/3), n is expulsed from the unshuffled zone. - Enrique Pérez Herrero, Feb 25 2010

Extensions

7593 corrected to 7598 by Hans Havermann, July 1998

A007063 Main diagonal of Kimberling's expulsion array (A035486).

Original entry on oeis.org

1, 3, 5, 4, 10, 7, 15, 8, 20, 9, 18, 24, 31, 14, 28, 22, 42, 35, 33, 46, 53, 6, 36, 23, 2, 55, 62, 59, 76, 65, 54, 11, 34, 48, 70, 79, 99, 95, 44, 97, 58, 84, 25, 13, 122, 83, 26, 115, 82, 91, 52, 138, 67, 90, 71, 119, 64, 37, 81, 39, 169, 88, 108, 141, 38, 16, 146, 41, 21
Offset: 1

Views

Author

Keywords

Comments

From Clark Kimberling Aug 05 2022, Oct 24 2022: (Start)
Eight such arrays (including A035486 and A356026) have been coded by Peter J. C. Moses using
R for "right side of expelled (number)",
L for "left side",
I for "inner", i.e., next to expelled, and
O for "outer", i.e., farthest from expelled. For example, the array A035486 (and diagonal A007063) are coded as RILI. For the eight codes see Example and Mathematica. It is conjectured that six of the eight diagonal sequences are permutations of the positive integers. (End)

Examples

			The eight diagonals described in Comments:
A007063 = RILI = (1, 3, 5, 4, 10,  7, 15,  8, 20,  9, 18, 24, 31, 14, ... )
A282348 = ROLO = (1, 3, 5, 2,  8,  9,  4, 10,  7, 20, 12, 24, 14, 23, ... )
A356376 = LORO = (1, 3, 5, 6,  4, 11, 12,  9, 13, 15, 23,  7, 27, 16, ... )
A356026 = LIRI = (1, 3, 5, 7,  4, 12, 10, 17,  6, 22, 15, 19, 24, 33, ... )
A356377 = ROLI = (1, 3, 5, 4,  8,  6, 10, 15,  2,  9, 13, 26, 11, 12, ... )
A356378 = RILO = (1, 3, 5, 2, 10,  9, 15,  8, 20, 19,  7, 21, 31,  6, ... )
A356379 = LORI = (1, 3, 5, 7,  4, 12, 11, 17, 10, 22, 21,  9, 23, 33, ... )
A356380 = LIRO = (1, 3, 5, 6,  4, 11, 13,  2,  7, 14, 24,  9, 10, 31, ... )
		

References

  • D. Gale, Tracking the Automatic Ant: And Other Mathematical Explorations, ch. 5, p. 27. Springer, 1998.
  • R. K. Guy, Unsolved Problems in Number Theory, 3rd ed., Springer, 2004; Section E35, p. 359.
  • N. J. A. Sloane and Simon Plouffe, The Encyclopedia of Integer Sequences, Academic Press, 1995 (includes this sequence).

Crossrefs

Programs

  • Mathematica
    K[i_, j_] := i + j - 1 /; (j >= 2 i - 3);
    K[i_, j_] := K[i - 1, i - j/2 - 1] /; (EvenQ[j] && (j < 2 i - 3));
    K[i_, j_] := K[i - 1, i + (j - 1)/2] /; (OddQ[j] && (j < 2 i - 3));
    A007063[i_] := A007063[i] = K[i, i]; SetAttributes[A007063, Listable] (* Enrique Pérez Herrero, Feb 09 2010 *)
    (* Next program generates the 8 arrays with highlighted diagonal sequences. *)
    len = 1000;
    roli = Join[{{1}},
       NestList[
        Join[#[[Riffle[Range[Length[#], (Length[#] + 3)/2, -1],
             Range[(Length[#] - 1)/2, 1, -1]]]],
          Range[#, # + 2] &[(3 Length[#] + 1)/2]] &, {2, 3, 4}, len]];
    rili = Join[{{1}},
      NestList[Join[#[[Riffle[Range[(Length[#] + 3)/2, Length[#]],
            Range[(Length[#] - 1)/2, 1, -1]]]],
         Range[#, # + 2] &[(3 Length[#] + 1)/2]] &, {2, 3, 4},
       len]];(*A007063*)
    rolo = Join[{{1}},
      NestList[Join[#[[Riffle[Range[Length[#], (Length[#] + 3)/2, -1],
            Range[1, (Length[#] - 1)/2]]]],
         Range[#, # + 2] &[(3 Length[#] + 1)/2]] &, {2, 3, 4},
       len]];(*A282348*)
    rilo = Join[{{1}},
      NestList[Join[#[[Riffle[Range[(Length[#] + 3)/2, Length[#]],
            Range[1, (Length[#] - 1)/2, 1]]]],
         Range[#, # + 2] &[(3 Length[#] + 1)/2]] &, {2, 3, 4}, len]];
    lori = Join[{{1}},
       NestList[
        Join[#[[Riffle[Range[1, (Length[#] - 1)/2],
             Range[(Length[#] + 3)/2, Length[#]]]]],
          Range[#, # + 2] &[(3 Length[#] + 1)/2]] &, {2, 3, 4}, len]];
    liri = Join[{{1}},
      NestList[Join[#[[Riffle[Range[(Length[#] - 1)/2, 1, -1],
            Range[(Length[#] + 3)/2, Length[#]]]]],
         Range[#, # + 2] &[(3 Length[#] + 1)/2]] &, {2, 3, 4},
       len]];(*A356026*)
    loro = Join[{{1}},
      NestList[Join[#[[Riffle[Range[1, (Length[#] - 1)/2],
            Range[Length[#], (Length[#] + 3)/2, -1]]]],
         Range[#, # + 2] &[(3 Length[#] + 1)/2]] &, {2, 3, 4}, len]];
    liro = Join[{{1}},
       NestList[
        Join[#[[Riffle[Range[(Length[#] - 1)/2, 1, -1],
             Range[Length[#], (Length[#] + 3)/2, -1]]]],
          Range[#, # + 2] &[(3 Length[#] + 1)/2]] &, {2, 3, 4}, len]];
    (Map[{#, Take[Flatten[Map[Take[#, {(Length[#] + 1)/2}] &, #]], 200] &[
          ToExpression[#]]} &, {"rolo", "rilo", "roli", "rili", "loro",
        "liro", "lori", "liri"}]) // ColumnForm
    rows = 10; Map[{#,
       Grid[Map[Map[StringPadLeft[ToString[#], 2] &, #] &,
         Take[ToExpression[#], rows]],
        Frame -> {None, None, Map[{#, #} -> True &, Range[rows]]},
        FrameStyle -> Directive[Red]]} &, {"rolo", "rilo", "roli", "rili",
       "loro", "liro", "lori", "liri"}]
    (* Peter J. C. Moses, Oct 24 2022; Clark Kimberling, Oct 24 2022 *)
  • PARI
    K(i,j) = { my(i1,j1);i1=i; j1=j;
    while(j1<(2*i1-3),if(j1%2,j1=i1+((j1-1)/2),j1=i1-((j1+2)/2));i1--;);
    return(i1+j1-1);}
    A007063(i)=K(i,i); \\ Enrique Pérez Herrero, Feb 21 2010

Formula

a(theta(k)) = 3*theta(k)-(k+1), where theta(k) = Sum_{i=0..k-1} 2^floor(i/3). - Enrique Pérez Herrero, Feb 23 2010
From Connor Brown, May 05 2023 to Feb 01 2024: (Start)
14 sets of values which predictably appear within the sequence have been found, 1 by Richard Guy (1992) and 13 by Connor Brown (2023). Below, k is any positive integer unless otherwise specified.
a(3*2^k-3) = 9*2^k - 3*k - 10. (Guy, 1992)
a(5*2^k-3) = 15*2^k - 3*k - 12.
a(4*2^k-3) = 12*2^k - 3*k - 11.
a((20/3)*2^k-(4/3)) = 20*2^k - 3*k - 13 for odd k.
a((16/3)*2^k-(4/3)) = 16*2^k - 3*k - 12 for even k.
a((40/7)*2^k-(3/7)) = (120/7)*2^k - 3*k - (93/7) for k==1 (mod 3).
a((16/5)*2^k-(2/5)) = (48/5)*2^k - 3*k - (46/5) for k==1 (mod 4).
a((12/5)*2^k-(2/5)) = (36/5)*2^k - 3*k - (41/5) for k==0 (mod 4).
a((48/13)*2^k+(8/13)) = (144/13)*2^k - 3*k - (145/13) for k==1 (mod 12).
a((64/13)*2^k+(8/13)) = (192/13)*2^k - 3*k - (158/13) for k==3 (mod 12).
a((80/13)*2^k+(8/13)) = (240/13)*2^k - 3*k - (171/13) for k==8 (mod 12).
a((64/9)*2^k+(7/9)) = (64/3)*2^k - 3*k - (35/3) for k==1 (mod 6).
a((80/9)*2^k+(7/9)) = (80/3)*2^k - 3*k - (38/3) for k==4 (mod 6).
a((64/15)*2^k+(7/15)) = (64/5)*2^k - 3*k - (63/5) for k>4, k==1 (mod 4).
(End)
a(n) <= A175312(n). - Enrique Pérez Herrero, Dec 14 2024

Extensions

More terms from James Sellers, Dec 23 1999

A038807 Future of the smallest-perizeroin komet in Kimberling's expulsion array (A035486).

Original entry on oeis.org

2, 3, 5, 10, 9, 20, 46, 83, 12, 24, 23, 36, 79, 124, 172, 56, 119, 61, 169, 17, 42, 84, 232, 285, 596, 1186, 3190, 6857, 14225, 12495, 30482, 45827, 79090, 144112, 423486, 1087497, 2443796, 628733, 871389, 1199242, 2787410, 7975876
Offset: 0

Views

Author

Keywords

Comments

Could the komet be a planit?

References

  • D. Gale, Mathematical Entertainments: "Careful Card-Shuffling and Cutting Can Create Chaos," The Mathematical Intelligencer, vol. 14, no. 1, 1992, pages 54-56.
  • D. Gale, Tracking the Automatic Ant and Other Mathematical Explorations, A Collection of Mathematical Entertainments Columns from The Mathematical Intelligencer, Springer, 1998.
  • Hans Havermann, Algorithm, #4, 1992, p. 2.

Crossrefs

Programs

  • Mathematica
    K[i_, j_] := i + j - 1 /; (j >= 2 i - 3);
    K[i_, j_] := K[i - 1, i - (j + 2)/2] /; (EvenQ[j] && (j < 2 i - 3));
    K[i_, j_] := K[i - 1, i + (j - 1)/2] /; (OddQ[j] && (j < 2 i - 3));
    K[i_] := K[i] = K[i, i]; SetAttributes[K, Listable];
    A007063[i_] := K[i];
    A038807[1] := 2;
    A038807[n_] := A007063[A038807[n - 1]];
    ReleaseHold[Table[A038807[n], {n, 1, 35}]]
    (* Enrique Pérez Herrero, Jan 11 2023 *)

Formula

a(0) = 2; a(n) = a(n-1)-th term in Kimberling's expulsion array (A007063).

A175312 Maximum value on Lower Shuffle Part of Kimberling's Expulsion Array (A035486).

Original entry on oeis.org

1, 3, 5, 7, 10, 12, 15, 17, 20, 22, 25, 28, 31, 33, 36, 39, 42, 44, 47, 50, 53, 55, 58, 61, 64, 67, 70, 73, 76, 78, 81, 84, 87, 90, 93, 96, 99, 101, 104, 107, 110, 113, 116, 119, 122, 124, 127, 130, 133, 136, 139, 142, 145, 148, 151, 154, 157, 160, 163, 166, 169, 171
Offset: 1

Views

Author

Enrique Pérez Herrero, Mar 28 2010

Keywords

Comments

a(n) is the maximum value on or below diagonal of Kimberling's Expulsion Array; this part could be called the Lower Shuffle.

References

  • D. Gale, Tracking the Automatic Ant: And Other Mathematical Explorations, ch. 5, p. 27. Springer, 1998
  • R. K. Guy, Unsolved Problems Number Theory, Sect E35.

Crossrefs

Programs

  • Mathematica
    (* By direct computation *)
    K[i_, j_] := i + j - 1 /; (j >= 2 i - 3);
    K[i_, j_] := K[i - 1, i - (j + 2)/2] /; (EvenQ[j] && (j < 2 i - 3));
    K[i_, j_] := K[i - 1, i + (j - 1)/2] /; (OddQ[j] && (j < 2 i - 3));
    K[i_] := K[i] = K[i, i]; SetAttributes[K, Listable];
    A175312[n_] := Max[Table[K[n, i], {i, 1, n}]]  (* Enrique Pérez Herrero, Mar 30 2010 *)
    (* By the Formula *)
    \[Lambda][n_] := Floor[Log[2, (n + 2)/3]];
    A175312[n_] := 1 + 3*(n - \[Lambda][n]) - Floor[(n + 2)/(2^\[Lambda][n])] (* Enrique Pérez Herrero, Mar 30 2010 *)
  • PARI
    lambda(n)= floor(log((n + 2)/3)/log(2));
    A175312(n)= 1 + 3*(n - lambda(n)) - floor((n + 2)/(2^lambda(n))); \\ Enrique Pérez Herrero, Mar 30 2010

Formula

a(n) = 1 + 3(n-lambda(n)) - floor((n+2)/2^lambda(n)), lambda(n) = floor(log_2((n+2)/3)).
a(n) >= A007063(n); a(n) = max(K(n,1),K(n,2),...,K(n,n)), where K(i,j) is an element of Kimberling's Array given by A035486.
From Enrique Pérez Herrero, Mar 30 2010: (Start)
a(theta(k)) = A007063(theta(k)), where theta(k) = Sum_{i=0..k-1} 2^floor(i/3).
At these values the maximum in the Lower Shuffle is the diagonal expelled element. (End)

A356379 Main diagonal of the LORI variant of the array A035486; this is one of eight such sequences discussed in A007063.

Original entry on oeis.org

1, 3, 5, 7, 4, 12, 11, 17, 10, 22, 21, 9, 23, 33, 8, 27, 16, 44, 26, 18, 30, 55, 41, 35, 14, 25, 65, 20, 67, 78, 43, 64, 49, 66, 76, 61, 85, 101, 60, 100, 32, 62, 111, 52, 68, 124, 80, 93, 86, 102, 92, 131, 115, 51, 110, 58, 77, 73, 72, 15, 134, 171, 29, 151
Offset: 1

Views

Author

Clark Kimberling, Oct 21 2022

Keywords

Comments

Conjecture: every positive integer except 2 occurs exactly once.

Crossrefs

Programs

  • Mathematica
    lori = Join[{{1}}, NestList[Join[#[[Riffle[Range[1, (Length[#] - 1)/2],
          Range[(Length[#] + 3)/2, Length[#]]]]],
          Range[#, # + 2] &[(3 Length[#] + 1)/2]] &, {2, 3, 4}, 200]];
    s = Map[{#, Take[Flatten[Map[Take[#, {(Length[#] + 1)/2}] &, #]], 150] &[
          ToExpression[#]]} &, {"lori"}];
    Last[First[s]]   (* A356379 *)
    (* Peter J. C. Moses, Jul 26 2022 *)
    (* The next program generates the LORI array. *)
    len = 8; lori = Join[{{1}}, NestList[Join[#[[Riffle[Range[1, (Length[#] - 1)/2],
         Range[(Length[#] + 3)/2, Length[#]]]]],
         Range[#, # + 2] &[(3 Length[#] + 1)/2]] &, {2, 3, 4}, len]];
    Grid[Map[Flatten, Transpose[{#, Range[3 Range[Length[#]] - 1,
           4 (Length[#] - 2) - 1 + Range[Length[#]]]}]] &[lori]]
    (* Peter J. C. Moses, Aug 02 2022 *)

A356377 Main diagonal of the ROLI variant of the array A035486; this is one of eight such sequences discussed in A007063.

Original entry on oeis.org

1, 3, 5, 4, 8, 6, 10, 15, 2, 9, 13, 26, 11, 12, 33, 34, 35, 29, 22, 37, 44, 48, 56, 39, 43, 54, 36, 16, 23, 25, 76, 81, 47, 30, 42, 14, 72, 38, 74, 71, 68, 92, 77, 46, 69, 94, 78, 128, 45, 110, 89, 73, 135, 90, 62, 115, 101, 104, 85, 153, 113, 158, 171, 172
Offset: 1

Views

Author

Clark Kimberling, Oct 21 2022

Keywords

Comments

Conjecture: every positive integer occurs exactly once.

Crossrefs

Programs

  • Mathematica
    len = 8; roli = Join[{{1}}, NestList[Join[#[[Riffle[Range[Length[#], (Length[#] + 3)/2, -1], Range[(Length[#] - 1)/2, 1, -1]]]],
         Range[#, # + 2] &[(3 Length[#] + 1)/2]] &, {2, 3, 4}, 200]];
    s = Map[{#, Take[Flatten[Map[Take[#, {(Length[#] + 1)/2}] &, #]], 150] &[
          ToExpression[#]]} &, {"roli"}];
    Last[First[s]]   (* A356377 *)
    (* Peter J. C. Moses, Jul 26 2022 *)
    (* The next program generates the ROLI array. *)
    len = 8; roli = Join[{{1}}, NestList[Join[#[[Riffle[Range[Length[#], (Length[#] + 3)/2, -1], Range[(Length[#] - 1)/2, 1, -1]]]],
         Range[#, # + 2] &[(3 Length[#] + 1)/2]] &, {2, 3, 4}, len]];
    Grid[Map[Flatten, Transpose[{#, Range[3 Range[Length[#]] - 1,
           4 (Length[#] - 2) - 1 + Range[Length[#]]]}]] &[roli]]
    (* Peter J. C. Moses, Aug 02 2022 *)

A356378 Main diagonal of the RILO variant of the array A035486; this is one of eight such sequences discussed in A007063.

Original entry on oeis.org

1, 3, 5, 2, 10, 9, 15, 8, 20, 19, 7, 21, 31, 6, 25, 14, 42, 24, 16, 28, 53, 39, 33, 12, 23, 63, 18, 65, 76, 41, 62, 47, 64, 74, 59, 83, 99, 58, 98, 30, 60, 109, 50, 66, 122, 78, 91, 84, 100, 90, 129, 113, 49, 108, 56, 75, 71, 70, 13, 132, 169, 27, 149, 43
Offset: 1

Views

Author

Clark Kimberling, Oct 21 2022

Keywords

Comments

Conjecture: every positive integer occurs exactly once.

Crossrefs

Programs

  • Mathematica
    rilo = Join[{{1}}, NestList[Join[#[[Riffle[Range[(Length[#] + 3)/2, Length[#]],          Range[1, (Length[#] - 1)/2, 1]]]], Range[#, # + 2] &[(3 Length[#] + 1)/2]] &, {2, 3, 4}, 200]]; (* A356378 *)
    s = Map[{#, Take[Flatten[Map[Take[#, {(Length[#] + 1)/2}] &, #]], 150] &[
          ToExpression[#]]} &, {"rilo"}];
    Last[First[s]]   (* A356378 *)
    (* Peter J. C. Moses,Jul 26 2022 *)
    (* The next program generates the RILO array. *)
    len = 8; rilo = Join[{{1}}, NestList[Join[#[[Riffle[Range[(Length[#] + 3)/2, Length[#]],
         Range[1, (Length[#] - 1)/2, 1]]]],
         Range[#, # + 2] &[(3 Length[#] + 1)/2]] &, {2, 3, 4}, len]];
    Grid[Map[Flatten, Transpose[{#, Range[3 Range[Length[#]] - 1,
           4 (Length[#] - 2) - 1 + Range[Length[#]]]}]] &[rilo]]
    (* Peter J. C. Moses, Aug 02 2022 *)

A356376 Main diagonal of the LORO variant of the array A035486; this is one of eight such sequences discussed in A007063.

Original entry on oeis.org

1, 3, 5, 6, 4, 11, 12, 9, 13, 15, 23, 7, 27, 16, 24, 25, 34, 36, 19, 14, 50, 41, 10, 40, 60, 32, 43, 35, 26, 20, 38, 63, 79, 81, 57, 44, 74, 80, 65, 72, 107, 28, 53, 93, 76, 66, 114, 56, 129, 55, 119, 47, 103, 125, 85, 39, 45, 141, 106, 77, 98, 137, 109, 33
Offset: 1

Views

Author

Clark Kimberling, Oct 21 2022

Keywords

Comments

Conjecture: every positive integer except 2 occurs exactly once.

Crossrefs

Programs

  • Mathematica
    loro = Join[{{1}}, NestList[Join[#[[Riffle[Range[1, (Length[#] - 1)/2],
          Range[Length[#], (Length[#] + 3)/2, -1]]]],
          Range[#, # + 2] &[(3 Length[#] + 1)/2]] &, {2, 3, 4}, 200]];
    s = Map[{#, Take[Flatten[Map[Take[#, {(Length[#] + 1)/2}] &, #]], 150] &[
          ToExpression[#]]} &, {"loro"}]; u = Last[First[s]]
    (* Peter J. C. Moses, Jul 26 2022 *)
    (* The next program generates the LORO array. *)
    len = 8; loro = Join[{{1}}, NestList[Join[#[[Riffle[Range[1, (Length[#] - 1)/2],
         Range[Length[#], (Length[#] + 3)/2, -1]]]],
         Range[#, # + 2] &[(3 Length[#] + 1)/2]] &, {2, 3, 4}, len]];
    Grid[Map[Flatten, Transpose[{#, Range[3 Range[Length[#]] - 1,
           4 (Length[#] - 2) - 1 + Range[Length[#]]]}]] &[loro]]
    (* Peter J. C. Moses, Aug 02 2022 *)

A356380 Main diagonal of the LIRO variant of the array A035486; this is one of eight such sequences discussed in A007063.

Original entry on oeis.org

1, 3, 5, 6, 4, 11, 13, 2, 7, 14, 24, 9, 10, 31, 35, 33, 27, 23, 38, 42, 46, 54, 37, 44, 52, 34, 17, 21, 26, 77, 79, 45, 28, 40, 12, 70, 36, 72, 69, 66, 90, 75, 47, 67, 95, 76, 126, 43, 108, 87, 74, 133, 88, 60, 116, 99, 102, 86, 151, 111, 156, 169, 173, 171
Offset: 1

Views

Author

Clark Kimberling, Oct 24 2022

Keywords

Comments

Conjecture: every positive integer occurs exactly once.

Crossrefs

Programs

  • Mathematica
    lori = Join[{{1}}, NestList[Join[#[[Riffle[Range[1, (Length[#] - 1)/2],
          Range[(Length[#] + 3)/2, Length[#]]]]],
          Range[#, # + 2] &[(3 Length[#] + 1)/2]] &, {2, 3, 4}, 200]];
    s = Map[{#, Take[Flatten[Map[Take[#, {(Length[#] + 1)/2}] &, #]], 150] &[
          ToExpression[#]]} &, {"lori"}];
    Last[First[s]]   (* A356379 *)
    (* Peter J. C. Moses, Jul 26 2022 *)
    (* The next program generates the LIRO array. *)
    len = 8; liro = Join[{{1}}, NestList[Join[#[[Riffle[Range[(Length[#] - 1)/2, 1, -1],
         Range[Length[#], (Length[#] + 3)/2, -1]]]],
         Range[#, # + 2] &[(3 Length[#] + 1)/2]] &, {2, 3, 4}, len]];
    Grid[Map[Flatten, Transpose[{#, Range[3 Range[Length[#]] - 1,
           4 (Length[#] - 2) - 1 + Range[Length[#]]]}]] &[liro]]
    (* Peter J. C. Moses, Aug 02 2022 *)

A035505 Active part of Kimberling's expulsion array as a triangular array.

Original entry on oeis.org

4, 2, 6, 2, 7, 4, 8, 7, 9, 2, 10, 6, 6, 2, 11, 9, 12, 7, 13, 8, 13, 12, 8, 9, 14, 11, 15, 2, 16, 6, 2, 11, 16, 14, 6, 9, 17, 8, 18, 12, 19, 13, 18, 17, 12, 9, 19, 6, 13, 14, 20, 16, 21, 11, 22, 2, 16, 14, 21, 13, 11, 6, 22, 19, 2, 9, 23, 12, 24, 17, 25, 18, 23, 2, 12, 19, 24, 22, 17, 6
Offset: 1

Views

Author

Keywords

Comments

Active or shuffle part of Kimberling's expulsion array (A035486) is given by the elements K(i,j), where j < 2*i-3. [Enrique Pérez Herrero, Apr 14 2010]

Examples

			4 2; 6 2 7 4; 8 7 9 2 10 6; ...
		

References

  • R. K. Guy, Unsolved Problems Number Theory, Sect. E35.

Crossrefs

Programs

  • Mathematica
    A000194[n_] := Floor[(1 + Sqrt[4 n - 3])/2];
    A074294[n_] := n - 2*Binomial[Floor[1/2 + Sqrt[n]], 2];
    K[i_, j_] := i + j - 1 /; (j >= 2 i - 3);
    K[i_, j_] := K[i - 1, i - (j + 2)/2] /; (EvenQ[j] && (j < 2 i - 3));
    K[i_, j_] := K[i - 1, i + (j - 1)/2] /; (OddQ[j] && (j < 2 i - 3));
    A035505[n_] := K[A000194[n] + 2, A074294[n]]
    (* Enrique Pérez Herrero, Apr 14 2010 *)

Formula

From Enrique Pérez Herrero, Apr 14 2010: (Start)
a(n) = K(A000194(n)+2, A074294(n)), where
K(i,j) = i + j - 1; (j >= 2*i - 3)
K(i,j) = K(i-1, i-(j+2)/2) if j is even and j < 2*i - 3
K(i,j) = K(i-1, i+(j-1)/2); if j is odd and j < 2*i - 3.
(End)

Extensions

More terms from James Sellers, Dec 23 1999
Showing 1-10 of 12 results. Next