Initial data commit

This commit is contained in:
Ingy döt Net 2023-07-01 11:58:00 -04:00
parent 72d218235f
commit f23f22d71c
199087 changed files with 3378941 additions and 0 deletions

View file

@ -0,0 +1,14 @@
use RationalNumbers;
PerfectNumbers( Limit = integer) -> multi(integer);
PerfectNumbers( Limit) =
[ Candidate = 2 .. Limit;
Sum:= Rational(1,Candidate);
[ Divisor = 2 .. integer(sqrt(real(Candidate)));
if mod(Candidate, Divisor) == 0 then
Sum := Sum + Rational(1, Divisor) + Rational(Divisor, Candidate);
];
if Sum == Rational(1,1) then Candidate
];
PerfectNumbers(10000)?