编译时跳过 \int 命令

编译时跳过 \int 命令

如果我这样写:\int_a^b或者\int_{a}^{b}它跳过\int和只写a to the power b但是当我只写\int而没有限制时它会显示以下错误:

! Missing \endcsname inserted.
<to be read again>
\protect
\{->\x@protect \{\protect
\{
\int #1->\csname i-#1
\endcsname
l.56 (u_1,u_2) = -i \int \{
u_1(x) \partial_0 u_2^*(x) - u_2^*(x)\partial_0 ...
The control sequence marked <to be read again> should
not appear between \csname and \endcsname.
! Extra \endcsname.
\int #1->\csname i-#1\endcsname
l.56 (u_1,u_2) = -i \int \{
u_1(x) \partial_0 u_2^*(x) - u_2^*(x)\partial_0 ...

该方程如下:

\begin{equation} 
(u_1,u_2) = -i \int \{ u_1(x) \partial_0 u_2^*(x) - u_2^*(x)\partial_0 u_1(x)\} [\sqrt{-g_{\Sigma}(x)}] \mathrm{d}\Sigma 
\label{Inner Prod}
\end{equation}

当我写

\begin{equation} 
(u_1,u_2) = -i \int\limits_{u}^{e} \{ u_1(x) \partial_0 u_2^*(x) - u_2^*(x)\partial_0 u_1(x)\} [\sqrt{-g_{\Sigma}(x)}] \mathrm{d}\Sigma 
\label{Inner Prod}
\end{equation}

显示以下错误:

! Missing \endcsname inserted.
<to be read again>
\limits
\int #1->\csname i-#1
\endcsname
l.56 (u_1,u_2) = -i \int\limits
_{u}^{e} \{ u_1(x) \partial_0 u_2^*(x) - u_2^...
The control sequence marked <to be read again> should
not appear between \csname and \endcsname.
! Limit controls must follow a math operator.
<recently read> \limits
\int #1->\csname i-#1
\endcsname
l.56 (u_1,u_2) = -i \int\limits
_{u}^{e} \{ u_1(x) \partial_0 u_2^*(x) - u_2^...
I'm ignoring this misplaced \limits or \nolimits command.
! Extra \endcsname.
\int #1->\csname i-#1\endcsname
l.56 (u_1,u_2) = -i \int\limits
_{u}^{e} \{ u_1(x) \partial_0 u_2^*(x) - u_2^...
I'm ignoring this, since I wasn't doing a \csname.

很明显它正在跳过,但我无法读取错误。csname 是什么?第一个错误中受保护的是什么?

我将 TexMaker 与 MikTex 一起使用。

答案1

错误日志显示

 \int #1->\csname i-#1

您未显示的一些代码已\int通过等效于以下内容进行定义

\renewcommand\int[1]{\csname i-#1}

所以它不再表示积分符号,并且您会得到您所述的错误。

相关内容