
 Various statistics for generating an RSA Public-Private key pair ,encrypting an arbitrary message using the public key and decrypting the
 message using the private key.

 The table below shows the time for above operations as a function of key size :
 Message Size = 250 bytes
                                                       TIME in milliseconds
                     **************************************************************************************
       KEY SIZE          Public-Private key generation        Encryption             Decryption 
         128                          142                       489                    485
         256                          312                       3089                   3107
         512                          1054                      22212                  22732
         768                          2316                      70360                  72163         
         1024                         5380                      168559                 167139

     CONCLUSION : As the key size increases time for key generation, encryption and decryption increases. 
                  

 The table below shows the time for encrypting and decrypting various size messages for two key sizes :

     KEY SIZE = 32 bits
                                                             TIME in milliseconds
                                           **************************************************************
                Message Size in bytes               Time for encryption             Time for decryption
                   250                                     58                                41
                   500                                     104                               49
                   750                                     126                               79
                   1000                                    146                               90    
                   2500                                    317                               198
                   4000                                    461                               318 

     KEY SIZE = 64 bits

                Message Size in bytes               Time for encryption             Time for decryption
                    250                                    149                                123
                    500                                    219                                191
                    750                                    322                                349
                    1000                                   422                                395
                    2500                                   1031                               935
                    4000                                   1604                               1510

    CONCLUSION : Increase in message size increases the time for both encryption and decryption. this time also increases as key size 
                 increases.

 The table below shows the time for Public-Private key generation for various values of "probability of P, Q being prime" variable in the 
 constructor of the BigInteger class :
            
            Probability  = 1 - 1/power(2,certainity)
            KEY SIZE =32 bits
                                                      
   Certainity of P and Q being prime              Time in milliseconds for Public-Private key generation                                                        5                                                11
                  10                                                22
                  15                                                23
                  20                                                31
                  25                                                38
                  30                                                39
                  50                                                50    
    CONCLUSION : Probability increases with certainity. As the probability of P and q being prime increases , time for key generation 
                 increases. The increase in time is due to increase in time for searching two prime numbers P and Q with the given 
                 probability.


    GRAPHS : plot1.png : Key Size Vs Key generation time
             plot2.png : Key Size Vs Encryption time
             plot1.png : Key Size Vs Decryption time
             plot1.png : Message Size Vs Encryption time[Key size=32 bits]
             plot1.png : Message Size Vs Decryption time[Key size=64 bits]
             plot1.png : Message Size Vs Encryption time
             plot1.png : Message Size Vs Decryption time
             plot1.png :Certainity Vs Key generation time

