OFFSET
0,3
COMMENTS
FORMULA
a(n) = a(n') if the i-th digit of n' either equals the i-th digit of n or (10 - the i-th digit of n): e.g., a(12345) = a(18365), because the 2nd and 4th digit of 12345 equal 10-(the 2nd resp. 4th digit of 18365), and the other digits are the same. In particular, a(10k+5+m) = a(10k+5-m), for m=0,...,4. - M. F. Hasler, Mar 26 2015
EXAMPLE
a(24) = 24*24 = 446:
...24
...24
-----
...86
..48.
-----
..446
(The rule for "adding" the columns is to multiply mod 10: 8+8 = 8 * 8 mod 10 = 4.)
PROG
(PARI) A169917(n)={#n=digits(n); n=apply(d->n*d, n)%10; sum(i=0, 2*#n-2, prod(j=max(1, #n-i), min(2*#n-1-i, #n), n[2*#n-i-j][j])%10*10^i)} \\ M. F. Hasler, Mar 26 2015
CROSSREFS
KEYWORD
nonn,base
AUTHOR
STATUS
approved