![如何使用“amsmath”解决 notag 方程中的以下错误?](https://linux22.com/image/479914/%E5%A6%82%E4%BD%95%E4%BD%BF%E7%94%A8%E2%80%9Camsmath%E2%80%9D%E8%A7%A3%E5%86%B3%20notag%20%E6%96%B9%E7%A8%8B%E4%B8%AD%E7%9A%84%E4%BB%A5%E4%B8%8B%E9%94%99%E8%AF%AF%EF%BC%9F.png)
编码:
\documentclass{article}
\usepackage{ctex} % used for Chinese
\usepackage{amsmath} % equation*
\begin{document}
直角三角形有如下性质:
\begin{equation*} % for notag equation
a^2 + b^2 = c^2
\end{equation*}
\end{document}
错误和警告:
Command `\acute' already defined. \begin{document}
Command `\grave' already defined. \begin{document}
Command `\ddot' already defined. \begin{document}
Command `\tilde' already defined. \begin{document}
Command `\bar' already defined. \begin{document}
Command `\breve' already defined. \begin{document}
Command `\check' already defined. \begin{document}
Command `\hat' already defined. \begin{document}
Command `\dot' already defined. \begin{document}
Command `\mathring' already defined. \begin{document}
Font shape `OMX/cmex/m/n' in size <10.53937> not available(Font) size <10.95> substituted
Size substitutions with differences(Font) up to 0.41063pt have occurred.
截屏:
如果没有amsmath
,equation*
则不能使用:
使用amsmath
,仍然出现错误:
平台:
TexLive2019, Windows10 64bit, TeXstudio2.12.18
编译消息:
xelatex.exe -synctex=1 -interaction=nonstopmode -shell-escape "test".tex
添加之后\listfiles
日志为:
*File List*
article.cls 2019/10/25 v1.4k Standard LaTeX document class
size10.clo 2019/10/25 v1.4k Standard LaTeX file (size option)
ctex.sty 2019/05/29 v2.4.16 Chinese adapter in LaTeX (CTEX)
expl3.sty 2019-11-07 L3 programming layer (loader)
expl3-code.tex 2019-11-07 L3 programming layer
l3deprecation.def 2019-04-06 v L3 Deprecated functions
l3backend-xdvipdfmx.def 2019-04-06 L3 backend support: xdvipdfmx
xparse.sty 2019-10-11 L3 Experimental document command parser
l3keys2e.sty 2019-10-11 LaTeX2e option processing using LaTeX3 keys
ctexhook.sty 2019/05/29 v2.4.16 Document and package hooks (CTEX)
ctexpatch.sty 2019/05/29 v2.4.16 Patching commands (CTEX)
fix-cm.sty 2015/01/14 v1.1t fixes to LaTeX
ts1enc.def 2001/06/05 v3.0e (jk/car/fm) Standard LaTeX file
everysel.sty 2011/10/28 v1.2 EverySelectfont Package (MS)
ctexopts.cfg 2019/05/29 v2.4.16 Option configuration file (CTEX)
ctex-engine-xetex.def 2019/05/29 v2.4.16 XeLaTeX adapter (CTEX)
xeCJK.sty 2019/06/02 v3.7.4 Typesetting CJK scripts with XeLaTeX
xtemplate.sty 2019-10-11 L3 Experimental prototype document functions
fontspec.sty 2019/10/19 v2.7d Font selection for XeLaTeX and LuaLaTeX
fontspec-xetex.sty 2019/10/19 v2.7d Font selection for XeLaTeX and LuaLaTeX
fontenc.sty
tuenc.def 2018/08/11 v2.0j Standard LaTeX file
fontspec.cfg
xeCJK.cfg 2019/06/02 v3.7.4 Configuration file for xeCJK package
xeCJKfntef.sty 2019/06/02 v3.7.4 xeCJK font effect
ulem.sty 2012/05/18
CJKfntef.sty 2015/04/18 4.8.4
zhnumber.sty 2019/04/07 v2.7 Typesetting numbers with Chinese glyphs
zhnumber-utf8.cfg 2019/04/07 v2.7 Chinese numerals with UTF8 encoding
ctex-scheme-chinese.def 2019/05/29 v2.4.16 Chinese scheme for generic (CTEX)
ctex-name-utf8.cfg 2019/05/29 v2.4.16 Caption with encoding UTF8 (CTEX)
indentfirst.sty 1995/11/23 v1.03 Indent first paragraph (DPC)
ctex-c5size.clo 2019/05/29 v2.4.16 c5size option (CTEX)
ctex-fontset-windows.def 2019/05/29 v2.4.16 Windows fonts definition (CTEX)
ctex-fontset-windowsnew.def 2019/05/29 v2.4.16 Windows fonts definition for
Vista or later version (CTEX)
ctex.cfg 2019/05/29 v2.4.16 Configuration file (CTEX)
amsmath.sty 2019/11/16 v2.17d AMS math features
amstext.sty 2000/06/29 v2.01 AMS text
amsgen.sty 1999/11/30 v2.0 generic functions
amsbsy.sty 1999/11/29 v1.2d Bold Symbols
amsopn.sty 2016/03/08 v2.02 operator names
***********
答案1
(非答案,但发布文件列表)
它在最新的 texlive 2019 中运行无误。如果你添加\listfiles
到你的序言中并使用 xelatex 运行,你应该会得到类似这样的列表,但请检查文件版本:
*File List*
article.cls 2019/10/25 v1.4k Standard LaTeX document class
size10.clo 2019/10/25 v1.4k Standard LaTeX file (size option)
ctex.sty 2019/05/29 v2.4.16 Chinese adapter in LaTeX (CTEX)
expl3.sty 2019-11-07 L3 programming layer (loader)
expl3-code.tex 2019-11-07 L3 programming layer
l3deprecation.def 2019-04-06 v L3 Deprecated functions
l3backend-xdvipdfmx.def 2019-04-06 L3 backend support: xdvipdfmx
xparse.sty 2019-10-11 L3 Experimental document command parser
l3keys2e.sty 2019-10-11 LaTeX2e option processing using LaTeX3 keys
ctexhook.sty 2019/05/29 v2.4.16 Document and package hooks (CTEX)
ctexpatch.sty 2019/05/29 v2.4.16 Patching commands (CTEX)
fix-cm.sty 2015/01/14 v1.1t fixes to LaTeX
ts1enc.def 2001/06/05 v3.0e (jk/car/fm) Standard LaTeX file
everysel.sty 2011/10/28 v1.2 EverySelectfont Package (MS)
ctexopts.cfg 2019/05/29 v2.4.16 Option configuration file (CTEX)
ctex-engine-xetex.def 2019/05/29 v2.4.16 XeLaTeX adapter (CTEX)
xeCJK.sty 2019/06/02 v3.7.4 Typesetting CJK scripts with XeLaTeX
xtemplate.sty 2019-10-11 L3 Experimental prototype document functions
fontspec.sty 2019/10/19 v2.7d Font selection for XeLaTeX and LuaLaTeX
fontspec-xetex.sty 2019/10/19 v2.7d Font selection for XeLaTeX and LuaLaTeX
fontenc.sty
tuenc.def 2018/08/11 v2.0j Standard LaTeX file
fontspec.cfg
xeCJK.cfg 2019/06/02 v3.7.4 Configuration file for xeCJK package
xeCJKfntef.sty 2019/06/02 v3.7.4 xeCJK font effect
ulem.sty 2012/05/18
CJKfntef.sty 2015/04/18 4.8.4
zhnumber.sty 2019/04/07 v2.7 Typesetting numbers with Chinese glyphs
zhnumber-utf8.cfg 2019/04/07 v2.7 Chinese numerals with UTF8 encoding
ctex-scheme-chinese.def 2019/05/29 v2.4.16 Chinese scheme for generic (CTEX)
ctex-name-utf8.cfg 2019/05/29 v2.4.16 Caption with encoding UTF8 (CTEX)
indentfirst.sty 1995/11/23 v1.03 Indent first paragraph (DPC)
ctex-c5size.clo 2019/05/29 v2.4.16 c5size option (CTEX)
ctex-fontset-fandol.def 2019/05/29 v2.4.16 Fandol fonts definition (CTEX)
ctex.cfg 2019/05/29 v2.4.16 Configuration file (CTEX)
amsmath.sty 2019/11/16 v2.17d AMS math features
amstext.sty 2000/06/29 v2.01 AMS text
amsgen.sty 1999/11/30 v2.0 generic functions
amsbsy.sty 1999/11/29 v1.2d Bold Symbols
amsopn.sty 2016/03/08 v2.02 operator names
***********