Calculators
Linear Equation Solver
Solve one-variable linear equations and two-variable systems.
Solve one linear equation
Enter coefficients for ax + b = c.
Result
x = 4
Solve two linear equations
Enter ax + by = c and dx + ey = f.
System result
x = 2, y = 1
Determinant: -3
About This Tool
Use this solver for two closely related algebra tasks: finding x in a linear equation written ax + b = c, and solving two simultaneous equations written ax + by = c and dx + ey = f. Keeping both tasks together makes it easier to move from introductory one-variable equations to systems without creating separate thin pages. The calculations run locally in your browser and accept integer, decimal, zero, and negative coefficients.
How To Use It
- For one variable, enter a, b, and c for ax + b = c. The solver isolates x when a is nonzero and identifies degenerate equations when a is zero.
- For a two-variable system, enter the six coefficients for ax + by = c and dx + ey = f. The solver uses determinants to find x and y when the equations have one intersection.
- Read the classification as well as the numbers. Parallel inconsistent equations have no solution, while equations representing the same line have infinitely many solutions.
Examples
Solve 2x + 3 = 11
Subtract 3 from both sides to get 2x = 8, then divide by 2. The solution is x = 4.
Solve a two-equation system
For 2x + y = 5 and x − y = 1, adding the equations gives 3x = 6, so x = 2. Substitution then gives y = 1.
No solution
x + 2y = 3 and 2x + 4y = 7 have proportional left sides but incompatible constants. They represent parallel distinct lines, so no pair x,y satisfies both.
Infinitely many solutions
x + 2y = 3 and 2x + 4y = 6 describe the same line because every coefficient in the second equation is twice the first. Every point on that line satisfies both equations.
Useful Notes
One-variable method
Starting with ax + b = c, subtract b to obtain ax = c − b, then divide by a: x = (c − b)/a. If a = 0, the equation either reduces to a true statement such as 3 = 3, giving infinitely many x values, or a contradiction such as 3 = 4, giving no solution.
Two-variable determinant method
For ax + by = c and dx + ey = f, the coefficient determinant is D = ae − bd. When D is nonzero, Cramer's rule gives x = (ce − bf)/D and y = (af − cd)/D. The calculator also reports the determinant for unique solutions.
Why determinant zero matters
A zero determinant means the coefficient rows are dependent, so the lines do not cross at exactly one point. Comparing the constants then distinguishes coincident equations with infinitely many solutions from inconsistent parallel equations with no solution.
Decimals and numerical precision
Decimal coefficients are supported with JavaScript floating-point arithmetic. The system solver uses a scale-aware tolerance when deciding whether a computed determinant is effectively zero, reducing false classifications caused by tiny rounding noise. Extremely large coefficients or results outside the reliable numeric range are rejected.
FAQ
Can this solve equations with negative coefficients?
Yes. Negative, zero, integer, and decimal coefficients are supported as long as they are finite numbers.
What does no solution mean?
It means the equation conditions contradict each other. For a two-variable system, this commonly occurs when the equations describe distinct parallel lines.
What does infinitely many solutions mean?
It means the equations do not determine one unique value or point. In a two-variable system, both equations describe the same line.
Does this solve nonlinear equations?
No. This page is specifically for first-degree linear equations and 2×2 linear systems. Use the Quadratic Equation Solver when an equation contains an x² term.
Related Tools
Quadratic Equation Solver
Solve quadratic equations and inspect roots, discriminant, and vertex.
Scientific Calculator
Scientific math functions with degree and radian modes.
Fraction Calculator
Calculate and simplify arithmetic with two fractions.
Ratio & Proportion Calculator
Simplify ratios and solve proportions with a missing value.