# Typesetting Mathematics

I specifically chose WordPress for this blog because of it allows the use of $\LaTeX$ for typesetting mathematics, used by many mathematicians and scientists for writing documents with extensive mathematical symbols.

To use $\LaTeX$ in WordPress, the basic command is

$\\hbox{latex [Your LaTeX command here]} \$

This creates a small image rendering the mathematical symbols. If you hover your mouse over any $\LaTeX$ image, you should see the source code that made the image possible.

If you’re not familiar with $\LaTeX$, I’ve illustrated some common syntax with the examples below.  The text on the left should replace [Your LaTex command here] above.

1. y = a(x-h)^2 + k   becomes  $y = a(x-h)^2 + k$
2. \frac{x^2-y^2}{x-y} = x + y \hbox{~if~} x \ne  y  becomes $\frac{x^2-y^2}{x-y} = x + y \hbox{~if~} x \ne y$
3. \pi \approx \frac{22}{7}    becomes   $\pi \approx \frac{22}{7}$
4. \pi \approx \displaystyle \frac{355}{113}   becomes  $\pi \approx \displaystyle \frac{355}{113}$
5. a^2 + b^2 = c^2   becomes  $a^2 + b^2 = c^2$
6. x \ge 6   becomes  $x \ge 6$
7. \sqrt{x^2} = |x|  becomes  $\sqrt{x^2} = |x|$
8. \sqrt[3]{-216} = -6  becomes $\sqrt[3]{-216} = -6$
9. \log_{10} \frac{x}{y} = \log_{10} x – \log_{10} y   becomes $\log_{10} \frac{x}{y} = \log_{10} x - \log_{10} y$
10. \sin^2 \theta + \cos^2 \theta = 1  becomes $\sin^2 \theta + \cos^2 \theta = 1$
11. (x+y)^n = \displaystyle \sum_{k=0}^n {n \choose k} x^k y^{n-k}   becomes  $(x+y)^n = \displaystyle \sum_{k=0}^n {n \choose k} x^k y^{n-k}$
12. \displaystyle \int_a^b f(x) dx \approx \frac{h}{2} \left[ f(x_0) + 2f(x_1) + \dots + 2f(x_{n-1}) + f(x_n) \right]   becomes $\displaystyle \int_a^b f(x) dx \approx \frac{h}{2} \left[ f(x_0) + 2f(x_1) + \dots + 2f(x_{n-1}) + f(x_n) \right]$
13. \frac{d}{d\phi} \left(\tan^2 \phi\right) = 2 \tan \phi\sec^2 \phibecomes $\frac{d}{d\phi} \left( \tan^2 \phi\right) = 2 \tan \phi\sec^2 \phi$
14. \mathbb{Z} \subset \mathbb{Q} \subset \mathbb{R} \subset \mathbb{C}   becomes $\mathbb{Z} \subset \mathbb{Q} \subset \mathbb{R} \subset \mathbb{C}$
15. \displaystyle \frac{-b \pm \sqrt{b^2-4ac}}{2a}   becomes $\displaystyle \frac{-b \pm \sqrt{b^2-4ac}}{2a}$
16. P(A \cap B)   becomes $P(A \cap B)$
17. \triangle ABC \cong \triangle DEF   becomes  $\triangle ABC \cong \triangle DEF$
18. (-\infty,-2] \cup [2,\infty)  becomes $(-\infty,2] \cup [2,\infty)$