1 min read

Using LaTeX in Your Posts

This post demonstrates how to use LaTeX for mathematical expressions and equations.

Inline Math

You can write inline equations like this: $E = mc^2$ or $x^2 + y^2 = r^2$

Block Equations

For larger equations, use double dollar signs:

\[\frac{d}{dx}\left( \int_{0}^{x} f(u)\,du\right)=f(x)\]

Complex Mathematical Expressions

The quadratic formula: \(x = \frac{-b \pm \sqrt{b^2 - 4ac}}{2a}\)

Matrix representation: \(\begin{bmatrix} a & b & c \\ d & e & f \\ g & h & i \end{bmatrix}\)

Sum notation: \(\sum_{n=1}^{\infty} \frac{1}{n^2} = \frac{\pi^2}{6}\)

Greek Letters and Symbols

Chemical Equations

\[\ce{CO2 + H2O -> H2CO3}\]

Statistical Formulas

Standard deviation: \(\sigma = \sqrt{\frac{1}{N} \sum_{i=1}^{N} (x_i - \mu)^2}\)

Probability and Set Theory

\[P(A \cap B) = P(A) \cdot P(B|A)\] \[A \subseteq B \iff \forall x(x \in A \implies x \in B)\]

Comments