当我使用包含一些矩阵的 align* 环境时,使用 beamer 类时编译会出现错误。当我更改为 article 类时,编译正常。我不明白哪里出了问题,或者我需要做什么来用 beamer 处理这个问题...
Beamer 代码:
\documentclass[9pt]{beamer}
\usepackage{amsmath}
\newcommand{\vect}[1]{\boldsymbol{\mathbf{#1}}}
\begin{document}
\begin{frame}
\begin{align*}
&\underbrace{\mathrm{d}
\begin{bmatrix}
\eta_1 \\
\eta_2 \\
\eta_3 \\
\eta_4 \\
\eta_5
\end{bmatrix}
\big{(}t\big{)}}_{\mathrm{d} \vect{\eta} (t)} = \left(
\underbrace{
\begin{bmatrix}
\text{drlatency} & \text{drlatencydisturbance} & \text{drlatencyquality} & \text{drlatencymood} & 0 \\
\text{drdisturbancelatency} & \text{drdisturbance} & \text{drdisturbancequality} & \text{drdisturbancemood} & 0 \\
\text{drqualitylatency} & \text{drqualitydisturbance} & \text{drquality} & \text{drqualitymood} & 0 \\
\text{drmoodlatency} & \text{drmooddisturbance} & \text{drmoodquality} & \text{drmood} & \text{drmoodsleep} \\
0 & 0 & 0 & \text{drsleepmood} & \text{drsleep}
\end{bmatrix}
}_{\underbrace{\vect{A}}_\textrm{DRIFT}} \underbrace{
\begin{bmatrix}
\eta_1 \\
\eta_2 \\
\eta_3 \\
\eta_4 \\
\eta_5
\end{bmatrix}
\big{(} t \big{)}
}_{\vect{\eta} (t)} + \underbrace{
\begin{bmatrix}
0 \\
0 \\
0 \\
0 \\
0
\end{bmatrix}
}_{\underbrace{\vect{b}}_\textrm{CINT}} \right) dt
\end{align*}
\end{frame}
\end{document}
文章代码:
\documentclass[9pt]{article}
\usepackage{amsmath} %for multiple line equations
\newcommand{\vect}[1]{\boldsymbol{\mathbf{#1}}}
\begin{document}
\begin{align*}
&\underbrace{\mathrm{d}
\begin{bmatrix}
\eta_1 \\
\eta_2 \\
\eta_3 \\
\eta_4 \\
\eta_5
\end{bmatrix}
\big{(}t\big{)}}_{\mathrm{d} \vect{\eta} (t)} = \left(
\underbrace{
\begin{bmatrix}
\text{drlatency} & \text{drlatencydisturbance} & \text{drlatencyquality} & \text{drlatencymood} & 0 \\
\text{drdisturbancelatency} & \text{drdisturbance} & \text{drdisturbancequality} & \text{drdisturbancemood} & 0 \\
\text{drqualitylatency} & \text{drqualitydisturbance} & \text{drquality} & \text{drqualitymood} & 0 \\
\text{drmoodlatency} & \text{drmooddisturbance} & \text{drmoodquality} & \text{drmood} & \text{drmoodsleep} \\
0 & 0 & 0 & \text{drsleepmood} & \text{drsleep}
\end{bmatrix}
}_{\underbrace{\vect{A}}_\textrm{DRIFT}} \underbrace{
\begin{bmatrix}
\eta_1 \\
\eta_2 \\
\eta_3 \\
\eta_4 \\
\eta_5
\end{bmatrix}
\big{(} t \big{)}
}_{\vect{\eta} (t)} + \underbrace{
\begin{bmatrix}
0 \\
0 \\
0 \\
0 \\
0
\end{bmatrix}
}_{\underbrace{\vect{b}}_\textrm{CINT}} \right) dt
\end{align*}
\end{document}
答案1
事实是
_\textrm{CINT}
默认情况下有效是原始下标的解析规则的一个不良副作用,这些规则与正常的宏参数不匹配。
如果你使用文档化的语法
_{\textrm{CINT}}
然后它在 beamer 中工作(示例中有两个实例)