@
oimotis 给出例子
错误样例:
$$
\newcommand{\itm}[1]{\mathcal {{ '{#' }}1}\rm}
\newcommand{\bgroup}[1]{\left( {{ '{#' }}1}\right)}
\begin{align}
p(y;\mu)&=\frac{1}{\sqrt{2\pi}}\rm{exp}\left(-\frac{1}{2}(\itm{y}\rm{}-\mu)\right)\\\\
&=\frac{1}{\sqrt{2\pi}}\rm{exp}\bgroup{-\frac{1}{2}\itm{y}^2}\cdot \rm{exp}\bgroup{\mu\itm{y}-\frac{1}{2}\mu^2}
\end{align}
$$
对应的正确样例:
$$
\newcommand{\itm}[1]{\mathcal{#1}\rm}
\newcommand{\bgroup}[1]{\left({#1}\right)}
\begin{align}
p(y;\mu)&=\frac{1}{\sqrt{2\pi}}\rm{exp}\left(-\frac{1}{2}(\itm{y}\rm{}-\mu)\right)\\
&=\frac{1}{\sqrt{2\pi}}\rm{exp}\bgroup{-\frac{1}{2}\itm{y}^2}\cdot \rm{exp}\bgroup{\mu\itm{y}-\frac{1}{2}\mu^2}
\end{align}
$$
上面的例子里,换行的 '\\' 都改成了 '\\\\' ,还有 hexo 中 '{#' 为保留的关键字,需要换成 ‘{{ '{#' }}’ 、
其他的问题暂时遇到的还有:'\{' 和 '\}' 改成'\\{'和'\\}' 、 '_' 改成'\_' 、 '*' 改成 '\*' 。
附上 Blog 源码
https://github.com/AFutureD/AFutureD.github.io ,hexo-next 分支为源码,master 为网站源码,
blog 地址:
AFutureD.github.io