2- You can use the restatable
environment provided by thmtools
.
1- Since the environment generates an anchor, you can use the standard \label
, \ref
(\pageref
) mechanism for cross-referencing.
A complete example:
\documentclass{article}
\usepackage{amsthm}
\usepackage{thmtools, thm-restate}
\usepackage{hyperref}
\declaretheorem{theorem}
\begin{document}
\section{Test Section}
\begin{theorem}
Test theorem
\end{theorem}
\begin{restatable}[Fundamental Theorem of Algebra]{theorem}{fta}
\label{thm:FTA}
Every non-constant single-variable polynomial with complex coefficients has at least one complex root.
\end{restatable}
\appendix
\section[Proof of the Fundamental Theorem of Algebra]{Proof of Theorem~\ref{thm:FTA} (See page~\pageref{thm:FTA})}
\fta*
\begin{proof}
Assume...
\end{proof}
\end{document}
Now that the question has been edited, and the used document class is known, here's a solution using the vldb
document class (the link to the class can be found in the question):
\documentclass{vldb}
\usepackage{textcase}
\usepackage{thmtools,thm-restate}
\usepackage{hyperref}
\makeatletter
\def\@sect#1#2#3#4#5#6[#7]#8{%
\ifnum #2>\c@secnumdepth
\let\@svsec\@empty
\else
\refstepcounter{#1}%
\edef\@svsec{%
\begingroup
%\ifnum#2>2 \noexpand\rm \fi % changed to next 29 July 2002 gkmt
\ifnum#2>2 \noexpand#6 \fi
\csname the#1\endcsname
\endgroup
\ifnum #2=1\relax .\fi
\hskip 1em
}%
\fi
\@tempskipa #5\relax
\ifdim \@tempskipa>\z@
\begingroup
#6\relax
\@hangfrom{\hskip #3\relax\@svsec}%
\begingroup
\interlinepenalty \@M
\if@uchead
\MakeTextUppercase{#8}% HERE
\else
#8%
\fi
\par
\endgroup
\endgroup
\csname #1mark\endcsname{#7}%
\vskip -12pt %gkmt, 11 aug 99 and GM July 2000 (was -14) - numbered section head spacing
\addcontentsline{toc}{#1}{%
\ifnum #2>\c@secnumdepth \else
\protect\numberline{\csname the#1\endcsname}%
\fi
#7%
}%
\else
\def\@svsechd{%
#6%
\hskip #3\relax
\@svsec
\if@uchead
\uppercase{#8}%
\else
#8%
\fi
\csname #1mark\endcsname{#7}%
\addcontentsline{toc}{#1}{%
\ifnum #2>\c@secnumdepth \else
\protect\numberline{\csname the#1\endcsname}%
\fi
#7%
}%
}%
\fi
\@xsect{#5}\hskip 1pt
\par
}
\makeatother
\declaretheorem{theorem}
\begin{document}
\section{Test Section}
\begin{theorem}
Test theorem
\end{theorem}
\begin{restatable}[Fundamental Theorem of Algebra]{theorem}{fta}
\label{thm:FTA}
Every non-constant single-variable polynomial with complex coefficients has at least one complex root.
\end{restatable}
\appendix
\section[Proof of the Fundamental Theorem of Algebra]{Proof of Theorem~\ref{thm:FTA}}
\fta*
\begin{proof}
Assume...
\end{proof}
\end{document}
Explanation:
The problem is that vldb.cls
sets the section (and also part) titles in upper case and uses the old TeX \uppercase
command to this end; this will produce problems if special commands, such as \ref
, are inside the argument of \section
(or \part
) since \uppercase
don't recognize them as special commands and tretas them in the wrong way (the LaTeX command \MakeUppercase
will also behave bad in this regard). To correct this situation, one can redefine (or patch) the internal command \@sect
, to use \MakeTextUppercase
(from the textcase
package), instead of the problematic \uppercase
command. In the example code above, the change was signaled with % HERE
.
Assuming you're using a package such as amsthm
, you could proceed as follows: Assign a \label
to the theorem, and then cross-reference it via a \ref
statement at the start of the associated proof
environment.
\documentclass{article}
\usepackage{amsthm}
\usepackage{lipsum} % for filler text
\newtheorem{theorem}{Theorem}
\begin{document}
\begin{theorem}[Pythagoras] \label{thm:neat}
$a^2+b^2=c^2$.
\end{theorem}
\lipsum[2]
\begin{proof}[Proof of Theorem \ref{thm:neat}]
(state your proof here)
\end{proof}
\end{document}
Addendum: For comparison, here's the output of the same MWE (minus the filler text) if you were to use the ntheorem
package. (Observe that ntheorem
doesn't automatically place a QED symbol at the end of a proof
environment.)
\documentclass{article}
\usepackage{ntheorem}
\newtheorem{theorem}{Theorem}
\theoremstyle{empty}
\newtheorem{refproof}{Proof}
\begin{document}
\begin{theorem}[Pythagoras] \label{thm:neat}
$a^2+b^2=c^2$.
\end{theorem}
\begin{refproof}[Proof of Theorem \ref{thm:neat}]
(state your proof here)
\end{refproof}
\end{document}
Best Answer
From the documentation of
elsarticle
:The class provides
\newproof
for defining proof environments, but the implementation is not as good as inamsthm
, so my advice is to load it and useIf you want a different title, do
Replace the dots in
\ref{...}
with the appropriate label.