答案1
从图中我可以看到,您定义的环境的预期调用形式为
\begin{theorem}{1}
Let $\mathscr{H}$ be a Hilbert space ...
\end{theorem}
而你的输出似乎是
\begin{theorem}[Theorem 1]
Let $\mathscr{H}$ be a Hilbert space ...
\end{theorem}
这是错误的。请使用前一种语法。
笔记
我对你使用 LaTeX 的方式有疑问。根据这些定义,只需一个新的环境就足够了。你可以调用
\begin{theorem}{1}
Let $\mathscr{H}$ be a Hilbert space ...
\end{theorem}
\begin{theorem}[Corollary]{1}
In the situation of ...
\end{theorem}
并且输出完全相同,而不需要六个几乎相同的定义。
然而,这违背了 LaTeX 的精神,因为可以而且应该避免手动编号。对于定理类陈述,LaTeX 提供了\newtheorem
,通过加载包可以对其进行改进amsthm
。
\documentclass{article}
\usepackage{amsmath}
\usepackage{amsthm}
\usepackage{mathrsfs}
\theoremstyle{definition} % body font upright
\newtheorem{theorem}{Theorem}
\newtheorem{corollary}{Corollary}
\begin{document}
\begin{theorem}\label{thm:projection}
Let $\mathscr{H}$ be a Hilbert space and $\mathscr{M}$ a closed
subspace of~$\mathscr{H}$. Moreover, let $x\in\mathscr{H}$. Then
there is a unique element $\hat{x}\in\mathscr{M}$ such that
\begin{equation}
\label{eq:projection}
\lVert x-\hat{x}\rVert = \inf_{y\in\mathscr{M}}\lVert x-y\rVert.
\end{equation}
Additionally, $\hat{x}\in\mathscr{M}$ and \eqref{eq:projection}~iff
$\hat{x}\in\mathscr{M}$ and $(x-\hat{x}\in\mathscr{M}^{\perp}$.
\end{theorem}
\begin{proof}
See \cite[p.~51]{BD91}.
\end{proof}
\begin{corollary}
In the situation of Theorem~\ref{thm:projection}, let $\mathcal{I}$
denote the identity map on $\mathscr{H}$. Then there is a unique map
$P_{\mathscr{M}}$ of $\mathscr{H}$ onto $\mathscr{M}$ such that
$\mathcal{I}-P_{\mathscr{M}}$ maps $\mathscr{H}$ onto $\mathscr{M}^{\perp}$.
\end{corollary}
\begin{thebibliography}{BD91}
\bibitem[BD91]{BD91} Whatever
\end{thebibliography}
\end{document}