# Enable Latex in Hugo

I was able to add \(\LaTeX\) support to my hugo blog finally. Suprisingly adding it is not difficult with hugo blogs. All I needed to do is add katex support. This might look different depending on the theam that you are using. Now I am able to include some mathematical expressions using `$$`

or `$`

depending on whether I want the expression to be inline or display mode. For example, the following is Holder’s inequality in display mode:

$$\sum_{i=1}^n x_iy_i \le \left(\sum_{i=1}^n x_i^p \right)^{1/p} \left(\sum_{i=1}^n y_i^q \right)^{1/q} $$

which is fantastic. The only problem I am seeing is that some special characters in \(\LaTeX\) are special characters in Markdown as well. For example, `_`

means something in both languages. My work around at the moment is to escape the underscores until I find a more convenient solution.