A292682 Rule 230: (000, ..., 111) -> (0, 1, 1, 0, 0, 1, 1, 1), without extending to the right of input bit 0.
0, 3, 6, 5, 12, 15, 10, 11, 24, 27, 30, 29, 20, 23, 22, 23, 48, 51, 54, 53, 60, 63, 58, 59, 40, 43, 46, 45, 44, 47, 46, 47, 96, 99, 102, 101, 108, 111, 106, 107, 120, 123, 126, 125, 116, 119, 118, 119, 80, 83, 86, 85, 92, 95, 90, 91, 88, 91, 94, 93, 92, 95, 94, 95, 192, 195, 198, 197, 204, 207
Offset: 0
Examples
n | a(n) 0 = 0[2] | 0[2] = 0 1 = 1[2] | 11[2] = 3 (bits below 001 and 01(0) are on) 2 = 10[2] | 110[2] = 6 (1 below 001 and 010, 0 below 10(0)) 3 = 11[2] | 101[2] = 5 (1 below 001 and 11(0), 0 below 011.) 4 = 100[2] | 1100[2] = 12 (as n = 1 and n = 2, shifted left once more) 5 = 101[2] | 1111[2] = 15 (1 below 001, 010 (twice) and 101) 6 = 110[2] | 1010[2] = 10 (as n = 3, shifted left once) 7 = 111[2] | 1011[2] = 11 (1 below 001, 111 and 11(0), 0 below 011).
Links
- Eric Weisstein's World of Mathematics, Elementary Cellular Automaton
- Index entries for sequences related to cellular automata
- Index to Elementary Cellular Automata
Programs
-
PARI
apply( A292682(n,r=230)=sum(i=0,logint(!n+n<<=1,2)+1,bittest(r,bitand(n>>i,7))<
Comments