0

In my opinion the proof environment has too big of a top margin. I'd like to have it visually closer to the proposition or theorem it refers to.

I have verified that adding \vspace{-3ex} before a proof environment gets me the result I want. Now, how do I modify the proof environment?

I tried to redefine it, but I don't know the original definition and I didn't find it in my Latex distribution.

MWE:

\documentclass{article}

\usepackage{amsmath}
\usepackage{amsthm}
\usepackage{thmtools}
\usepackage[dvipsnames]{xcolor}

\declaretheoremstyle[
    spaceabove=\topsep,
    spacebelow=\topsep,
    name={\color{Blue}Proposition},
]{propsty}
\declaretheorem[style=propsty]{prop}

\begin{document}
\begin{prop}
    This is a proposition.
\end{prop}

\begin{proof}
    The proof is left as an exercise for the reader.
\end{proof}

\begin{prop}
    This is another proposition.
\end{prop}

\vspace{-3ex}
\begin{proof}
    The proof is left as an exercise for the reader and it's closer to the
    relevant proposition.
\end{proof}
\end{document}

Choosing a negative value for spacebelow didn't seem to do anything. So I decided to change the proof environment.

  • 1
    we don't know where the definition of proof is either. please provode a small compilable example that shows the problem. and remember, a proof does not always follow directly after the theorem or proposition it refers to; in such a case, the extra space would be useful. – barbara beeton Jun 7 '16 at 14:59
  • @barbarabeeton I'm sorry, I added a MWE to the question. – rubik Jun 7 '16 at 15:12
1

You can have this, for instance:

\documentclass{article}

\usepackage{amsmath}
\usepackage{amsthm}
\usepackage{thmtools}
\usepackage[dvipsnames]{xcolor}

\declaretheoremstyle[
    spaceabove=0\topsep,
    spacebelow=0\topsep,
    name={\color{Blue}Proposition},
]{propsty}
\declaretheorem[style=propsty]{prop}

\declaretheoremstyle[
    spaceabove=0.5\topsep,
    spacebelow=0.5\topsep,
    name={\color{Blue}Proposition},
]{propsty}
\declaretheoremstyle[
    spaceabove=0.5\topsep,
    spacebelow=1\topsep,
    name=Proof,
    headfont=\itshape, numbered=no
]{proofsty}
\declaretheorem[style=proofsty]{myproof}
\raggedbottom
\begin{document}
\begin{prop}
    This is a proposition.
\end{prop}

\begin{myproof}
    The proof is left as an exercise for the reader.
\end{myproof}

\begin{prop}
    This is another proposition.
\end{prop}


\begin{myproof}
    The proof is left as an exercise for the reader and it's closer to the
    relevant proposition.
\end{myproof}
\end{document} 

enter image description here

  • Very nice. Is there a way to redefine the proof environment so that I can keep that same name? – rubik Jun 7 '16 at 16:35
  • Unfortunately I don't know amsthm very well (personally, I use ntheorem). The ntheorem package allows declarations like \renewtheorem or \renewtheoremstyle. – Bernard Jun 7 '16 at 17:12

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.