![同一文档中的公式采用两种不同的编号样式](https://linux22.com/image/292762/%E5%90%8C%E4%B8%80%E6%96%87%E6%A1%A3%E4%B8%AD%E7%9A%84%E5%85%AC%E5%BC%8F%E9%87%87%E7%94%A8%E4%B8%A4%E7%A7%8D%E4%B8%8D%E5%90%8C%E7%9A%84%E7%BC%96%E5%8F%B7%E6%A0%B7%E5%BC%8F.png)
在该文档前面的部分,有一些标示如下的方程式:
(1) (some space) \frac{1}{/2}=0.5
(2) (some space) hi
现在,我想做这样的事情,切换方程编号并重新开始:
(a) (some space) hello
我怎样才能做到这一点?
答案1
像这样吗?
\documentclass[leqno,fleqn]{article}
\usepackage{amsmath} %% for \eqref macro
\setlength\textwidth{2in} % just for this example
\begin{document}
\begin{equation} \frac{1}{2}=0.5 \label{eq:1} \end{equation}
\begin{equation} \mbox{hi} \end{equation}
\setcounter{equation}{0} % reset the equation counter
\renewcommand{\theequation}{\alph{equation}} % change numbering from arabic to alphabetic
Now, I want to do something like this and switch the equation number and start over:
\begin{equation} \mbox{hello} \label{eq:a} \end{equation}
Here are cross-references to equations \eqref{eq:1} and \eqref{eq:a}.
\end{document}