pdfLaTeX align环境缺少插入的$



我在校样中使用Align环境,收到错误"Missing$inserted"。除了Align的第一行外,我已经注释掉了所有内容,使错误消失,但我仍然不知道问题是什么。我找不到任何解决方案。我是不是错过了什么?

documentclass[12pt,letterpaper]{article}
usepackage{ifpdf, enumerate}
usepackage{mla}
usepackage{gb4e}
usepackage{amsfonts}
usepackage{amsmath}
usepackage{amsthm}
usepackage{stmaryrd}
newcommand{tuple}[1]{ensuremath{left langle #1 right rangle }}
newcommand{evaluation}[2][]{ensuremath{llbracket #2rrbracket^{#1}}}
begin{document}
begin{proof}
  begin{align*} 
    evaluation[mathbb{M}]{(Mx)(D (x) & V (x))} = 1 iff \
    evaluation[mathbb{M}]{lbrack alpha / x rbrack (D (x) & V (x))} = 1 text{for most constants alpha} \
    evaluation[mathbb{M}]{(D (alpha) & V (alpha))} = 1 text{for most constants alpha } \
    evaluation[mathbb{M}]{D (alpha)} = 1 text{and} evaluation[mathbb{M}]{V (alpha)} = 1 text{for most constants alpha } \
    F(alpha) in F(D) text{and} F(alpha) in F(V) text{for most constants alpha } \
    intertext{Examining the definitions of the model, we see that there are only four entities that are both in $F(D)$ and $F(V)$: Alice, Bob, Colin, and David. Because this is not more than half of the total twelve entities in the universe, our naive definition of ``most'' is not satisfied. Therefore the statement is false, which implies that the truth value of the origenal proposition is not 1.}
  end{align*}
end{proof}
end{document}

以下是错误消息的样子。

    ./test.tex:24: Missing $ inserted.
<inserted text>
                $
l.24   end{align*}
?

您只错过了一个棘手的事实:alpha只在数学模式下工作,所以如果您替换所有出现的

text{for most constants alpha} \

(第18、19、20、21行),带

text{for most constants }alpha \

那么你的tex就会编译得很好。还有:

text{for most constants} alpha \

或:

text{for most constants $alpha$} \

正如您在代码的第22行中所做的那样(…$F(D)$ and $F(V)$…)。

这个答案不适用于这种确切的情况,但如果"amsmath";包未被使用。这变得很棘手,因为除了我忘记在文档开头添加usepackage{amsmath}行之外,整个代码看起来都很好。

最新更新