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.

Previous Showing 11-20 of 21 results. Next

A136119 Limiting sequence when we start with the positive integers (A000027) and delete in step n >= 1 the term at position n + a(n).

Original entry on oeis.org

1, 3, 4, 5, 7, 8, 10, 11, 13, 14, 15, 17, 18, 20, 21, 22, 24, 25, 27, 28, 29, 31, 32, 34, 35, 37, 38, 39, 41, 42, 44, 45, 46, 48, 49, 51, 52, 54, 55, 56, 58, 59, 61, 62, 63, 65, 66, 68, 69, 71, 72, 73, 75, 76, 78, 79, 80, 82, 83, 85, 86, 87, 89, 90, 92, 93, 95, 96, 97, 99, 100
Offset: 1

Views

Author

Ctibor O. Zizka, Mar 16 2008

Keywords

Comments

Apparently a(n) = A001953(n-1)+1 = floor((n-1/2)*sqrt(2))+1 (confirmed for n < 20000) and a(n+1) - a(n) = A001030(n). From the definitions these conjectures are by no means obvious. Can they be proved? - Klaus Brockhaus, Apr 15 2008 [For an affirmative answer, see the Cloitre link.]
This is the s(n)-Wythoff sequence for s(n)=2n-1; see A184117 for the definition. Complement of A184119. - Clark Kimberling, Jan 09 2011

Examples

			First few steps are:
1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,...
n = 1; delete term at position 1+a(1) = 2: 2;
1,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,...
n = 2; delete term at position 2+a(2) = 5: 6;
1,3,4,5,7,8,9,10,11,12,13,14,15,16,17,18,19,20,...
n = 3; delete term at position 3+a(3) = 7: 9;
1,3,4,5,7,8,10,11,12,13,14,15,16,17,18,19,20,...
n = 4; delete term at position 4+a(4) = 9: 12;
1,3,4,5,7,8,10,11,13,14,15,16,17,18,19,20,...
n = 5; delete term at position 5+a(5) = 12: 16;
1,3,4,5,7,8,10,11,13,14,15,17,18,19,20,...
n = 6; delete term at position 6+a(6) = 14: 19;
1,3,4,5,7,8,10,11,13,14,15,17,18,20,...
		

References

  • B. Cloitre, The golden sieve, preprint 2008

Crossrefs

Cf. A000027, A001953 (floor((n+1/2)*sqrt(2))), A001030 (fixed under 1 -> 21, 2 -> 211), A136110, A137292.
Cf. A242535.
Cf. A000217 (T).

Programs

  • Haskell
    import Data.List (delete)
    a136119 n = a136119_list !! (n-1)
    a136119_list = f [1..] where
       f zs@(y:xs) = y : f (delete (zs !! y) xs)
    -- Reinhard Zumkeller, May 17 2014
    
  • Magma
    [Ceiling((n-1/2)*Sqrt(2)): n in [1..100]]; // Vincenzo Librandi, Jul 01 2019
    
  • Mathematica
    f[0] = Range[100]; f[n_] := f[n] = Module[{pos = n + f[n-1][[n]]}, If[pos > Length[f[n-1]], f[n-1], Delete[f[n-1], pos]]]; f[1]; f[n = 2]; While[f[n] != f[n-1], n++]; f[n] (* Jean-François Alcover, May 08 2019 *)
    T[n_] := n (n + 1)/2; Table[1 + 2 Sqrt[T[n-1]] , {n, 1, 71}] // Floor (* Ralf Steiner, Oct 23 2019 *)
  • PARI
    apply( {A136119(n)=sqrtint(n*(n-1)*2)+1}, [1..99]) \\ M. F. Hasler, Jul 04 2022

Formula

a(n) = ceiling((n-1/2)*sqrt(2)). This can be proved in the same way as the formula given for A099267. There are some generalizations. For instance, it is possible to consider "a(n)+K*n" instead of "a(n)+n" for deleting terms where K=0,1,2,... is fixed. The constant involved in the Beatty sequence for the sequence of deleted terms then depends on K and equals (K + 1 + sqrt((K+1)^2 + 4))/2. K=0 is related to A099267. 1+A001954 is the complement sequence of this sequence A136119. - Benoit Cloitre, Apr 18 2008
a(n) = floor(1 + 2*sqrt(T(n-1))), with triangular numbers T(). - Ralf Steiner, Oct 23 2019
Lim_{n->inf}(a(n)/(n - 1)) = sqrt(2), with {a(n)/(n - 1)} decreasing. - Ralf Steiner, Oct 24 2019

Extensions

Edited and extended by Klaus Brockhaus, Apr 15 2008
An incorrect g.f. removed by Alois P. Heinz, Dec 14 2012

A004641 Fixed under 0 -> 10, 1 -> 100.

Original entry on oeis.org

1, 0, 0, 1, 0, 1, 0, 1, 0, 0, 1, 0, 1, 0, 0, 1, 0, 1, 0, 0, 1, 0, 1, 0, 1, 0, 0, 1, 0, 1, 0, 0, 1, 0, 1, 0, 1, 0, 0, 1, 0, 1, 0, 0, 1, 0, 1, 0, 1, 0, 0, 1, 0, 1, 0, 0, 1, 0, 1, 0, 0, 1, 0, 1, 0, 1, 0, 0, 1, 0, 1, 0, 0, 1, 0, 1, 0, 1, 0, 0, 1, 0, 1, 0, 0, 1, 0, 1, 0, 0, 1, 0, 1
Offset: 1

Views

Author

Keywords

Comments

Partial sums: A088462. - Reinhard Zumkeller, Dec 05 2009
Write w(n) = a(n) for n >= 1. Each w(n) is generated by w(i) for exactly one i <= n; let g(n) = i. Each w(i) generates a single 1, in a word (10 or 100) that starts with 1. Therefore, g(n) is the number of 1s among w(1), ..., w(n), so that g = A088462. That is, this sequence is generated by its partial sums. - Clark Kimberling, May 25 2011

Crossrefs

Equals A001030 - 1. Essentially the same as A006337 - 1 and A159684.
Characteristic function of A086377.
Cf. A081477.
The following sequences are all essentially the same, in the sense that they are simple transformations of each other, with A000201 as the parent: A000201, A001030, A001468, A001950, A003622, A003842, A003849, A004641, A005614, A014675, A022342, A088462, A096270, A114986, A124841. - N. J. A. Sloane, Mar 11 2021

Programs

  • Magma
    [Floor(n*(Sqrt(2) - 1) + Sqrt(1/2)) - Floor((n - 1)*(Sqrt(2) - 1) + Sqrt(1/2)): n in [0..100]]; // Vincenzo Librandi, Mar 27 2015
    
  • Maple
    P(0):= (1,0): P(1):= (1,0,0):
    ((P~)@@6)([1]);
    # in Maple 12 or earlier, comment the above line and uncomment the following:
    # (curry(map,P)@@6)([1]); # Robert Israel, Mar 26 2015
  • Mathematica
    Nest[ Flatten[# /. {0 -> {1, 0}, 1 -> {1, 0, 0}}] &, {1}, 5] (* Robert G. Wilson v, May 25 2011 *)
    SubstitutionSystem[{0->{1,0},1->{1,0,0}},{1},5]//Flatten (* Harvey P. Dale, Nov 20 2021 *)
  • Python
    from math import isqrt
    def A004641(n): return [1, 0, 0, 1, 0, 1, 0, 1][n-1] if n < 9 else -1-isqrt(m:=(n-9)*(n-9)<<1)+isqrt(m+(n-9<<2)+2) # Chai Wah Wu, Aug 25 2022

Formula

a(n) = floor(n*(sqrt(2) - 1) + sqrt(1/2)) - floor((n - 1)*(sqrt(2) - 1) + sqrt(1/2)) (from the de Bruijn reference). - Peter J. Taylor, Mar 26 2015
From Jianing Song, Jan 02 2019: (Start)
a(n) = A001030(n) - 1.
a(n) = A006337(n-9) - 1 = A159684(n-10) for n >= 10. (End)

A088462 a(1)=1, a(n) = ceiling((n - a(a(n-1)))/2).

Original entry on oeis.org

1, 1, 1, 2, 2, 3, 3, 4, 4, 4, 5, 5, 6, 6, 6, 7, 7, 8, 8, 8, 9, 9, 10, 10, 11, 11, 11, 12, 12, 13, 13, 13, 14, 14, 15, 15, 16, 16, 16, 17, 17, 18, 18, 18, 19, 19, 20, 20, 21, 21, 21, 22, 22, 23, 23, 23, 24, 24, 25, 25, 25, 26, 26, 27, 27, 28, 28, 28, 29, 29, 30, 30, 30, 31, 31, 32, 32
Offset: 1

Views

Author

Benoit Cloitre, Nov 12 2003

Keywords

Comments

Partial sums of A004641. - Reinhard Zumkeller, Dec 05 2009
This sequence generates A004641; see comment at A004641. - Clark Kimberling, May 25 2011

Crossrefs

Cf. A005206.
The following sequences are all essentially the same, in the sense that they are simple transformations of each other, with A000201 as the parent: A000201, A001030, A001468, A001950, A003622, A003842, A003849, A004641, A005614, A014675, A022342, A088462, A096270, A114986, A124841. - N. J. A. Sloane, Mar 11 2021

Programs

  • Magma
    [Floor((Sqrt(2)-1)*n+1/Sqrt(2)): n in [1..100]]; // Vincenzo Librandi, Jun 26 2017
  • Mathematica
    Table[Floor[(Sqrt[2] - 1) n + 1 / Sqrt[2]], {n, 100}] (* Vincenzo Librandi, Jun 26 2017 *)
  • Python
    l=[0, 1, 1]
    for n in range(3, 101): l.append(n - l[n - 1] - l[l[n - 2]])
    print(l[1:]) # Indranil Ghosh, Jun 24 2017, after Altug Alkan
    

Formula

a(n) = floor((sqrt(2)-1)*n + 1/sqrt(2)).
a(1) = a(2) = 1; a(n) = n - a(n-1) - a(a(n-2)) for n > 2. - Altug Alkan, Jun 24 2017

A114986 Characteristic function of (A000201 prefixed with 0).

Original entry on oeis.org

1, 1, 0, 1, 1, 0, 1, 0, 1, 1, 0, 1, 1, 0, 1, 0, 1, 1, 0, 1, 0, 1, 1, 0, 1, 1, 0, 1, 0, 1, 1, 0, 1, 1, 0, 1, 0, 1, 1, 0, 1, 0, 1, 1, 0, 1, 1, 0, 1, 0, 1, 1, 0, 1, 0, 1, 1, 0, 1, 1, 0, 1, 0, 1, 1, 0, 1, 1, 0, 1, 0, 1, 1, 0, 1, 0, 1, 1, 0, 1, 1, 0, 1, 0, 1, 1, 0, 1, 1, 0, 1, 0, 1, 1, 0, 1, 0, 1, 1, 0, 1, 1, 0, 1, 0
Offset: 0

Views

Author

N. J. A. Sloane, Feb 28 2006

Keywords

Crossrefs

Essentially the same as A005614. Cf. A096270, A189479.
The following sequences are all essentially the same, in the sense that they are simple transformations of each other, with A000201 as the parent: A000201, A001030, A001468, A001950, A003622, A003842, A003849, A004641, A005614, A014675, A022342, A088462, A096270, A114986, A124841. - N. J. A. Sloane, Mar 11 2021

A124841 Inverse binomial transform of A005614, the rabbit sequence: (1, 0, 1, 1, 0, ...).

Original entry on oeis.org

1, -1, 2, -3, 3, 0, -10, 35, -90, 200, -400, 726, -1188, 1716, -2080, 1820, -312, -2704, 5408, 455, -39195, 170313, -523029, 1352078, -3114774, 6548074, -12668578, 22492886, -36020998, 49549110, -49549110, 0, 182029056, -670853984, 1809734560, -4242470755
Offset: 0

Views

Author

Gary W. Adamson, Nov 10 2006

Keywords

Comments

As with every inverse binomial transform, the numbers are given by starting from the sequence (A005614) and reading the leftmost values of the array of repeated differences.

Examples

			Given 1, 0, 1, 1, 0, ..., take finite difference rows:
1, 0, 1, 1, 0, ...
_-1, 1, 0, -1, ...
___ 2, -1, -1, ...
_____ -3, 0, ...
________ 3, ...
Left border becomes the sequence.
		

Crossrefs

Cf. A124842.
The following sequences are all essentially the same, in the sense that they are simple transformations of each other, with A000201 as the parent: A000201, A001030, A001468, A001950, A003622, A003842, A003849, A004641, A005614, A014675, A022342, A088462, A096270, A114986, A124841. - N. J. A. Sloane, Mar 11 2021

Programs

  • Mathematica
    A005614 = SubstitutionSystem[{0 -> {1}, 1 -> {1, 0}}, {1, 0}, 7] // Last;
    Table[Differences[A005614, n], {n, 0, 35}][[All, 1]] (* Jean-François Alcover, Feb 06 2020 *)

Extensions

Corrected and extended by R. J. Mathar, Nov 28 2011

A086377 a(1)=1; a(n)=a(n-1)+2 if n is in the sequence; a(n)=a(n-1)+2 if n and (n-1) are not in the sequence; a(n)=a(n-1)+3 if n is not in the sequence but (n-1) is in the sequence.

Original entry on oeis.org

1, 4, 6, 8, 11, 13, 16, 18, 21, 23, 25, 28, 30, 33, 35, 37, 40, 42, 45, 47, 49, 52, 54, 57, 59, 62, 64, 66, 69, 71, 74, 76, 78, 81, 83, 86, 88, 91, 93, 95, 98, 100, 103, 105, 107, 110, 112, 115, 117, 120, 122, 124, 127, 129, 132, 134, 136, 139, 141, 144, 146, 148, 151
Offset: 1

Views

Author

Benoit Cloitre, Sep 13 2003

Keywords

Comments

From Joseph Biberstine (jrbibers(AT)indiana.edu), May 02 2006: (Start)
The continued fraction 4/Pi = 1 + 1/(3 + 4/(5 + 9/(7 + 16/(9 + 25/(11 + ...))))) (see A079037) suggests the recurrence b(n) = 2*n - 1 + n^2/b(n+1) with b(1) = 4/Pi. Solving the above recurrence in the other direction we would have b(n) = (n-1)^2/b(n-1 - 2*n + 3) with b(1) = 4/Pi.
Now consider this last defined sequence {b(n)}. It appears to grow linearly. (1) Does it? (2) What is the limit of b(n)/n as n->oo? (3) How does the limit depend on the initial term b(1)? (End)
From the recurrence relation, it follows that the limit L = lim_{b->oo} b(n)/n satisfies the following quadratic equation: L^2 - 2*L - 1 = 0 implying that L = 1+sqrt(2) or 1-sqrt(2). - Max Alekseyev, May 02 2006
Note that b(n)/n decreases, while b(n)/(n+1) increases. I speculate that 4/Pi is the only b(1) value such that b(n)/n converges to 1+sqrt(2) instead of 1-sqrt(2). - Don Reble, May 02 2006
It appears that round( b(n) ) = floor((1+sqrt(2))*n - 1/sqrt(2)) = A086377(n) = a(n). This is certainly true for the first 190 terms. Is there a formal proof? - Paul D. Hanna, May 02 2006
Is A086377 the sequence of positions of 0 in A189687? - Clark Kimberling, Apr 25 2011
The three conjectures by respectively Biberstein, Hanna, and Kimberling have all been proved, see the paper by Bosma et al. in the Links. - Michel Dekking, Oct 05 2017
In the Fokkink-Joshi paper, this sequence is the Cloitre (1,1,3,2)-hiccup sequence, - Michael De Vlieger, Jul 29 2025

Crossrefs

Programs

Formula

a(n) = floor((1+sqrt(2))*n - 1/sqrt(2)).
n is in the sequence if A004641(n)=1 or A001030(n)=2. a(n) = A080652(n) - 1 = A064437(n+1) - 2 = A081841(n+2) - 3. - Ralf Stephan, Feb 23 2004

A080757 First differences of Beatty sequence A022838(n) = floor(n sqrt(3)).

Original entry on oeis.org

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

Views

Author

N. J. A. Sloane, Mar 25 2003

Keywords

Comments

Let S(0) = 1; obtain S(k) from S(k-1) by applying 1 -> 221, 2 -> 2221; sequence is S(0), S(1), S(2), ... - Matthew Vandermast, Mar 25 2003
The sequence (a(n+1)-1) is the homogeneous Sturmian sequence with slope sqrt(3)-1, which is fixed point of the morphism 0->110, 1->1101. So (a(n), n>0) is the unique fixed point of the morphism 1->221, 2->2212. - Michel Dekking, Oct 06 2018
The dual version defined by b(n)=1-(a(n)-1) for n>0 is the Sturmian sequence with slope 1-(sqrt(3)-1) = 2-sqrt(3). It is the fixed point of the morphism 0->0010, 1->001. The sequence (b(n)) prefixed with 0 equals A275855. - Michel Dekking, Oct 06 2018

Crossrefs

Equals A007538(n+1) - 1. Cf. A001030.

Programs

  • Haskell
    a080757 = (subtract 1) . a007538 . (+ 1)
    -- Reinhard Zumkeller, Feb 14 2012
  • Mathematica
    Flatten[ NestList[ Flatten[ # /. {1 -> {2, 2, 1}, 2 -> {2, 2, 2, 1}}] &, {1}, 4]] (* Robert G. Wilson v, Jun 20 2005 *)
    Differences[Floor[Range[0,110]Sqrt[3]]] (* Harvey P. Dale, Mar 15 2018 *)

Formula

a(n) = A007538(n+1) - 1. - Reinhard Zumkeller, Feb 13 2012

A197878 a(n) = floor(2*(1 + sqrt(2))*n).

Original entry on oeis.org

4, 9, 14, 19, 24, 28, 33, 38, 43, 48, 53, 57, 62, 67, 72, 77, 82, 86, 91, 96, 101, 106, 111, 115, 120, 125, 130, 135, 140, 144, 149, 154, 159, 164, 168, 173, 178, 183, 188, 193, 197, 202, 207, 212, 217, 222, 226, 231, 236, 241, 246, 251, 255, 260, 265, 270
Offset: 1

Views

Author

Zak Seidov, Oct 18 2011

Keywords

Comments

First differences are 4 and 5. Also, there is no immediate pattern in parity of a(n).
Are similar sequences well defined (in terms of rounding problems)? See also A086843, A086844, A196468.
Answer: I would not call the sequences A086843, A086844, A196468 'similar' to (a(n)). The first differences d =5,5,5,5,4,5,5,5,5,4,... are a Sturmian sequence (d(n)) with slope alpha = 2 + sqrt(8) and intercept 0. We give d offset 0 by setting d(0):=4. By Hofstadter's Fundamental Theorem of eta-sequences, the chunks 45555 and 455555 occur following a Sturmian sequence with density beta = (sqrt(8) - 2)/(3 - sqrt(8)). Since beta = 2 + sqrt(8) = alpha, the sequence (d(n)) is fixed point of the substitution 4->45555, 5->455555. See A197879 for a complete description of the parity pattern of (a(n)). - Michel Dekking, Jan 24 2017

Crossrefs

Cf. A001030. - Michel Dekking, Jan 24 2017
A bisection of A003151.

Programs

  • Magma
    [Floor(2*(1 + Sqrt(2))*n): n in [1..100]]; // G. C. Greubel, Aug 18 2018
  • Mathematica
    Table[Floor[((2+Sqrt[8]))*n], {n,100}]
  • PARI
    a(n)=2*n+sqrtint(8*n^2) \\ Charles R Greathouse IV, Oct 25 2011
    

Formula

a(n) = A003151(2n). - R. J. Mathar, Oct 20 2011

A323116 Fixed point of the morphism 1->221, 2->2211.

Original entry on oeis.org

2, 2, 1, 1, 2, 2, 1, 1, 2, 2, 1, 2, 2, 1, 2, 2, 1, 1, 2, 2, 1, 1, 2, 2, 1, 2, 2, 1, 2, 2, 1, 1, 2, 2, 1, 1, 2, 2, 1, 2, 2, 1, 1, 2, 2, 1, 1, 2, 2, 1, 2, 2, 1, 1, 2, 2, 1, 1, 2, 2, 1, 2, 2, 1, 2, 2, 1, 1, 2, 2, 1, 1, 2, 2, 1, 2, 2, 1, 2, 2, 1, 1, 2, 2, 1, 1, 2, 2, 1, 2, 2, 1, 1, 2, 2, 1, 1, 2, 2, 1, 2, 2, 1, 1, 2
Offset: 1

Views

Author

Michel Dekking, Jan 05 2019

Keywords

Comments

A self-generating sequence: there are a(n) 1's between successive pairs 22.
(a(n)) has some similarity with the Kolakoski sequence A000002. It is the fixed point of a 2-block substitution beta. Beta is simply given by
beta(11) = 221221
beta(12) = 2212211
beta(21) = 2211221
beta(22) = 22112211.
However, the fact that beta(a) = a is not entirely trivial, as the iterates of beta are ill-defined (since beta^n(12) and beta^n(21) have odd length for all n>0).
By induction one sees that still, beta(beta(...beta(22))) = sigma^n(22), where sigma is the defining morphism given by sigma(1) = 221, sigma(2) = 2211.

Examples

			2, 2, 1, 1, 2, 2, 1, 1, 2, 2, 1, 2, 2, 1, 2, 2, 1, 1, 2, 2, 1, 1, 2, 2,
      2,          2,          1,       1,       2,          2,
		

Crossrefs

Other self-generating sequences: A000002, A001030, A007538, A006337, A018244, etc.

Programs

  • Maple
    f(1):= (2,2,1): f(2):= (2,2,1,1):
    T:= [2]:
    for i from 1 to 5 do T:= map(f,T) od;
    T; # Robert Israel, Jan 07 2019
  • Mathematica
    Nest[Flatten[ReplaceAll[#,{1->{2,2,1},2->{2,2,1,1}}]]&,{2},4] (* Paolo Xausa, Nov 09 2023 *)

A106802 Trajectory of 2 under the morphism 1->{2, 1, 2, 1, 1, 2, 2, 1}, 2->{1, 1, 1, 2, 2, 1, 2}.

Original entry on oeis.org

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

Views

Author

Roger L. Bagula, May 17 2005

Keywords

References

  • T. S. Blyth and E. F. Robertson, Essential Student Algebra: volume 5: Groups: Chapman and Hall, 1986, page 9.

Crossrefs

Programs

  • Mathematica
    s[1, 1] = {1}; s[2, 1] = {2};; s[1, 2] = {2}; s[2, 2] = {1};; s[1, 3] = {1, 2}; s[2, 3] = {1};; s[1, 4] = {1}; s[2, 4] = {1, 2};; s[1, 5] = {1, 2}; s[2, 5] = {2};; s[1, 6] = {2}; s[2, 6] = {1};; w[i_] = s[1, 1 + Mod[i, 6]] v[i_] = s[2, 1 + Mod[i, 6]] S[1] = Flatten[Table[w[i], {i, 1, 6}]] S[2] = Flatten[Table[v[i], {i, 1, 6}]] t[a_] := Flatten[S /@ a]; p[0] = {1}; p[1] = t[p[0]]; p[n_] := t[p[n - 1]] aa = p[3]
    Nest[Flatten[#]/.{1->{2,1,2,1,1,2,2,1},2->{1,1,1,2,2,1,2}}&,2,4]//Flatten (* Harvey P. Dale, Apr 09 2019 *)

Extensions

Edited by N. J. A. Sloane, Nov 12 2006
Previous Showing 11-20 of 21 results. Next