OFFSET
0,3
LINKS
Robert Israel, Table of n, a(n) for n = 0..10000
MAPLE
f:= proc(n) local L, k;
L:= convert(n, base, 7);
add(L[-i]*7^(i-1), i=1..nops(L))
end proc:
map(f, [$0..100]); # Robert Israel, May 19 2020
MATHEMATICA
Table[FromDigits[Reverse[IntegerDigits[n, 7]], 7], {n, 0, 80}] (* Harvey P. Dale, Sep 17 2013 *)
PROG
(PARI) a(n, b=7)=subst(Polrev(base(n, b)), x, b) /* where */
base(n, b)={my(a=[n%b]); while(0<n\=b, a=concat(n%b, a)); a} \\ M. F. Hasler, Nov 04 2011
CROSSREFS
KEYWORD
AUTHOR
STATUS
approved