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

A269161 Formula for Wolfram's Rule 86 cellular automaton: a(n) = 4n XOR (2n OR n).

Original entry on oeis.org

0, 7, 14, 11, 28, 27, 22, 19, 56, 63, 54, 51, 44, 43, 38, 35, 112, 119, 126, 123, 108, 107, 102, 99, 88, 95, 86, 83, 76, 75, 70, 67, 224, 231, 238, 235, 252, 251, 246, 243, 216, 223, 214, 211, 204, 203, 198, 195, 176, 183, 190, 187, 172, 171, 166, 163, 152, 159, 150, 147, 140, 139, 134, 131, 448, 455, 462, 459
Offset: 0

Views

Author

Antti Karttunen, Feb 20 2016

Keywords

Comments

The sequence is injective: no value occurs more than once.
Fibbinary numbers (A003714) give all integers n>=0 for which a(n) = A048727(n) and for which a(n) = A269160(n).

Crossrefs

Cf. A265281 (iterates starting from 1).
Cf. also A048727, A269160.

Programs

Formula

a(n) = 4n XOR (2n OR n) = A003987(4*n, A003986(2*n, n)).
a(n) = 4*n XOR A163617(n).
Other identities. For all n >= 0:
a(2*n) = 2*a(n).
a(n) = A057889(A269160(A057889(n))). [Rule 86 is the mirror image of rule 30.]

A213370 a(n) = n AND 2*n, where AND is the bitwise AND operator.

Original entry on oeis.org

0, 0, 0, 2, 0, 0, 4, 6, 0, 0, 0, 2, 8, 8, 12, 14, 0, 0, 0, 2, 0, 0, 4, 6, 16, 16, 16, 18, 24, 24, 28, 30, 0, 0, 0, 2, 0, 0, 4, 6, 0, 0, 0, 2, 8, 8, 12, 14, 32, 32, 32, 34, 32, 32, 36, 38, 48, 48, 48, 50, 56, 56, 60, 62, 0, 0, 0, 2, 0, 0, 4, 6, 0, 0, 0, 2, 8, 8
Offset: 0

Views

Author

Alex Ratushnyak, Jun 14 2012

Keywords

Crossrefs

Cf. A003714: indices of 0's.
Cf. A213540: indices of 2's, indices of 4's divided by 2.

Programs

  • Mathematica
    Table[BitAnd[n, 2n], {n, 0, 63}] (* Alonso del Arte, Jun 19 2012 *)
  • PARI
    a(n) = bitand(n, 2*n); \\ Michel Marcus, Mar 26 2021
  • Python
    for n in range(99):
        print(2*n & n, end=", ")
    

Formula

a(n) = 2 * A048735(n).
a(n) = (1/2)*(A048727(n) XOR A269160(n)) = (n OR 2n) XOR (n XOR 2n). - Antti Karttunen, May 16 2021

A328103 Bitwise XOR of trajectories of rule 30 and rule 124, when both are started from a lone 1 cell: a(n) = A110240(n) XOR A267357(n).

Original entry on oeis.org

0, 4, 30, 100, 398, 1748, 6510, 28628, 102590, 456132, 1642078, 7289764, 26336590, 116802708, 420215854, 1865678868, 6741198206, 29904470916, 107568473246, 477629808612, 1725756768270, 7655529847380, 27537572248046, 122273029571156, 441793665700414, 1959816793456452, 7049616389341662, 31301899019407908, 113099196716630990, 501713069953322004
Offset: 0

Views

Author

Antti Karttunen, Oct 05 2019

Keywords

Crossrefs

Cf. A003987, A110240, A267357, A269160, A269174, A328109 (binary weight of terms).
Cf. also A327971, A327972, A327973, A327976, A328104 for other such combinations, and also A328111.

Programs

Formula

a(n) = A110240(n) XOR A267357(n), where XOR is bitwise exclusive or (A003987).

A327971 Bitwise XOR of trajectories of rule 30 and its mirror image, rule 86, when both are started from a lone 1 cell: a(n) = A110240(n) XOR A265281(n).

Original entry on oeis.org

0, 0, 10, 20, 130, 396, 2842, 4420, 38610, 124220, 684490, 1385044, 8891330, 26281036, 192525274, 269101060, 2454365330, 8588410876, 43860512138, 89059958420, 551714970626, 1663794165260, 12235920695450, 19683098342340, 164315052318034, 538162708968636, 2894532467106378, 6192136868790228, 37503903254935874, 114926395086966988, 814341599153559130
Offset: 0

Views

Author

Antti Karttunen, Oct 03 2019

Keywords

Comments

Each term is a binary palindrome when its trailing zeros (in base 2) are omitted, that is, a term of A057890.
Compare the binary string illustrations drawn for the first 1024 terms of this sequence and for A327976, which has almost the same definition.

Crossrefs

Cf. A003987, A030101, A057890, A110240, A265281, A280508, A328106 (binary weight of terms).
Cf. also A327972, A327973, A327976, A328103, A328104 for other such combinations.

Programs

Formula

a(n) = A110240(n) XOR A265281(n).
a(n) = A280508(A110240(n)) = A110240(n) XOR A030101(A110240(n)).
a(n) = A280508(A265281(n)) = A265281(n) XOR A030101(A265281(n)).
For n >= 1, a(n) = (1/2) * (A327973(n-1) XOR A327976(n-1)).

A327976 Bitwise XOR of trajectories (centrally aligned) of rule 30, and its mirror image, rule 86, when both are started from a lone 1-bit, with the latter delayed by one step: a(n) = A110240(n) XOR 2*A265281(n-1).

Original entry on oeis.org

5, 23, 73, 359, 1233, 6143, 19225, 93495, 325729, 1518895, 4833289, 23453735, 81443089, 398815039, 1271974489, 6168932215, 21231239841, 99197620591, 314863189193, 1541326542823, 5312985402193, 26258203294847, 82884499362201, 400683454289591, 1406328980294113, 6532877164215983, 20744329255918985, 100303645024039591
Offset: 1

Views

Author

Antti Karttunen, Oct 04 2019

Keywords

Crossrefs

Cf. A110240, A265281, A269160, A269161, A030101, A327974 (gives the middle bit), A328108 (binary weight).
Cf. also A327971, A327972, A327973, A328103, A328104 for other such combinations.

Programs

Formula

a(n) = A110240(n) XOR 2*A265281(n-1) = A110240(n) XOR 2*A030101(A110240(n-1)).

A328104 a(n) = A163617(A110240(n)) = A110240(n) OR 2*A110240(n).

Original entry on oeis.org

3, 15, 59, 255, 947, 4095, 15131, 65407, 242627, 1048271, 3874811, 16743551, 62119411, 268369791, 991927259, 4286447359, 15902689155, 68701773199, 253935222715, 1097330432511, 4071076396851, 17587676696575, 65007550988187, 280916526002175, 1042196361379523, 4502448248917967, 16641933085980923, 71914639532751871
Offset: 0

Views

Author

Antti Karttunen, Oct 04 2019

Keywords

Crossrefs

Cf. A003986, A051023, A110240, A269160, A163617, A328105 (binary weight of terms).
Cf. also A327971, A327972, A327973, A327976, A328103 for other such combinations.

Programs

Formula

a(n) = A163617(A110240(n)) = A110240(n) OR 2*A110240(n).
a(n) = (1/2) * (A110240(n) XOR A110240(1+n)).

A327972 Bitwise XOR of trajectories of rule 30 and rule 150, when both are started from a lone 1 cell: a(n) = A110240(n) XOR A038184(n).

Original entry on oeis.org

0, 0, 12, 4, 128, 384, 3404, 740, 37056, 127296, 794316, 286532, 8510656, 25560896, 224057484, 42076324, 2446214016, 8430013568, 51732969356, 18062215300, 553213409792, 1655549411840, 14630859361996, 3227756349540, 159219183713088, 546944274202816, 3411332163636556, 1231354981057220, 36554500089286208, 109782277571646400, 962314238681316620
Offset: 0

Views

Author

Antti Karttunen, Oct 03 2019

Keywords

Crossrefs

Cf. also A327971, A327973, A327976, A328103, A328104 for other such combinations.

Programs

Formula

a(n) = A038184(n) XOR A110240(n).
Conjecture: for n > 1, floor(log_2(a(n))) = 2*n - (1,2,1,4,1,2,1,5 according as n == 0..7 (mod 8), respectively). - Alan Michael Gómez Calderón, Mar 02 2023

A328106 Binary weight of A327971: a(n) = A000120(A110240(n) XOR A030101(A110240(n))).

Original entry on oeis.org

0, 0, 2, 2, 2, 4, 6, 4, 8, 10, 10, 8, 12, 8, 18, 6, 12, 26, 16, 18, 14, 18, 20, 22, 22, 26, 26, 38, 30, 26, 36, 26, 28, 36, 28, 18, 28, 42, 36, 32, 34, 40, 44, 38, 40, 50, 48, 48, 50, 58, 46, 56, 48, 42, 54, 48, 56, 56, 46, 54, 48, 52, 60, 58, 78, 74, 64, 60, 66, 74, 74, 64, 80, 74, 80, 62, 92, 62, 80, 70, 68, 100, 90, 82, 80, 92
Offset: 0

Views

Author

Antti Karttunen, Oct 05 2019

Keywords

Comments

a(n) is the number of times the k-th cell from the left is different from the k-th cell from the right, at the generation n of Rule 30 1-D cellular automaton, when it is started from a single alive cell.
All terms are even.

Examples

			The evolution of one-dimensional cellular automaton rule 30 proceeds as follows, when started from a single alive (1) cell:
---------------------------------------------- a(n)
   0:              (1)                          0
   1:             1(1)1                         0
   2:            11(0)01                        2
   3:           110(1)111                       2
   4:          1100(1)0001                      2
   5:         11011(1)10111                     4
   6:        110010(0)001001                    6
   7:       1101111(0)0111111                   4
   8:      11001000(1)11000001                  8
   9:     110111101(1)001000111                10
  10:    1100100001(0)1111011001               10
  11:   11011110011(0)10000101111               8
  12:  110010001110(0)110011010001             12
  13: 1101111011001(1)1011100110111             8
When we count the times the k-th cell from the left is different from the k-th cell from the right, we obtain a(n). Note that the central cells (indicated with parentheses) do not affect the count, as the central cell is always equal to itself.
		

Crossrefs

Programs

Formula

a(n) = Sum_{i=0..2n} abs(A070950(n,i)-A070950(n,n-i)).

A327980 Distances between successive zeros in A051023, the middle column of rule-30 1-D cellular automaton, when started from a lone 1 cell.

Original entry on oeis.org

4, 1, 3, 1, 1, 2, 3, 1, 2, 1, 4, 2, 4, 1, 4, 2, 2, 3, 1, 1, 1, 3, 1, 2, 2, 3, 2, 2, 7, 1, 1, 1, 5, 1, 1, 2, 2, 4, 1, 1, 1, 1, 2, 1, 2, 3, 1, 1, 4, 1, 1, 3, 3, 3, 2, 1, 1, 1, 1, 1, 1, 2, 1, 1, 6, 4, 2, 1, 4, 1, 1, 4, 2, 4, 1, 1, 1, 1, 3, 1, 2, 1, 1, 3, 1, 5, 1, 7, 1, 1, 1, 1, 1, 8, 3, 1, 2, 3, 4, 1, 1, 1, 1
Offset: 1

Views

Author

Antti Karttunen, Oct 03 2019

Keywords

Comments

First differences of A327985, which gives indices of zeros in A051023.

Examples

			The evolution of one-dimensional cellular automaton rule 30 proceeds as follows, when started from a single alive (1) cell:
   0:              (1)
   1:             1(1)1
   2:            11(0)01
   3:           110(1)111
   4:          1100(1)0001
   5:         11011(1)10111
   6:        110010(0)001001
   7:       1101111(0)0111111
   8:      11001000(1)11000001
   9:     110111101(1)001000111
  10:    1100100001(0)1111011001
  11:   11011110011(0)10000101111
  12:  110010001110(0)110011010001
When noting up the distances between successive 0's in its central column (indicated here with parentheses), we obtain 6-2 (as the first 0 is on row 2, and the second is on row 6), 7-6, 10-7, 11-10, 12-11, ..., that is, the first terms of this sequence: 4, 1, 3, 1, 1, ...
		

Crossrefs

Programs

  • Mathematica
    A327980list[upto_]:=Differences[Flatten[Position[CellularAutomaton[30,{{1},0},{upto,{{0}}}],0]]];A327980list[300] (* Paolo Xausa, Jun 01 2023 *)
  • PARI
    up_to = 105;
    A269160(n) = bitxor(n, bitor(2*n, 4*n));
    A327980list(up_to) = { my(v=vector(up_to), s=25, n=2, on=n, k=0); while(kA269160(s); if(!((s>>n)%2), k++; v[k] = (n-on); on=n)); (v); }
    v327980 = A327980list(up_to);
    A327980(n) = v327980[n];

Formula

a(n) = A327985(1+n) - A327985(n).

A327981 Distances between successive ones in A051023, the middle column of rule-30 1-D cellular automaton, when started from a lone 1 cell.

Original entry on oeis.org

1, 2, 1, 1, 3, 1, 4, 2, 1, 3, 3, 1, 1, 2, 2, 1, 1, 3, 1, 1, 2, 2, 2, 1, 5, 1, 3, 2, 2, 1, 2, 2, 2, 1, 1, 1, 1, 1, 5, 1, 1, 1, 4, 2, 2, 1, 1, 6, 3, 2, 1, 4, 1, 1, 4, 1, 2, 1, 2, 1, 2, 8, 4, 1, 1, 1, 1, 2, 1, 1, 2, 3, 1, 1, 4, 1, 1, 2, 2, 1, 1, 6, 1, 3, 4, 1, 3, 1, 1, 1, 3, 1, 1, 1, 1, 1, 7, 1, 1, 1, 1, 1, 1, 2, 1, 3, 2, 1, 2, 1, 1
Offset: 1

Views

Author

Antti Karttunen, Oct 03 2019

Keywords

Comments

First differences of A327984, which gives indices of ones in A051023.

Examples

			The evolution of one-dimensional cellular automaton rule 30 proceeds as follows, when started from a single alive (1) cell:
   0:              (1)
   1:             1(1)1
   2:            11(0)01
   3:           110(1)111
   4:          1100(1)0001
   5:         11011(1)10111
   6:        110010(0)001001
   7:       1101111(0)0111111
   8:      11001000(1)11000001
   9:     110111101(1)001000111
  10:    1100100001(0)1111011001
  11:   11011110011(0)10000101111
  12:  110010001110(0)110011010001
  13: 1101111011001(1)1011100110111
The distances between successive 1's in its central column (indicated here with parentheses) are 1-0 (as the first 1 is on row 0, and the second is on row 1), 3-1, 4-3, 5-4, 8-5, 9-8, 13-9, ..., that is, the first terms of this sequence: 1, 2, 1, 1, 3, 1, 4, ...
		

Crossrefs

Programs

  • Mathematica
    A327981list[upto_]:=Differences[Flatten[Position[CellularAutomaton[30,{{1},0},{upto,{{0}}}],1]]];A327981list[300] (* Paolo Xausa, Jun 27 2023 *)
  • PARI
    up_to = 105;
    A269160(n) = bitxor(n, bitor(2*n, 4*n));
    A327981list(up_to) = { my(v=vector(up_to), s=1, n=0, on=n, k=0); while(kA269160(s); if((s>>n)%2, k++; v[k] = (n-on); on=n)); (v); }
    v327981 = A327981list(up_to);
    A327981(n) = v327981[n];

Formula

a(n) = A327984(1+n) - A327984(n).
Previous Showing 11-20 of 37 results. Next