mohuangrui/ucasthesis

使用学校发的模板,但公式序号根据section不同而重新编号,请问如何更改

cbx812 opened this issue · 2 comments

cbx812 commented

检查 / Check

编译环境 / Compilation Environment

  • 操作系统 / Operating System

    • Windows 7/8/10
    • macOS
    • Linux
  • TeX 发行版 / Tex Distribution

    • TeX Live
    • MiKTeX
    • CTeX

描述问题 / Problem Description

问题描述:

使用国科大LaTeX模板4.LaTeX.zip_20221006.zip,编辑公式时序号根据section不同而重新编号,如下图,而不是再同一chapter下连续编号,如第二个公式应为4.2,请问应该如何修改?
image.png

日志文件 / .log file

将编译生成的 .log 文件拖入下行空白处:

问题截图 / Screenshots

将出现的问题或需要实现的效果的 截图照片 拖入下行空白处:

最小工作示例(MWE) / Minimal Working Example

问题在于

%- Set equation, figure, table numbering
%\numberwithin{equation}{section}% set enumeration level
%\renewcommand{\theequation}{\thesection\arabic{equation}}% configure the label style

你发的模板将这段代码取消注释了,导致 equation 随着 section 增加而归零。

解决方案:

  1. 将这段代码注释,但不能确保其它地方没错;
  2. 使用 github 上的模板(建议)。
cbx812 commented

问题在于

%- Set equation, figure, table numbering
%\numberwithin{equation}{section}% set enumeration level
%\renewcommand{\theequation}{\thesection\arabic{equation}}% configure the label style

你发的模板将这段代码取消注释了,导致 equation 随着 section 增加而归零。
解决方案:

  1. 将这段代码注释,但不能确保其它地方没错;
  2. 使用 github 上的模板(建议)。

明白了,非常感谢!