Payload LogoOctree

Cube Root, Square Root, and Nth Root in LaTeX

Date Published

Roots in LaTeX

Writing roots in LaTeX is straightforward once you know the syntax.

Square Root

The basic square root:

$\sqrt{x}$

With expressions inside:

$\sqrt{a^2 + b^2}$

$\sqrt{\frac{a}{b}}$

Cube Root

For cube roots, use the optional argument:

$\sqrt[3]{x}$

The 3 goes in square brackets before the radicand.

Examples:

$\sqrt[3]{8} = 2$

$\sqrt[3]{a^3 + b^3}$

$\sqrt[3]{\frac{27}{8}}$

Nth Root

The same pattern works for any root:

$\sqrt[n]{x}$

Common examples:

Fourth root: $\sqrt[4]{16} = 2$

Fifth root: $\sqrt[5]{32}$

General: $\sqrt[n]{a^n} = a$

Nested Roots

Roots can be nested:

$\sqrt{\sqrt{x}}$

$\sqrt[3]{\sqrt{x}}$

$\sqrt{1 + \sqrt{1 + \sqrt{1 + x}}}$

Roots in Fractions

$\frac{1}{\sqrt{2}}$

$\frac{\sqrt{3}}{2}$

Rationalizing (Root in Denominator)

Often you'll rationalize:

$\frac{1}{\sqrt{2}} = \frac{\sqrt{2}}{2}$

Roots with Exponents

Combine roots and powers:

$\sqrt{x^2} = |x|$

$\left(\sqrt{x}\right)^2 = x$

$\sqrt[3]{x^6} = x^2$

Fractional Exponents (Alternative)

Roots can be written as fractional exponents:

$\sqrt{x} = x^{1/2} = x^{\frac{1}{2}}$

$\sqrt[3]{x} = x^{1/3} = x^{\frac{1}{3}}$

$\sqrt[n]{x} = x^{1/n}$

Common Formulas with Roots

Quadratic Formula

$x = \frac{-b \pm \sqrt{b^2 - 4ac}}{2a}$

Distance Formula

$d = \sqrt{(x_2-x_1)^2 + (y_2-y_1)^2}$

Standard Deviation

$\sigma = \sqrt{\frac{\sum(x_i - \mu)^2}{N}}$

Pythagorean Theorem

$c = \sqrt{a^2 + b^2}$

Styling the Radical

For a cleaner look with tall content, add spacing:

$\sqrt{\,\frac{a}{b}\,}$

The \, adds thin spaces inside.

Complex Numbers

Cube roots of unity:

$\omega = e^{2\pi i/3} = -\frac{1}{2} + \frac{\sqrt{3}}{2}i$

Write Root Expressions with Octree

Octree simplifies root notation:

- Smart autocomplete for \sqrt - Handles nested roots beautifully - Real-time preview of complex expressions - AI suggests proper formatting

Try it at https://useoctree.com