Take the 2-minute tour ×
TeX - LaTeX Stack Exchange is a question and answer site for users of TeX, LaTeX, ConTeXt, and related typesetting systems. It's 100% free, no registration required.

I am writing a quite long proof in a LaTeX file and I would like to create a "claim" environment to put inside said proof. Can someone help me to understand how this can be done, or at least redirect me to some manual or other resource where it is explained?

What I would like precisely is two environments:

claim: similar to theorem, but maybe instead of getting Claim (bold), only underlined.

claimproof: similar to the proof environment, but with a black box at the end, to distinguish its end from the end of the full proof of the theorem.

share|improve this question
2  
Welcome to TeX.SE! have a look at the amsthm, ntheorem, and perhaps thmtools packages to help you with this :) –  cmhughes Mar 24 '13 at 16:56

1 Answer 1

up vote 4 down vote accepted

Requires amssymb for the black square.

\newenvironment{claim}[1]{\par\noindent\underline{Claim:}\space#1}{}
\newenvironment{claimproof}[1]{\par\noindent\underline{Proof:}\space#1}{\hfill $\blacksquare$}

You can edit and use Claim's proof for example, or anything else. Also, adjust the space above and below, if you want.

\begin{claim}
foo
\end{claim}

\begin{claimproof}
foo
\end{claimproof}

enter image description here

ps: Following the suggestion by @barbara beeton, to avoid new lines before the black square, replace the last pair of {} by

{\leavevmode\unskip\penalty9999 \hbox{}\nobreak\hfill\quad\hbox{$\blacksquare$}}
share|improve this answer
    
That's perfect. Thank you very much. –  Daniel Robert-Nicoud Mar 24 '13 at 16:59
    
@DanielRobert-Nicoud, you're welcome. Try to improve the code using some other commands for spaces above and below, like theorems does. Now you have the starting point. –  Sigur Mar 24 '13 at 17:01
2  
this definition could leave the black box at the beginning of a line by itself, if you're unlucky enough to have the text of the claim end at the end of a line. better to steal the code from amsthm: \leavevmode\unskip\penalty9999 \hbox{}\nobreak\hfill\quad\hbox{$\blacksquare$} –  barbara beeton Mar 24 '13 at 17:27
    
How could I imagine this?! Nice! I'll edit and cite your code. –  Sigur Mar 25 '13 at 10:11

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

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