This is a follow-up question of QED symbol after statements without proof, and I am really not sure whether this is the right approach to solve the problem raised there. But it seems to solve all situations I encounter perfectly, so I will try...
The theorem environment has the usual version with numbering and a *
'ed version without numbering. I would now like to have another **
'ed (or something similar) version that puts something around the theorem environment.
Here is what I currently need to do:
\documentclass{amsart}
\newtheorem{theorem}{Theorem}[section]
\newtheorem{corollary}[theorem]{Corollary}
\begin{document}
\begin{proof}[\unskip\nopunct]
\begin{theorem}
$e^{2\pi i} = 1$. \qedhere
\end{theorem}
\end{proof}
\begin{proof}[\unskip\nopunct]
\begin{corollary}[{myref}]
The expression $e^{2\pi i} - 1$ equals $0$. Moreover, there is more text to actually add here. \qedhere
\end{corollary}
\end{proof}
\end{document}
and I want to avoid adding the \begin{proof}[\unskip\nopunct]
and the \end{proof}
myself, but get this automatically using a double star in both situations.
It might actually be better to interchange the order of the proof and the theorem environment, so a solution that provides that version would also be appreciated!
That is
\begin{myXYZ**}[...]
...
\end{myXYZ**}
(with myXYZ
defined as a theorem environment in the header) should simply translate into
\begin{proof}[\unskip\nopunct]
\begin{myXYZ}[...]
...
\end{myXYZ}
\end{proof}
Is this (or the **
replaced with something else, independent of using theorem or lemma or proposition) possible?
\newenvironment{theorem**}[1][]{\begin{proof}[\unskip\nopunct]\begin{theorem}[#1]}{\end{theorem}\end{proof}}
?theorem
but it should work equally well withlemma
and any other theorem-like environment in the very same way without having to define it for each of these independently.\addqed
macro I proposed do the job without any additionalproof
environment around? One might add a further abstraction layer, but I don't think that\newtheorem{theorem}{Theorem}\addqed{theorem}
is so long to type. Besides it was your request not to define environments with an additional*
.