Returns some Carmichael numbers.
a = number_carmichael ( )
a 33x1 matrix of floating point integers, some Carmichael numbers
In number theory, a Carmichael number is a composite positive integer n which satisfies the congruence
for all integers b which are relatively prime to n.
a = number_carmichael ( ) // Test Carmichael #1 in the range b=[1,50] n=a(1); bmin = 1; bmax = 50; for b = bmin : bmax if ( number_gcd(b,n) == 1 ) then x = number_powermod ( b, n-1, n ); mprintf("gcd(%d,%d)=1 and %d^%d = %d (mod %d)\n",.. b,n,b,n-1,x,n); end end
http://www.research.att.com/~njas/sequences/table?a=2997&fmt=4
Carmichael number, http://en.wikipedia.org/wiki/Carmichael_numbers