Elliptic Curve Point Add Calculator

Adding points on an elliptic curve is the core operation of modern public-key cryptography. Over a prime field, two points P and Q on the curve y^2 = x^3 + ax + b combine to a third point R, using a slope computed with modular arithmetic and a modular inverse. When the two points coincide, the tangent (doubling) formula applies. This calculator takes the curve parameters, the prime modulus, and the two points, then returns the sum R, handling the point at infinity. All arithmetic uses arbitrary-precision BigInt.

-
-
-
-

Point addition formula (over GF(p))

distinct P, Q: s = (y2 - y1) * inverse(x2 - x1) mod p
doubling P = Q: s = (3*x1^2 + a) * inverse(2*y1) mod p
x3 = (s^2 - x1 - x2) mod p
y3 = (s*(x1 - x3) - y1) mod p
P + (-P) = point at infinity (identity)

The modular inverse is found with the extended Euclidean algorithm. The point at infinity is the group identity. Each point is checked against y^2 = x^3 + ax + b mod p before adding.

Elliptic curve context

  • Point addition forms an abelian group with the point at infinity as identity.
  • Doubling uses the tangent slope; distinct points use the secant slope.
  • Division in the field is multiplication by a modular inverse.
  • Repeated addition (scalar multiplication) underlies ECDH and ECDSA.
  • Standard curves appear in NIST SP 800-186 and FIPS 186-5.

Elliptic curve point add: frequently asked questions

What is elliptic-curve point addition?

On an elliptic curve over a prime field, you can add two points P and Q to get a third point R on the same curve. Geometrically you draw the line through P and Q, find the third intersection with the curve, and reflect it across the x-axis. Algebraically this is done with modular arithmetic.

How does the formula change for doubling?

When P equals Q (point doubling), the line is the tangent at P, so the slope uses calculus: s = (3x^2 + a) / (2y) mod p. For two distinct points the slope is s = (y2 - y1) / (x2 - x1) mod p. Division means multiplying by the modular inverse.

What is the point at infinity?

The point at infinity is the identity element of the group: P plus the point at infinity equals P. It arises when you add a point to its own negative (same x, opposite y), where the line is vertical and has no third finite intersection. This calculator reports it as the result in that case.

What curve parameters should I use?

Enter the curve coefficients a and b and a prime modulus p for the curve y^2 = x^3 + ax + b. Real curves such as secp256k1 (a=0, b=7) use a 256-bit prime; this calculator handles arbitrary-size integers with BigInt. Points must satisfy the curve equation mod p.

Is point addition the basis of ECC security?

Yes. Repeated point addition (scalar multiplication) is easy forward but hard to reverse: recovering the scalar from the result is the elliptic-curve discrete logarithm problem, which underpins ECDH and ECDSA. Standard curves are specified in NIST SP 800-186 and FIPS 186-5.

Official sources

Reviewed by the CalculatorHub team, edited by James Graham, 17 June 2026. See our methodology.