part7
Class Curve
java.lang.Object
part7.Curve
- public class Curve
- extends java.lang.Object
A class used to represent an elliptic curve of the form
y2=x3+ax+b over Zp
where p is a prime greater than 3.
Note that objects of type Curve
are immutable.
Constructor Summary |
Curve(java.math.BigInteger p,
java.math.BigInteger a,
java.math.BigInteger b)
A constructor to create a canonical representation of an elliptic curve given
a prime p and any values a & b. |
Method Summary |
boolean |
equal(Curve c)
A method to determine if this curve is equal to the curve c . |
java.math.BigInteger |
getA()
|
java.math.BigInteger |
getB()
|
java.math.BigInteger |
getP()
|
java.lang.String |
toString()
|
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Curve
public Curve(java.math.BigInteger p,
java.math.BigInteger a,
java.math.BigInteger b)
throws java.lang.Exception
- A constructor to create a canonical representation of an elliptic curve given
a prime p and any values a & b.
- Throws:
java.lang.Exception
toString
public java.lang.String toString()
getP
public java.math.BigInteger getP()
throws java.lang.Exception
- Throws:
java.lang.Exception
getA
public java.math.BigInteger getA()
throws java.lang.Exception
- Throws:
java.lang.Exception
getB
public java.math.BigInteger getB()
throws java.lang.Exception
- Throws:
java.lang.Exception
equal
public boolean equal(Curve c)
throws java.lang.Exception
- A method to determine if this curve is equal to the curve
c
.
- Throws:
java.lang.Exception