OFFSET
0,3
COMMENTS
LINKS
Reinhard Zumkeller, Table of n, a(n) for n = 0..10000
EXAMPLE
........0
........1
.......10
.......11
......100 <- Starting here, the downward diagonals
......101 read 100, 111, 110, 101, giving the block 4, 7, 6, 5.
......110
......111
.....1000
.....1001
.....1010
.....1011
.........
MAPLE
a:=proc(i, j) if j=1 and i<=16 then 0 else convert(i+15, base, 2)[7-j] fi end: seq(a(i, 2)*2^4+a(i+1, 3)*2^3+a(i+2, 4)*2^2+a(i+3, 5)*2+a(i+4, 6), i=1..16); # this is a Maple program (not necessarily the simplest) only for one block of (2^4) numbers # Emeric Deutsch, Apr 16 2005
MATHEMATICA
numberOfBlocks = 7; bloc[n_] := Join[ Table[ IntegerDigits[k, 2], {k, 2^(n-1), 2^n-1}], Table[ Rest @ IntegerDigits[k, 2], {k, 2^n, 2^n+n}]]; Join[{0, 1}, Flatten[ Table[ Table[ Diagonal[bloc[n], k] // FromDigits[#, 2]&, {k, 0, -2^(n-1)+1, -1}], {n, 2, numberOfBlocks}]]] (* Jean-François Alcover, Nov 03 2016 *)
PROG
(Haskell)
import Data.Bits ((.|.), (.&.))
a105025 n = foldl (.|.) 0 $ zipWith (.&.)
a000079_list $ reverse $ enumFromTo n (n - 1 + a070939 n)
-- Reinhard Zumkeller, Jul 21 2012
CROSSREFS
KEYWORD
nonn,nice,base
AUTHOR
N. J. A. Sloane, Apr 03 2005
EXTENSIONS
More terms from Emeric Deutsch, Apr 16 2005
STATUS
approved