Coordinate Forms
Affine
Affine form refers to the regular form of coordinates on an -plane.
Problem
For elliptic curves, point addition is done very often as it is considered cheap. To calculate point addition in affine form, we must compute the slope . However, calculating field inverses or the in this case is expensive, so we want to prevent the calculation of inverses as much as possible.
Solution
When calculating a series of point operations, we convert points to a different intermediate form that does not require field inverses for point operations and for the final result, we revert back to affine. Calculating through these intermediate forms does not cost any inverse operations; however, converting the forms back to affine will cost one inverse operation.
The reasoning for why our intermediate forms do not calculate inverses is quite simple: when calculating an operation, the resulting formulas of the final and are manipulated to use the same denominator (projective) or related denominators (Jacobian & XYZZ). This denominator will then be calculated and stored as a continuous separate value .
We will provide an explanation of projective coordinates to ease our way into understanding Jacobian coordinates, yet in reality for our elliptic curves, we use Jacobian coordinates as it yields much simpler results to work with.
Projective
In projective form, affine points of are redefined as . In practice, projective form is stored as . With this conversion, the elliptic curve equation is changed to:
Affine Projective
Projective Affine
Calculating Operations
Refer to Hyperelliptic for Projective points on the best practices on how to calculate addition and double operations on projective coordinates.
Jacobian
In Jacobian form, affine points of are redefined as . In practice, Jacobian form is stored as . With this conversion, the elliptic curve equation is changed to:
Affine Jacobian
Jacobian Affine
Calculating Operations
Refer to Hyperelliptic for Jacobian points on the best practices on how to calculate addition and double operations on Jacobian coordinates.
XYZZ - Extended Jacobian
XYZZ form also known as "Extended Jacobian form" follows the same calculation and reasoning as Jacobian, but with one minor difference: Extended Jacobian is instead stored as to provide better performance of computations with a slight tradeoff in memory.
Affine XYZZ
Jacobian XYZZ
Calculating Operations
Refer to Hyperelliptic for XYZZ points on the best practices on how to calculate addition and double operations on XYZZ coordinates.
Summary of all forms:
Affine
Projective
Jacobian
Extended Jacobian (XYZZ)
References
Written by Ashley Jeong of A41
Last updated