Forums

Articles
Create
cancel
Showing results for 
Search instead for 
Did you mean: 

How to Align Multi-Line Equations in Confluence Using LaTeX

Support team_Stiltsoft_
Atlassian Partner
August 1, 2025

Hello again from the LaTeX Math for Confluence (Cloud) team!

If you’ve been following our series, you already know how to write fractions, roots, summations, integrals, and add text to your equations.

Today’s focus: aligning multi-line equations. Often, math derivations or systems of equations span multiple lines. Aligned equations improve readability by lining up operators or equal signs.

Aligning multi-line equations in LaTeX for Confluence

The align environment lets you write several equations aligned on the & symbol:

 

\begin{align}
a &= b + c \\
d &= e - f
\end{align}

This renders two aligned equations with equal signs lined up.

LaTeX - aligned.jpg

Tips:

  • Always use double backslashes (\\) to break lines

  • Use & to align equations on equal signs or any other chosen symbol

  • Use \text{} to add words or comments inside math blocks

Practical examples of aligned multi-line equations in Confluence

Example 1: Basic alignment on equals sign

\begin{align}
ax^2 + bx + c &= 0 \\
x &= \frac{-b \pm \sqrt{b^2 - 4ac}}{2a}
\end{align}

LaTeX - basic alignment.jpg

Example 2: Long equation split across lines

Useful for breaking up lengthy expressions:

\begin{align}
  f(x) &= x^3 + 2x^2 - 5x \\
       &\quad + \frac{1}{x} - 7
\end{align}

LaTeX - long equation split.jpg

Example 3: Equation with explanatory text

You can add comments or explanations between lines using the \text{} command and & to align them:

\begin{align}
c &= \sqrt{a^2 + b^2} \\
&\text{Using Pythagoras theorem with } a = 3,\ b = 4 \\
&= \sqrt{3^2 + 4^2}= \sqrt{9 + 16} = \sqrt{25} = 5
\end{align} 

LaTeX - align text.jpg

Aligned equations are essential when working with derivations, formulas, and systems that span multiple lines. Using the align environment with & and \\ gives your math a clean, readable structure and helps colleagues follow each step without confusion.

If you're using Confluence Cloud, tools like LaTeX Math for Confluence make it easy to add nicely formatted formulas directly in your pages.

📌 Next up in our series: how to use and scale brackets, delimiters, and absolute values in LaTeX.

0 comments

Comment

Log in or Sign up to comment
TAGS
AUG Leaders

Atlassian Community Events