2つ(または複数)のQEDシンボルを1行に配置する方法

2つ(または複数)のQEDシンボルを1行に配置する方法

定理の証明に主張とその証明が含まれており、主張の証明によって定理の証明が完了するとします。つまり、主張の証明が終了した後は、定理の証明にそれ以上のテキストは必要ありません。例:

\documentclass{article}
\usepackage{amsthm}
\newtheorem{theorem}{Theorem}
\newtheorem{claim}{Claim}
\begin{document}

\begin{theorem}
Today is Thursday.

\begin{proof}
We know that the day after Wednesday is always Thursday.
Thus the theorem follows from the following claim:

\begin{claim}
Yesterday was Wednesday.

\begin{proof}
My computer said so.
\end{proof}
\end{claim}
\end{proof}
\end{theorem}
\end{document}

デフォルトでは、2 番目の QED シンボルは、その行にテキストがない場合でも、最初の行の 1 行下に配置されます。2 つの (ネストされた) 証明が両方ともその時点で終了することを示すために、両方の QED シンボルを同じ行に並べて配置する方が自然に思えます。どうすればこれを実現できますか? コマンドを挿入してみました\qedhereが、役に立たないようです。

答え1

を2倍にします\qedsymbol

前文では、

\let\oldqedbox\qedsymbol
\newcommand{\twoqedbox}{\oldqedbox\oldqedbox}

そして、最初の の前に\end{proof}

\renewcommand{\qedsymbol}{\twoqedbox}

2番目の前に\end{proof}

\renewcommand{\qedsymbol}{}

「更新」は\qedsymbol持続しません。

amsthmネストされた証明を処理するようには設計されていません。ネストされた証明は非常にまれです。

答え2

証明環境を偽造することができます。

\begin{theorem}
Today is Thursday.
\end{theorem}  % moved to here

\begin{proof}
We know that the day after Wednesday is always Thursday.
Thus the theorem follows from the following claim:
\begin{claim}
Yesterday was Wednesday.
\end{claim}
\noindent\textit{\proofname.} My computer said so.\qedhere\qedsymbol
\end{proof}

ここに画像の説明を入力してください

関連情報