Diophantine Solver

Integer solutions of ax+by=c

3x + 5y = 11
gcd(a, b)
1
Bézout identity
3·(2) + 5·(-1) = 1
General solution
x = 2 + 5t
y = 1 − 3t

for every integer t

Sample solutions (x, y)
(-8, 7)(-3, 4)(2, 1)(7, -2)(12, -5)
a·x + b·y = cA coordinate grid showing the line a·x + b·y = c. Integer solutions are the lattice points (whole-number coordinates) that lie exactly on this line; they are highlighted and spaced evenly apart by the step (b/g, −a/g).

Über diesen Rechner

The Diophantine Solver finds all integer solutions of the linear equation a·x + b·y = c. It uses the extended Euclidean algorithm to compute gcd(a, b) and Bézout coefficients, reports whether a solution exists, and gives the full one-parameter family x = x0 + (b/g)·t, y = y0 − (a/g)·t with sample solutions and a lattice-point visual.

Häufige Beispiele

  • 3x + 5y = 11 → x = 2 + 5t, y = 1 − 3t
  • 6x + 9y = 15 → gcd 3 divides 15, x = 4 + 3t, y = −1 − 2t
  • 2x + 4y = 5 → gcd 2 does not divide 5, no integer solutions
  • 0x + 5y = 10 → y = 2, x is free (x = t)
  • 0x + 0y = 0 → every integer pair (x, y) is a solution