Twisted Edwards curve
In algebraic geometry, the twisted Edwards curves are plane models of elliptic curves, a generalisation of Edwards curves introduced by Bernstein, Birkner, Joye, Lange and Peters in 2008. The curve set is named after mathematician Harold M. Edwards. Elliptic curves are important in public key cryptography and twisted Edwards curves are at the heart of an electronic signature scheme called EdDSA that offers high performance while avoiding security problems that have surfaced in other digital signature schemes. Definition. Each twisted Edwards curve is a twist of an Edwards curve. A twisted Edwards curve formula_1 over a field  formula_2 with formula_3 is an affine plane curve defined by the equation: where formula_5 are distinct non-zero elements of formula_2. The special case formula_7 is "untwisted", because the curve reduces to an ordinary Edwards curve. Every twisted Edwards curve is birationally equivalent to an elliptic curve in Montgomery form and vice versa. Group law. As for all elliptic curves, also for the twisted Edwards curve, it is possible to do some operations between its points, such as adding two of them or doubling (or tripling) one. The results of these operations are always points that belong to the curve  itself. In the following sections some formulas are given to obtain the coordinates of a point resulted from an addition between two other points (addition), or the coordinates of point resulted from a doubling of a single point on a curve. Addition on twisted Edwards curves. Let formula_2 be a field with characteristic different from 2. Let formula_9 and formula_10 be points on the twisted Edwards curve. The equation of twisted Edwards curve is written as; The sum of these points formula_12 on "E" is: The neutral element is (0,1) and the negative of formula_9 is formula_15 These formulas also  work for doubling. If "a" is a "square" in formula_2 and "d" is a "non-square" in  formula_2, these formulas are "complete": this means that they can be used for all pairs of points without exceptions; so they work for doubling as well, and neutral elements and negatives are accepted as inputs. Example of addition Given the following twisted Edwards curve with "a" = 3 and "d" = 2: it is possible to add the points formula_19 and formula_20 using the formula given above. The result is a point P that has coordinates: Doubling on twisted Edwards curves. "Doubling" can  be performed with exactly the same formula as addition. Doubling of a point formula_9 on the curve E is: formula_24 where Denominators in doubling are simplified using the curve equation formula_26. This reduces the power from 4 to 2 and allows for more efficient computation. Example of doubling Considering the same twisted Edwards curve given in the previous example, with a=3 and d=2, it is possible to double the point formula_19. The point 2P obtained using the formula above has the following coordinates: It is easy to see, with some little computations, that the point formula_30 belongs to the curve  formula_18. Extended coordinates. There is another kind of coordinate system with which a point in the twisted Edwards curves can be represented. A point formula_32 on formula_33 is represented as "X", "Y", "Z", "T" satisfying the following equations "x" = "X"/"Z", "y" = "Y"/"Z", "xy" = "T"/"Z". The coordinates of the point ("X":"Y":"Z":"T") are called the extended twisted Edwards coordinates. The identity element is represented by (0:1:1:0). The negative of a point is (−"X":"Y":"Z":−"T"). Inverted twisted Edwards coordinates. The coordinates of the point formula_34 are called the inverted twisted Edwards coordinates on the curve formula_35with formula_36; this point to the  affine one formula_37 on "E". Bernstein and Lange introduced these inverted coordinates, for the case a=1 and observed that the coordinates save time in addition. Projective twisted Edwards coordinates. The equation for the projective twisted Edwards curve is given as: formula_38 For "Z" ≠ 0 the point (X:Y:Z) represents the affine point ("x" = "X"/"Z", "y" = "Y"/"Z") on "E". Expressing an elliptic curve in twisted Edwards form saves time in arithmetic, even when the same curve can be expressed in the Edwards form. Addition in projective twisted curves. The addition on a projective twisted Edwards curve is  given by and costs 10Multiplications + 1Squaring + 2D + 7 additions, where the 2D are one multiplication by "a" and one by "d". Doubling on projective twisted curves. Doubling on the projective twisted curve is given by This costs 3Multiplications + 4Squarings + 1D + 7additions, where 1D is a multiplication by a.