Use MathJax on Blogger [May 2021]

Recently, I have been working on an online Classical Mechanics course on edX, knowing that could be the direction I want this blog to go. After more than a month of hiatus, I came back but quickly learned that Blogger doesn't provide any mathematical formulation inputs. *This blog will not work without any equations* After searching the keywords "MathJax Blogger," I found several outdated blogs and instructions, including the unofficial tutorials on the MathJax documentation; but, none of them works for me. It appears that Blogger constantly updates its site and no longer supports older scripts. Fortunately, there is an 8-month old Quora post (see link below) that still does the trick. I will summarize it as below.

Source: How can you write math equations on Blogger or Blogspot?

How to enable MathJax on Blogger: 

  1. On your Blogger homepage, click "Theme" on the left pane. 
  2. Next to the "Customize" button, click on the downward arrow then "Edit HTML".
  3. Now, you are redirected to a webpage editor. Here. you will need to call in MathJax. Copy the script below and paste it below <head> (located in the first few lines, line #4 in the figure).

<script src='https://polyfill.io/v3/polyfill.min.js?features=es6'/>
<script async='async' id='MathJax-script' src='https://cdn.jsdelivr.net/npm/mathjax@3/es5/tex-mml-chtml.js'/>
<script type='text/x-mathjax-config'>
MathJax.Hub.Config({
TeX: { equationNumbers: { autoNumber: &quot;AMS&quot; } }
});
</script>

Click to Enlarge


      4. Click on "Save" on the upper right corner.
      5. Now, you should be able to render mathematical equations on your posts. 

Trial #1:

\begin{equation} \frac{V_1kC_{A0}}{F_{A0}} = \int_0^{X_{A1}} \frac{dX_A}{1-X_A}=\frac{(100 \cdot L)(0.6 \cdot min^{-1})(5 \cdot mol \cdot L^{-1})}{100 \cdot mol \cdot min^{-1}} \end{equation}

Trial #2:

\[E=mc^2\]

Trial #3:

\[e^{i\pi} + 1=0\]

Get Familiar with LaTex:

For those who not familiar with LaTex, I have included two useful webpages and a MathJax tutorial below. Hope this helps!


No comments:

Post a Comment

A Brief Review of SF's Young Bay Mud: Part II

Consolidation Properties during Primary Compression The topic of consolidation properties of a soil normally encompasses the discussions of ...