OFFSET
1,1
LINKS
David Applegate and N. J. A. Sloane, Table of n, a(n) for n = 1..21894
D. Applegate, M. LeBrun and N. J. A. Sloane, Dismal Arithmetic [Note: we have now changed the name from "dismal arithmetic" to "lunar arithmetic" - the old name was too depressing]
EXAMPLE
11011*11011 = 11111*11111 = 111111111, so 11011 and 11111 are members.
PROG
(ksh script from David Applegate; assumes the dismal C program dismal2a has been installed)
i=0
while [ $i -lt 100000 ]; do
echo $i $(dismal2a -d mul $i $i)
i=$(($i+1))
done | awk '{
nrt[$2]++;
rt[$2]=rt[$2] " " $1;
}
END{
for (i in rt)
if (nrt[i] > 1)
print i, rt[i];
}' | sort -k1, 1n > dismal_multsquares.txt
CROSSREFS
KEYWORD
nonn,base
AUTHOR
David Applegate and N. J. A. Sloane, Jan 26 2011
STATUS
approved