我在 IEEEtrantools 中使用子数:
\documentclass{article}
\usepackage{IEEEtrantools}
\begin{document}
Numbered equation:
\begin{IEEEeqnarray}{rCl}
a & = & b \;.
\label{eq:tTy}
\end{IEEEeqnarray}
Subnumbered equations:
\begin{IEEEeqnarray}{rrCll}
& c & = & 3d & \IEEEyessubnumber
\\*[-0.625\normalbaselineskip]
\smash{\left\{\IEEEstrut[6\jot]\right.} \label{eq:NvY} &&&& \nonumber \;. % the invisible row
\\*[-0.625\normalbaselineskip]
& e & = & f & \IEEEyessubnumber
\end{IEEEeqnarray}
Next equation:
\begin{IEEEeqnarray}{rCl}
h & = & i \;.
\label{eq:tog}
\end{IEEEeqnarray}
\end{document}
它给:
我希望子数与前一个和下一个方程无关。所以我需要得到这个:
我如何获得它?(IEEEtrantools 是我想要坚持使用的软件包。)
答案1
Adobe 的答案确实在一定程度上解决了这个问题,但效果并不理想。尤其是当一个子编号紧随另一个子编号时,只有方程计数器会增加,而内部子计数器不会增加。
\documentclass{IEEEtran}
\begin{document}
Numbered equation:
\begin{IEEEeqnarray}{rCl}
a & = & b \;.
\label{eq:tTy}
\end{IEEEeqnarray}
Subnumbered equations:
\addtocounter{equation}{1}
\begin{IEEEeqnarray}{rrCll}
& c & = & 3d & \IEEEyessubnumber
\\*[-0.625\normalbaselineskip]
\smash{\left\{\IEEEstrut[6\jot]\right.} \label{eq:NvY} &&&& \nonumber \;. % the invisible row
\\*[-0.625\normalbaselineskip]
& e & = & f & \IEEEyessubnumber
\end{IEEEeqnarray}`
Next equation:
\addtocounter{equation}{1}
\begin{IEEEeqnarray}{rCl}
h & = & i \; \IEEEyessubnumber
\label{eq:tog}
\end{IEEEeqnarray}
\end{document}.
这个问题可以通过引入来解决\IEEEyesnumber命令之前\IEEEyessubnumber这将使当前 IEEEeqnarray 独立于前一个和下一个方程,并且还将增加方程计数器并重新启动子计数器。
\documentclass{IEEEtran}
\begin{document}
Numbered equation:
\begin{IEEEeqnarray}{rCl}
a & = & b \;.
\label{eq:tTy}
\end{IEEEeqnarray}
Subnumbered equations:
\begin{IEEEeqnarray}{rrCll}
& c & = & 3d & \IEEEyesnumber \IEEEyessubnumber
\\*[-0.625\normalbaselineskip]
\smash{\left\{\IEEEstrut[6\jot]\right.} \label{eq:NvY} &&&& \nonumber \;. % the invisible row
\\*[-0.625\normalbaselineskip]
& e & = & f & \IEEEyessubnumber
\end{IEEEeqnarray}`
Next equation:
\begin{IEEEeqnarray}{rCl}
h & = & i \; \IEEEyesnumber \IEEEyessubnumber
\label{eq:tog}
\end{IEEEeqnarray}
\end{document}
此外,手动增加计数器会使代码很难调试!
答案2
哦,我解决了:需要在子编号等式前将计数器加 1:
\addtocounter{equation}{1}
\begin{IEEEeqnarray}{rrCll}
& c & = & 3d & \IEEEyessubnumber
\\*[-0.625\normalbaselineskip]
\smash{\left\{\IEEEstrut[6\jot]\right.} \label{eq:NvY} &&&& \nonumber \;. % the invisible row
\\*[-0.625\normalbaselineskip]
& e & = & f & \IEEEyessubnumber
\end{IEEEeqnarray}