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”).

A222213
Replace all (decimal) digits '0' with '4' and vice versa.
1
4, 1, 2, 3, 0, 5, 6, 7, 8, 9, 14, 11, 12, 13, 10, 15, 16, 17, 18, 19, 24, 21, 22, 23, 20, 25, 26, 27, 28, 29, 34, 31, 32, 33, 30, 35, 36, 37, 38, 39, 4, 1, 2, 3, 0, 5, 6, 7, 8, 9, 54, 51, 52, 53, 50, 55, 56, 57, 58, 59, 64, 61, 62, 63, 60, 65, 66, 67, 68, 69, 74, 71, 72, 73, 70, 75
OFFSET
0,1
COMMENTS
The map which is applied to primes in A171019.
LINKS
MATHEMATICA
Table[FromDigits[IntegerDigits[n]/.{0->z, 4->f}/.{z->4, f->0}], {n, 0, 80}] (* Harvey P. Dale, Feb 25 2013 *)
PROG
(PARI) A222213(n, d=[4, 1, 2, 3, 0, 5, 6, 7, 8, 9])=sum(i=1, #n=digits(n), d[n[i]+1]*10^(#n-i), !n*d[1]) \\ N.B.: PARI's digits() function returns [] for 0.
CROSSREFS
KEYWORD
nonn,base,easy
AUTHOR
M. F. Hasler, Feb 12 2013
STATUS
approved