Learn to write equations in Markdown and convert it to docx format

Prepare system

Download and install

  1. Any text editor
    1. visualstudiocode Download link recommended
    2. markdownedit Download link alternative to visualstudiocode
    3. Or simply type in any text editor notepad or vim

Equations must be enclosed by $ sign or $$

  1. enclose formulas in single dollar sign $ your equation $ for inline equations.
  2. enclose formulas in double dollar sign $$ your equation $$ for equation environment and start with new line.



\(\alpha\) $\beta$
\(\beta\) $\delta$


$\frac{numerator}{denominator}$ \(\frac{numerator}{denominator}\)

$\frac{a}{b}$ \(\frac{a}{b}\)

Powers Output





simple () are not because brackets done resize to cover content like below $(\frac{a}{b)$ \((a^2\frac{a^2}{b^2})\)
so use \left( and \right) BracketsOutput $\left($
\(\left( a \right.\)
\(\left. a \right)\)
$\left( a \right)$
\(\left( a^2\frac{a^2}{b^2} \right)\)
\(\left[ a \right.\)
\(\left. a \right]\)
$\left[ a \right\$
\(\left[a^2\frac{a^2}{b^2} \right]\)
$E=mc^2$ \(E=mc^2\)

  1. now save this as “anyfilename.md”

  2. run command in the same folder as

    pandoc anyfilename.md -o anyfilename.docx

    check anyfilename.docx in the directory

Test formulas

\[E=mc^2\] \[\vec{F}=m\vec{a}\] \[S=ut+\frac{1}{2}at^2\] \[v=u+at\] \[v^2=u^2+2as\] \[V=l\frac{\delta i}{\delta t}\] \[\nabla \times \overrightarrow E= - \frac{\partial \overrightarrow B}{\partial t}\] \[\begin{bmatrix}a\ b\ c\\d\ e\ f\\ g\ h\ i \end{bmatrix}\] \[\left|\begin{matrix}a\ b\ c\\d\ e\ f\\ g\ h\ i \end{matrix}\right|\]