Writing LaTeX on this website
How equations are displayed on this website?
Posted on: July 16, 2022
PhysicistSouravDas
In this article, I will describe about writing
?
What is Suppose I want to write one of the most famous equation, the Einstein mass-energy equivalence equation. In text, someone would write it like this: E = mc2. But how to raise that 2 to the power? Let us use
Some more equations below:
The above equations are Maxwell's equations. The
$$
\begin{align*}
\nabla\cdot\textbf{E} &= \frac{\rho}{\epsilon_{0}} \\
\nabla\cdot\textbf{B} &= 0 \\
\nabla\times\textbf{E} &= -\frac{\partial{\textbf{B}}}{\partial{t}} \\
\nabla\times\textbf{B} &= \mu_{0}\textbf{j} + \frac{1}{c^{2}}\frac{\partial{\textbf{E}}}{\partial{t}}
\end{align*}
$$
on websites
Displaying If any website does not have the software to compile
As you may already know, this website is created using the Nuxt framework, which is a JavaScript framework. To display remark-math@4.0.0
and rehype-mathjax@3.1.0
. Note that version of these packages later than these won't work with Nuxt v2 (which I am currently using), because the later version of remark packages are ESM package, which cannot be require()
'd from CommonJS. An alternative to MathJax is KaTeX, created by developers at Khan Academy. KaTeX is faster than MathJax, but MathJax has complete support for