changed generation increment size to 1000 to get larger values in knapsack
Changed primary type from Double to BigInteger
bug fix: order of operations in derivePublicKey. Additional contstraints on r during generation.
added check for r to avoid identical priv and pub keys