Mathematics
System of equations - formula in LaTeX
A system of two equations joined by a brace on the left. The cases environment aligns rows to the left. If the equals signs must line up exactly, use aligned inside \left\{ and \right. instead, with & before each equals sign. Both need the amsmath package.
LaTeX code
$$
\begin{cases} a_1 x + b_1 y = c_1 \\ a_2 x + b_2 y = c_2 \end{cases}
$$Got this formula in your notes or on a whiteboard? Snap a photo and CamteX turns it into LaTeX. Try it free
What the symbols mean
- unknowns
- coefficients of the first equation
- coefficients of the second equation
A math formula - one of the most frequently typed in assignments, lecture notes and calculus or algebra homework.
Worked example
Adding the equations cancels y, which gives x = 2 straight away and y = 1 from the second equation. The solution sits on the same line as the system, after an arrow.
Other ways to write it
Equals signs lined up exactly; \right. is an invisible right bracket.
\left\{\begin{aligned} 2x + y &= 5 \\ x - y &= 1 \end{aligned}\right.Three equations in three unknowns: just add another row.
\begin{cases} x + y + z = 6 \\ x - y = -1 \\ z - x = 2 \end{cases}The same system in matrix form Ax = b.
\begin{pmatrix} a_1 & b_1 \\ a_2 & b_2 \end{pmatrix}\begin{pmatrix} x \\ y \end{pmatrix} = \begin{pmatrix} c_1 \\ c_2 \end{pmatrix}
LaTeX commands in this formula
\begin{cases}- cases
x_{0}- subscript; wrap several characters in braces
How to use this formula in LaTeX?
- Copy the code with the button above -
$$…$$is centered display math. - Paste it into the CamteX editor, Overleaf or any LaTeX document.
- Inside a sentence, use single
$…$instead of double. - The formula needs the
amsmathpackage - CamteX templates include it in the preamble.
Related formulas - Mathematics
Drawing formulas is faster than typing them.
Draw a formula, table or chart - CamteX AI turns it into ready LaTeX and inserts it into your document.