Around the year 820, a Persian mathematician working at the House of Wisdom in Baghdad — Muhammad ibn Musa al-Khwarizmi — wrote a book whose title contained two Arabic words that would shape Western mathematics: al-jabr (restoration, the operation of moving a subtracted term to the other side of an equation) and al-muqabala (balancing, the operation of canceling like terms). Eight hundred years later, the French lawyer-turned-mathematician François Viète completed the move by replacing the unknown numbers with letters — and from that point onward, mathematics had a way of talking about quantities without committing to which numbers they were.
An equation is a statement that two expressions are equal: 3x + 5 = 14, a² + b² = c², F = ma. A variable is a letter that stands in for a number you do not yet know — sometimes because you are about to determine it, sometimes because the equation is meant to hold for every value, and the distinction between solving and proving corresponds exactly to which case you are in. The discipline of solving — finding the values that make an equation true — has a layered history. Linear equations (degree 1) yield to a single inversion. Quadratic equations (degree 2) gave us the quadratic formula, known in some form to Babylonian scribes 4000 years ago. Cubic equations (degree 3) were cracked in sixteenth-century Italy by Tartaglia and stolen-and-published by Cardano in 1545, in one of the most disreputable episodes of mathematical history. Quartic equations yielded soon after to Cardano's student Ferrari. The quintic (degree 5) and beyond resisted every attempt for two centuries, until Évariste Galois — killed at twenty in a duel — proved that no general formula in radicals exists, by inventing group theory in the process. The deeper move beneath all this technique was conceptual: variables made mathematics modular. A single statement could now stand for infinitely many specific cases, and the same equation could be applied across physics, finance, biology, and engineering by reinterpreting what each letter referred to.
Variables are now baked into every programming language — let x = 5 is the algebraic move, made operational. SAT solvers and SMT solvers mechanically find variable assignments that satisfy systems of equations and inequalities, running everything from chip verification to airline scheduling. Computer algebra systems (Mathematica, SymPy, Maple) manipulate equations symbolically rather than numerically, descending in a direct line from al-Khwarizmi's al-jabr. The shift from number to equation — from what is the answer to what relationship constrains the answer — is one of the most consequential cognitive technologies humans have ever developed.