Perfect Numbers 
Author Message
 Perfect Numbers

While reading Simon Singh's book, "Fermat's Last Theorem", I got
the urge to try and code some of the ideas in Forth. Hopefully
somebody will find it amusing.

This was written as a puzzle-solver: "What is the largest perfect
number that you can find, using only 32-bit cells?"

The program given here is not computationally intensive. It should
finish before you lift your finger off the return key.

Sample output:

Creating --- Perfect Numbers     Version 1.00 ---

Try: .PERFECTS
.X1 and .X2 show divisors of these numbers.
 ok
FORTH> .perfects
Root =  1, x1 =          1, x2 =          1, A = x1 * x2 = 1
Root =  2, x1 =          2, x2 =          3, A = x1 * x2 = 6
Root =  3, x1 =          4, x2 =          7, A = x1 * x2 = 28
Root =  5, x1 =         16, x2 =         31, A = x1 * x2 = 496
Root =  7, x1 =         64, x2 =        127, A = x1 * x2 = 8,128
Root = 13, x1 =       4096, x2 =       8191, A = x1 * x2 = 33,550,336
Root = 17, x1 =      65536, x2 =     131071, A = x1 * x2 = 8,589,869,056
Root = 19, x1 =     262144, x2 =     524287, A = x1 * x2 = 137,438,691,328
Root = 31, x1 = 1073741824, x2 = 2147483647, A = x1 * x2 = 2,305,843,008,139,952,128  ok

This program didn't run on gForth 0.49 for DOS, when Root > 19. (This
is probably fixed in 0.50).

Root = 19, x1 =     262144, x2 =     524287, A = x1 * x2 = 137438691328
:1: Invalid memory address
.perfects
^^^^^^^^^
Backtrace:
  ok

-marcel

---
( *
  * LANGUAGE    : ANS Forth
  * PROJECT     : Forth Environments
  * DESCRIPTION : Find Pythagorean 'Perfect Numbers'
  * CATEGORY    : Number game
  * AUTHOR      : Marcel Hendrix
  * LAST CHANGE : March 10, 2001, Marcel Hendrix
  * )

\       REVISION -perfect "??? Perfect Numbers     Version 1.00 ???"

0 [IF]

 From Simon Singh's book: "Fermat's Last Theorem", Fourth Estate,
 London 1997, ISBN 1-85702-669-1.

 Pythagoras defined a Perfect Number as a number A whose divisors
 add up to A itself. When this sum is larger than A it is called
 'excessive', when it is smaller than A it is called 'defective'.

 Example 1: divisors of 10 = {1 2 5}, Sum = 1 + 2 + 5 = 8.
            10 is defective.
 Example 2: divisors of 6 = {1 2 3}, Sum = 1 + 2 + 3 = 6.
            6 is perfect.
 Example 3: divisors of 12 = {1 2 3 4 6}, Sum = 1 + 2 + 3 + 4 + 6 = 16.
            12 is excessive.

 The first perfect number after 6 is 28: {1, 2, 4, 7, 14}.
 The next are 496, 8,128, 33,550,336, 8,589,869,056.

 Pythagoras found that a perfect number is the sum of a series
 of consecutive rational numbers:

       6 = 1 + 2 + 3
      28 = 1 + 2 + 3 + 4 + 5 + 6 + 7
     496 = 1 + 2 + 3 + 4 + 5 + 6 + 7 + 8 + 9 ... 30 + 31
   8,128 = 1 + 2 + 3 + 4 + 5 + 6 + 7 + 8 + 9 ... 126 + 127

 Pythagoras also found that the divisors of 2^n add up to 2^n - 1, i.e.,

   2^2 =  4, Divisors 1, 2          Sum =  3 = 2^2 - 1
   2^3 =  8, Divisors 1, 2, 4       Sum =  7 = 2^3 - 1
   2^4 = 16, Divisors 1, 2, 4, 8    Sum = 15 = 2^4 - 1

 Euclid found that perfect numbers are always the multiple of two numbers,
 one a power of two, the other the next power of 2 minus 1:

      6 = 2^1 * (2^2 - 1)
     28 = 2^2 * (2^3 - 1)
    496 = 2^4 * (2^5 - 1)
  8,128 = 2^6 * (2^7 - 1)

 State of the art (in 1997) was: 2^216,090 * (2^216,091 - 1) is perfect.

 Observations
 ------------
 The perfect number A can be characterized by a unique number n, where
 A = 2^n * (2^n-1 - 1). So instead of looking for A we can also look for
 its 'root' n.

 To check A, we must find the sum of all of the divisors of
 2^n * (2^n-1 - 1), or, equivalently,

    [1] x1 = the sum of the divisors of 2^n
          +
    [2] x2 = the sum of the divisors of (2^n-1 - 1).

 According to Pythagoras, x1 = 2^n-1.

 The number 2^n - 1 is prime when n is a Mersenne number [Knuth]
   {   2,     3,    5,      7,    13,    17,    19,    31,    61,
      89,   107,   127,   521,   607,  1279,  2203,  2281,  3217,
    4253,  4423,  9689,  9941, 11213, 19937, 21701, 23209, 44497  }.

 So we only need to find x2 and verify that x2 = A - x1.
 The simple case is where x2 is prime, in that case the divisors
 of A are the divisors of x1, appended with these divisors * x2.
 In general the divisors of A are div_x1 * div_x2, where the sets
 div_x1 and div_x2 should not overlap (this is not completely accurate,
 see the program notes).

[THEN]

\ Needs:
\  2^x      ( x -- 2^x )          a table will work best.
\  CELL[]   ( addr ix -- addr' )  CELLS +
\  DOUBLE[] ( addr ix -- addr' )  2* CELLS +
\  +TO      ( n "value" -- )      x +TO a    x a + TO a
\  SQRT     ( u1 -- u2 )          many algorithms
\  ENDIF                          THEN

CREATE x1{        #32     CELLS ALLOT  
CREATE x2{        #50     CELLS ALLOT  
CREATE divisors{{ #500 2* CELLS ALLOT  



: }!  ( addr ix -- ) S" CELL[] ! "    EVALUATE ; IMMEDIATE
: }}! ( addr ix -- ) S" DOUBLE[] 2! " EVALUATE ; IMMEDIATE

0 VALUE n       0 VALUE nd
0 VALUE x1      0 VALUE n1
0 VALUE x2      0 VALUE n2

: .X1   ."  [ " n1 1- 0 ?DO x1{ I } . LOOP ." ] " ;
: .X2   ."  [ " n2 1- 1 ?DO x2{ I } . LOOP ." ] " ;

: UNIQ? ( i -- bool )
        TRUE SWAP n1 0 ?DO  DUP x1{ I } = IF  2DROP FALSE
                                              UNLOOP EXIT
                                       ENDIF  
                      LOOP DROP ;

\ Divisors of x1 => 2^[n-1] - 1 divisors.
\ Store one extra => 2^[n-1] to facilitate BUILD-DIVISORS .
: BUILD-x1 ( -- ) 0 TO n1  n 0 ?DO  I 2^x x1{ I }! 1 +TO n1 LOOP ;

\ Divisors of x2
\ We store two extra ones, 1 to start and x2 to stop,
\ to facilitate BUILD-DIVISORS
: BUILD-x2 ( -- )
        1 x2{ 0 }!  1 TO n2  
        x2 SQRT 1+ DUP 3 < IF  DROP x2 x2{ 1 }! 2 TO n2 EXIT  ENDIF
        2 ?DO I UNIQ? IF  x2 I MOD 0= IF  I x2{ n2 }! 1 +TO n2  
                                   ENDIF
                   ENDIF  
         LOOP
        x2 x2{ n2 }!  1 +TO n2 ;

\ The last product is not valid as it equal to A itself (should be smaller).
: BUILD-DIVISORS ( -- )
        0 TO nd
        n2 0 ?DO x2{ I }
                 n1 0 DO  DUP x1{ I } UM*  divisors{{ nd }}!  1 +TO nd  LOOP
                 DROP
            LOOP
        -1 +TO nd ;

: SUM-DIVISORS ( -- d )  0. nd 0 ?DO  divisors{{ I }} D+  LOOP ;

: .PERFECT ( -- )
        CR ." Root = " n    2 .R
        ." , x1 = "    x1 #10 .R
        ." , x2 = "    x2 #10 .R
        ." , A = x1 * x2 = " x1 x2 UM* (n,3) ;

: SETUP ( n -- )
        TO n
        n 1- 2^x    TO x1
        n    2^x 1- TO x2 ;

: TEST ( n -- )
        SETUP
        BUILD-x1 BUILD-x2 BUILD-DIVISORS SUM-DIVISORS  
        x1 x2 UM* D=  IF .PERFECT ENDIF ;

: .PERFECTS ( -- ) #32 1 DO  I TEST  LOOP ;

: .ABOUT  CR ." Try: .PERFECTS"
          CR ." .X1 and .X2 show divisors of these numbers." ;

                .ABOUT

\                             (* End of Source *)



Thu, 28 Aug 2003 04:02:46 GMT  
 Perfect Numbers
Oeps. Change this:

CREATE divisors{{ 1470 2* CELLS ALLOT

( For some reason it didn't crash with iForth ... )

C:\TEMP\gforth.049>gforth-f
GForth 0.4.9, Copyright (C) 1998 Free Software Foundation, Inc.
GForth comes with ABSOLUTELY NO WARRANTY; for details type `license'
Type `bye' to exit
include perfect.fs
Try: .PERFECTS
.X1 and .X2 show divisors of these numbers. ok
.perfects
Root =  1, x1 =          1, x2 =          1, A = x1 * x2 = 1
Root =  2, x1 =          2, x2 =          3, A = x1 * x2 = 6
Root =  3, x1 =          4, x2 =          7, A = x1 * x2 = 28
Root =  5, x1 =         16, x2 =         31, A = x1 * x2 = 496
Root =  7, x1 =         64, x2 =        127, A = x1 * x2 = 8128
Root = 13, x1 =       4096, x2 =       8191, A = x1 * x2 = 33550336
Root = 17, x1 =      65536, x2 =     131071, A = x1 * x2 = 8589869056
Root = 19, x1 =     262144, x2 =     524287, A = x1 * x2 = 137438691328
Root = 31, x1 = 1073741824, x2 = 2147483647, A = x1 * x2 = 2305843008139952128
1856 ms elapsed ok

-marcel



Thu, 28 Aug 2003 05:16:24 GMT  
 Perfect Numbers
How about some Forth routines to calculate Amicable Numbers???

If you add together all the numbers that divide evenly into
number A (excluding A itself), you get number B. Now if you
add together all the numbers that divide evenly into number
B (exluding B itself), and you get number A again...then
A and B are an Amicable Number pair... The smallest pair is
220 and 284, which were known in the time of Pythagoras.

Fermat and Euler found several pairs of Amicable Numbers in
their day. There is a formula due to the Arab mathematician
Thabit Ibn Qurra, who lived from 826 A.D. to 901 A.D. that
will find *some* of the Amicable Number pairs...but *not*
all of them. The following describes this formula:

Let p(n) = (3 * 2**n -1) and q(n) = (9 * 2**(2*n-1) - 1) for
any "n" greater than one. If p(n-1) and p(n) and q(n) are all
three *prime* numbers, then (2**n)*p(n)*p(n-1) and (2**n)*q(n)
are a pair of Amicable Numbers.

This formula only finds three or four Amicable Number pairs
with less than a dozen digits in each number. There are at
least 60 pairs less than 1,000,000...so obviously this formula
does *not* find all pairs...

--
+-------------------------------------------------------------+

+-------------------------------------------------------------+



Thu, 28 Aug 2003 19:20:39 GMT  
 Perfect Numbers
\ This problem is O(n^2).
\ The following naive algorithm is not practical for n > 1,000,000.

\ -marcel

[DEFINED] -work [IF] -work [THEN] MARKER -work

0 [IF]

        comp.lang.forth #52160 (1 more)
        Date: Sun Mar 11 12:20:39 CET 2001


        Subject: Amicable Numbers (Was: Perfect Numbers)
        Lines: 29

        How about some Forth routines to calculate Amicable Numbers???

        If you add together all the numbers that divide evenly into
        number A (excluding A itself), you get number B. Now if you
        add together all the numbers that divide evenly into number
        B (exluding B itself), and you get number A again...then
        A and B are an Amicable Number pair... The smallest pair is
        220 and 284, which were known in the time of Pythagoras.

        Fermat and Euler found several pairs of Amicable Numbers in
        their day. There is a formula due to the Arab mathematician
        Thabit Ibn Qurra, who lived from 826 A.D. to 901 A.D. that
        will find *some* of the Amicable Number pairs...but *not*
        all of them. The following describes this formula:

        Let p(n) = (3 * 2**n -1) and q(n) = (9 * 2**(2*n-1) - 1) for
        any "n" greater than one. If p(n-1) and p(n) and q(n) are all
        three *prime* numbers, then (2**n)*p(n)*p(n-1) and (2**n)*q(n)
        are a pair of Amicable Numbers.

        This formula only finds three or four Amicable Number pairs
        with less than a dozen digits in each number. There are at
        least 60 pairs less than 1,000,000...so obviously this formula
        does *not* find all pairs...

        --
        +-------------------------------------------------------------+

        +-------------------------------------------------------------+

[THEN]

:  amiga     ( a -- b ) LOCAL a  0  a 1 ?DO  a I MOD 0= IF  I +  ENDIF  LOOP ;
:  amicable? ( a -- ? ) DUP amiga amiga = ;
: .amigas    ( a --   ) CR ."     (" DUP 0 .R ." ," amiga 0 .R ." )" ;

: TEST<n ( n -- )
        DUP 3 < ABORT" n should be larger than 2"
        CR ." Amicable Numbers < " DUP U>D (n,3) ." .."
        2 ?DO  I amicable? IF I .amigas ENDIF  LOOP ;

0 [IF]
Amicable Numbers < 100,000 ..
    (6,6)
    (28,28)
    (220,284)
    (284,220)
    (496,496)
    (1184,1210)
    (1210,1184)
    (2620,2924)
    (2924,2620)
    (5020,5564)
    (5564,5020)
    (6232,6368)
    (6368,6232)
    (8128,8128)
    (10744,10856)
    (10856,10744)
    (12285,14595)
    (14595,12285)
    (17296,18416)
    (18416,17296)
    (63020,76084)
    (66928,66992)
    (66992,66928)
    (67095,71145)
    (69615,87633)
    (71145,67095)
    (76084,63020)
    (79750,88730)
    (87633,69615)
    (88730,79750)
470.376 seconds elapsed. ok
[THEN]

\ EOF



Fri, 29 Aug 2003 04:42:40 GMT  
 Perfect Numbers
\ The first 236 Amicable Numbers.
\ With thanks to Hisanori Mishima and Don Knuth.

[DEFINED] -work [IF] -work [THEN] MARKER -work

0 [IF]

        comp.lang.forth #52160 (1 more)
        Date: Sun Mar 11 12:20:39 CET 2001


        Subject: Amicable Numbers (Was: Perfect Numbers)
        Lines: 29

        How about some Forth routines to calculate Amicable Numbers???

        If you add together all the numbers that divide evenly into
        number A (excluding A itself), you get number B. Now if you
        add together all the numbers that divide evenly into number
        B (exluding B itself), and you get number A again...then
        A and B are an Amicable Number pair... The smallest pair is
        220 and 284, which were known in the time of Pythagoras.

        Fermat and Euler found several pairs of Amicable Numbers in
        their day. There is a formula due to the Arab mathematician
        Thabit Ibn Qurra, who lived from 826 A.D. to 901 A.D. that
        will find *some* of the Amicable Number pairs...but *not*
        all of them. The following describes this formula:

        Let p(n) = (3 * 2**n - 1) and q(n) = (9 * 2**(2*n-1) - 1) for
        any "n" greater than one. If p(n-1) and p(n) and q(n) are all
        three *prime* numbers, then (2**n)*p(n)*p(n-1) and (2**n)*q(n)
        are a pair of Amicable Numbers.

        This formula only finds three or four Amicable Number pairs
        with less than a dozen digits in each number. There are at
        least 60 pairs less than 1,000,000...so obviously this formula
        does *not* find all pairs...

        --
        +-------------------------------------------------------------+

        +-------------------------------------------------------------+

        ===============================================================

                   From the web pages of Hisanori Mishima

        ===============================================================

        1. Sums of divisors

        Let integer n be factorized as

             e1     e2           ek
        n = p    * p    * ... * p  
             1      2            k

        then the sums of divisors of n is represented as the following formula,

          ---
          \  n = a  * a  * ... * a
          /       1    2          k
          ---
        where

               ek+1
             p      - 1
              k
        a  = ----------
         k     p  - 1
                k

        Especially,

          ek+1        
        p      - 1
         k             ek           2
        ---------- = p    + ... + p   + p  + 1
          p  - 1      k            k     k
           k

                 e
        so if n=p  then

           ---      e          2
           \  n  = p  + ... + p  + p + 1.
           /
           ---

        2. When we compute the sum of divisors during factorization of n,
        this formula is easier to handle. The algorithm is the following,

        1. Let w=1 (\sigma(n) is stored in w).
        2. p=prmdiv(n)

           If p|n then
             w = w*p+1
             n = n/p

        3. If p does not divide n, terminate.
                      e          2
           The value p  + ... + p  + p + 1 is stored in w.
        4. goto 2.

                                          e1    e2         ek
        The value of \sigma(n) where n = p   * p  * ... * p  
                                          1     2          k
        is calculated by the following procedure.

        1. Let s=1 (\sigma(n) is stored in s).
        2. Let p be the smallest divisor of n.
           If p=1 then terminate.
        3. repeat 1. through 4. of above procedure.
           If the condition 3. is held, let

           s = s * w.

        4. goto 2.

        3. The program is the following.

        10   fnSigma(N)
        20   local S,W,P
        30   S=1
        40   W=1:P=prmdiv(N)

        60   S=S*W
        70   if N=1 then return(S) else goto 40


        Hisanori Mishima

[THEN]

\ Knuth, Semi-numerical algorithms, pg. 365.
\ We need all primes < sqrt(10^8) = 10,000

0 VALUE #primes
CREATE trial-divisors #6543 CELLS ALLOT

: PRIME? ( n -- bool )
        LOCAL N
        N SQRT 1+ 2 ?DO  N I MOD 0= IF  FALSE UNLOOP EXIT  
                                 ENDIF  
                   LOOP  TRUE ;

: INIT-DIVISORS ( -- )
        2 trial-divisors !+  3 SWAP !+  5 SWAP !+
        3 TO #primes
        $10000 7 DO  I PRIME? IF  I SWAP !+  1 +TO #primes  ENDIF  LOOP
        $10000 SWAP !  1 +TO #primes ;

        INIT-DIVISORS   FORGET INIT-DIVISORS

: prmdiv ( N -- n )
        0 0 0 LOCALS| dk t k n |
        BEGIN   n 1 <>

                n dk /MOD SWAP 0= IF  DROP dk EXIT  ENDIF
                dk <= IF  n EXIT  ENDIF
                1 +TO k
        REPEAT  n ;

\ The sum of *all* divisors of n ( 1 + ... + n )
\ n should be > 2
: SIGMA-MISHIMA ( n -- sum )
        DUP 3 < IF  1+ EXIT  ENDIF
        0 1 LOCALS| s p n |
        BEGIN
          1 ( w)
          n prmdiv TO p
            BEGIN  n p MOD 0=
            WHILE  ( w) p * 1+
                   n p / TO n
            REPEAT
          ( w) s * TO s
          n 1 =
        UNTIL s ;

:  amiga     ( a -- b ) DUP SIGMA-MISHIMA SWAP - ;
:  amicable? ( a -- ? ) DUP amiga DUP >R amiga DUP >R = 2R> > AND ;

: .amigas    ( a n -- ) CR 4 .R ."     ( "
                        DUP   U>D (n,3) ." :: "
                        amiga U>D (n,3) ." )" ;

: TEST<n ( n -- )
        DUP 3 < ABORT" n should be larger than 2"
        0 LOCAL nr
        CR ." Amicable Numbers < " DUP U>D (n,3) ." .."
        TIMER-RESET
          2 ?DO  I amicable? IF I nr .amigas 1 +TO nr ENDIF  LOOP
        CR .ELAPSED ;

0 [IF]

Amicable Numbers < 100,000,000 ..
   1    ( 220 :: 284 )
   2    ( 1,184 :: 1,210 )
   3    ( 2,620 :: 2,924 )
   4    ( 5,020 :: 5,564 )
   5    ( 6,232 :: 6,368 )
   6    ( 10,744 :: 10,856 )
   7    ( 12,285 :: 14,595 )
   8    ( 17,296 :: 18,416 )
   9    ( 63,020 :: 76,084 )
  10    ( 66,928 :: 66,992 )
  11    ( 67,095 :: 71,145 )
  12    ( 69,615 :: 87,633 )
  13    ( 79,750 :: 88,730 )
  14    ( 100,485 :: 124,155 )
  15    ( 122,265 :: 139,815 )
  16    ( 122,368 :: 123,152 )
  17    ( 141,664 :: 153,176 )
  18    ( 142,310 :: 168,730 )
  19    ( 171,856 :: 176,336 )
  20    ( 176,272 :: 180,848 )
  21    ( 185,368 :: 203,432 )
  22    ( 196,724 :: 202,444 )
  23    ( 280,540 :: 365,084 )
  24    ( 308,620 :: 389,924 )
  25    ( 319,550 :: 430,402 )
  26    ( 356,408 :: 399,592 )
  27    ( 437,456 :: 455,344 )
  28    ( 469,028 :: 486,178 )
  29    ( 503,056 :: 514,736 )
  30    ( 522,405 :: 525,915 )
  31    ( 600,392 :: 669,688 )
  32    ( 609,928 :: 686,072 )
  33    ( 624,184 :: 691,256 )
  34    ( 635,624 :: 712,216 )
  35    ( 643,336 :: 652,664 )
  36    ( 667,964 :: 783,556 )
  37    ( 726,104 :: 796,696 )
  38    ( 802,725 :: 863,835 )
  39    ( 879,712 :: 901,424 )
  40    ( 898,216 :: 980,984 )
  41    ( 947,835 :: 1,125,765 )
  42    ( 998,104 :: 1,043,096 )
  43    ( 1,077,890 :: 1,099,390 )
  44    ( 1,154,450 :: 1,189,150 )
  45    ( 1,156,870 :: 1,292,570 )
  46    ( 1,175,265 :: 1,438,983 )
  47    ( 1,185,376 :: 1,286,744 )
  48    ( 1,280,565 :: 1,340,235 )
  49    ( 1,328,470 :: 1,483,850 )
  50    ( 1,358,595 :: 1,486,845 )
  51    ( 1,392,368 :: 1,464,592 )
  52    ( 1,466,150 :: 1,747,930 )
  53    ( 1,468,324 :: 1,749,212 )
  54    ( 1,511,930 :: 1,598,470 )
  55    ( 1,669,910 :: 2,062,570 )
  56    ( 1,798,875 :: 1,870,245 )
  57    ( 2,082,464 :: 2,090,656 )
  58    ( 2,236,570 :: 2,429,030 )
  59    ( 2,652,728 :: 2,941,672 )
  60    ( 2,723,792 :: 2,874,064 )
  61    ( 2,728,726 :: 3,077,354 )
  62    ( 2,739,704 :: 2,928,136 )
  63    ( 2,802,416 :: 2,947,216 )
  64    ( 2,803,580 :: 3,716,164 )
  65    ( 3,276,856 :: 3,721,544 )
  66    ( 3,606,850 :: 3,892,670 )
  67    ( 3,786,904 :: 4,300,136 )
  68    ( 3,805,264 :: 4,006,736 )
  69    ( 4,238,984 :: 4,314,616 )
  70    ( 4,246,130 :: 4,488,910 )
  71    ( 4,259,750 :: 4,445,050 )
  72    ( 4,482,765 :: 5,120,595 )
  73    ( 4,532,710 :: 6,135,962 )
  74    ( 4,604,776 :: 5,162,744 )
  75    ( 5,123,090 :: 5,504,110 )
  76    ( 5,147,032 :: 5,843,048 )
  77    ( 5,232,010 :: 5,799,542 )
  78    ( 5,357,625 :: 5,684,679 )
  79    ( 5,385,310 :: 5,812,130 )
  80    ( 5,459,176 :: 5,495,264 )
  81    ( 5,726,072 :: 6,369,928 )
  82    ( 5,730,615 :: 6,088,905 )
  83    ( 5,864,660 :: 7,489,324 )
  84    ( 6,329,416 :: 6,371,384 )
  85    ( 6,377,175 :: 6,680,025 )
  86    ( 6,955,216 :: 7,418,864 )
  87    ( 6,993,610 :: 7,158,710 )
  88    ( 7,275,532 :: 7,471,508 )
  89    ( 7,288,930 :: 8,221,598 )
  90    ( 7,489,112 :: 7,674,088 )
  91    ( 7,577,350 :: 8,493,050 )
  92    ( 7,677,248 :: 7,684,672 )
  93    ( 7,800,544 :: 7,916,696 )
  94    ( 7,850,512 :: 8,052,488 )
  95    ( 8,262,136 :: 8,369,864 )
  96    ( 8,619,765 :: 9,627,915 )
  97    ( 8,666,860 :: 10,638,356 )
  98    ( 8,754,130 :: 10,893,230 )
  99    ( 8,826,070 :: 10,043,690 )
 100    ( 9,071,685 :: 9,498,555 )
 101    ( 9,199,496 :: 9,592,504 )
 102    ( 9,206,925 :: 10,791,795 )
 103    ( 9,339,704 :: 9,892,936 )
 104    ( 9,363,584 :: 9,437,056 )
 105    ( 9,478,910 :: 11,049,730 )
 106    ( 9,491,625 :: 10,950,615 )
 107    ( 9,660,950 :: 10,025,290 )
 108    ( 9,773,505 :: 11,791,935 )
 109    ( 10,254,970 :: 10,273,670 )
 110    ( 10,533,296 :: 10,949,704 )
 111    ( 10,572,550 :: 10,854,650 )
 112    ( 10,596,368 :: 11,199,112 )
 113    ( 10,634,085 :: 14,084,763 )
 114    ( 10,992,735 :: 12,070,305 )
 115    ( 11,173,460 :: 13,212,076 )
 116    ( 11,252,648 :: 12,101,272 )
 117    ( 11,498,355 :: 12,024,045 )
 118    ( 11,545,616 :: 12,247,504 )
 119    ( 11,693,290 :: 12,361,622 )
 120    ( 11,905,504 :: 13,337,336 )
 121    ( 12,397,552 :: 13,136,528 )
 122    ( 12,707,704 :: 14,236,136 )
 123    ( 13,671,735 :: 15,877,065 )
 124    ( 13,813,150 :: 14,310,050 )
 125    ( 13,921,528 :: 13,985,672 )
 126    ( 14,311,688 :: 14,718,712 )
 127    ( 14,426,230 :: 18,087,818 )
 128    ( 14,443,730 :: 15,882,670 )
 129    ( 14,654,150 :: 16,817,050 )
 130    ( 15,002,464 :: 15,334,304 )
 131    ( 15,363,832 :: 16,517,768 )
 132    ( 15,938,055 :: 17,308,665 )
 133    ( 16,137,628 :: 16,150,628 )
 134    ( 16,871,582 :: 19,325,698 )
 135    ( 17,041,010 :: 19,150,222 )
 136    ( 17,257,695 :: 17,578,785 )
 137    ( 17,754,165 :: 19,985,355 )
 138    ( 17,844,255 :: 19,895,265 )
 139    ( 17,908,064 :: 18,017,056 )
 140    ( 18,056,312 :: 18,166,888 )
 141    ( 18,194,715 :: 22,240,485 )
 142    ( 18,655,744 :: 19,154,336 )
 143    ( 20,014,808 :: 21,457,192 )
 144    ( 20,022,328 :: 22,823,432 )
 145    ( 20,308,995 :: 20,955,645 )
 146    ( 21,448,630 :: 23,030,090 )
 147    ( 22,227,075 :: 24,644,925
...

read more »



Sat, 30 Aug 2003 08:04:21 GMT  
 
 [ 6 post ] 

 Relevant Pages 

1. New user need help with perfect numbers.

2. Perfect Numbers

3. ASM to test Perfect Number

4. Finding perfect numbers

5. Perfect Number

6. Perfect Numbers, Complexity

7. Yet another perfect number program

8. Yet another perfect number program

9. perfect numbers

10. Numbers Numbers Numbers

11. Perfect example of why subclassing can be dangerous...

12. Golf - The perfect problem to compare languages with?

 

 
Powered by phpBB® Forum Software