login

Year-end appeal: Please make a donation to the OEIS Foundation to support ongoing development and maintenance of the OEIS. We are now in our 61st year, we have over 378,000 sequences, and we’ve reached 11,000 citations (which often say “discovered thanks to the OEIS”).

A077266
Triangle of number of zeros when n is written in base k (2 <= k <= n).
2
1, 0, 1, 2, 0, 1, 1, 0, 0, 1, 1, 1, 0, 0, 1, 0, 0, 0, 0, 0, 1, 3, 0, 1, 0, 0, 0, 1, 2, 2, 0, 0, 0, 0, 0, 1, 2, 1, 0, 1, 0, 0, 0, 0, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 1, 2, 1, 1, 0, 1, 0, 0, 0, 0, 0, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 1, 0, 1, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1
OFFSET
2,4
FORMULA
T(nk, k)=T(n, k)+1; T(nk+m, k)=T(n, k) if 0<m<k; T(k, k)=1; T(n, k)=0 if n/2<k<n or 0<n<k.
EXAMPLE
Rows start:
1;
0,1;
2,0,1;
1,0,0,1;
1,1,0,0,1;
0,0,0,0,0,1;
3,0,1,0,0,0,1;
2,2,0,0,0,0,0,1;
etc.
9 can be written in bases 2-9 as: 1001, 100, 21, 14, 13, 12, 11 and 10, in which case the numbers of zeros are 2,2,0,0,0,0,0,1.
PROG
(PARI) T(n, k) = #select(x->(x==0), digits(n, k));
row(n) = vector(n-1, k, T(n, k+1));
tabl(nn) = for (n=2, nn, print(row(n))); \\ Michel Marcus, Sep 02 2020
CROSSREFS
Columns include A023416 and A077267. Row sums are A033093, row maxima are A062842, number of positive terms in each row are A077268.
Sequence in context: A325226 A376847 A261812 * A366794 A214302 A129561
KEYWORD
base,nonn,tabl
AUTHOR
Henry Bottomley, Nov 01 2002
STATUS
approved