In a thought-provoking letter to New Scientist, J. Margolis commences with the observation that calculating prodigies (idiot savants), who are often also mentally retarded, can easily and almost instantaneously recognize 20-digit prime numbers! Gifted mathematicians with so-called photographic memories cannot perform such mental feats using known methods for identifying primes. What do the calculating prodigies know that the rest of us do not? Better algorithms; that is, calculating methods? Margolis expands on this:
"All this suggests some relatively simple, subconscious algorithms which have not, as yet, been explicitly formulated. Research in this direction might well result in new mathematical insights.
"It need not be surprising that mathematical insight is more fundamental than language. Even a primitive animal brain is 'wired" to perform exceedingly complex computations essential for survival in an unpredictable environment. The latest 'smart' weapons are rudimentary compared with a humble gnat. Mathematics could be a by-product of these functions. Language is a comparatively recent evolutionary innovation and it is quite possible that conscious manipulation of abstract symbols has not caught up with an innate ability to perceive quantitative relationships."
(Margolis, Joel; "What Gnats Know," New Scientist, p. 58, January 30, 1993.)