OFFSET
0,1
COMMENTS
Take a number n, create a table with d columns and rows where d=number of digits of n. Each column corresponds to a digit of n and each row to a digit of n. In each cell, multiply the two digits of n represented by that row and column. Add up the sums of all of the rows and all of the columns to get a new number m which divides n.
"The sum of the products of each of [the] digits" is just the square of the sum of the digits. - Franklin T. Adams-Watters, Jul 17 2006
LINKS
Harvey P. Dale, Table of n, a(n) for n = 0..1000
EXAMPLE
512 / (2*(5*5 + 5*1 + 5*2 + 1*5 + 1*1 + 1*2 + 2*5 + 2*1 + 2*2)) = 4.
MATHEMATICA
ed2Q[n_]:=Module[{idn=IntegerDigits[n]}, Divisible[n, 2Total[ Flatten[ Table[ idn* idn[[i]], {i, Length[idn]}]]]]]; Select[Range[7000], ed2Q] (* Harvey P. Dale, Dec 28 2016 *)
CROSSREFS
KEYWORD
base,nonn
AUTHOR
Chuck Seggelin (barkeep(AT)plastereddragon.com), Jun 30 2003
STATUS
approved