GeneralProof environment numbered not like I want

LaTeX specific issues not fitting into one of the other forums of this category.
Post Reply
thedoctor818
Posts: 92
Joined: Fri Apr 24, 2009 8:02 pm

Proof environment numbered not like I want

Post by thedoctor818 »

I am using ntheoerem and have defined my own proof environment. But I want the proofs to (like the default) have no numbering. I have tried altering the setup to nonumber but still the proofs are numbered. Here is my MWE:

Code: Select all


\documentclass[a4paper,12pt,twoside]{book}

\usepackage[left=2.50cm,right=2.50cm,top=2.50cm,bottom=2.75cm]{geometry}
\usepackage{amsmath,amssymb,amscd,amsbsy,array,color}
\usepackage{fancyhdr,framed,latexsym,multicol,pstricks,slashed,xcolor}
\usepackage{picture}
\usepackage{indentfirst}
\usepackage{enumitem}

\usepackage[amsmath,framed,thmmarks]{ntheorem}


\newtheorem{Theorem}{Theorem}

\theoremclass{Theorem}
\theoremstyle{break}
\theoreminframepreskip{0pt}
\theoreminframepostskip{0pt}
\theoremframepreskip{1cm}
\theoremframepostskip{1cm}
\theoremstyle{break}
\def\theoremframecommand{%
	\psshadowbox[fillstyle=solid,fillcolor=blue,linecolor=black]}
\newshadedtheorem{them}[section]{Theorem}

\theoremstyle{nonumberplain}
\theoremsymbol{\rule{1ex}{1ex}}
\theoreminframepreskip{0pt}
\theoreminframepostskip{0pt}
\theoremframepreskip{1cm}
\theoremframepostskip{1cm}
\theoremstyle{break}
\def\theoremframecommand{%
	\psshadowbox[fillstyle=solid,fillcolor=red,linecolor=black]}
\newshadedtheorem{proof}{Proof}

\begin{document}
\author{Michael Dykes and Croix Snapp}
\title{Real and Complex Analysis}
\date{\today}

\chapter{Logic, Set Theory, Functions, and Relations.}
\section{Basic Set Theory.}
\subsection{Introduction.}

\begin{them}
    Let $X$ be any set. Then:
        \begin{enumerate}
            \item $\emptyset \subseteq X.$
            \item $X \subseteq X.$
        \end{enumerate}
\end{them}

\begin{proof}\mbox{}
    \begin{enumerate}
        \item Let $X$ be any set, and let $x$ be any object. Then, let $x \in \emptyset.$ Hence $(\forall x) (X \in \emptyset \Rightarrow x \in X). \,\therefore \emptyset \subseteq X$ [since the hypothesis is false].
        \item Let $X$ be any set, and let $x$ be any object. Then $x \in X \Rightarrow x \in X.$ Hence $(\forall x)(x \in X \Rightarrow x \in X). \, \therefore X \subseteq X.$
    \end{enumerate}
\end{proof}

\end{document}

-Michael D

Recommended reading 2024:

LaTeXguide.org • LaTeX-Cookbook.net • TikZ.org

Learn LaTeX easily with newest books:

The LaTeX Beginner's Guide: 2nd edition and perfect for students writing a thesis

The LaTeX Cookbook: 2nd edition full of practical examples for mathematics, physics, chemistry, and more

LaTeX Graphics with TikZ: the first book about TikZ for perfect drawings in your LaTeX thesis

User avatar
Stefan Kottwitz
Site Admin
Posts: 10360
Joined: Mon Mar 10, 2008 9:44 pm

Proof environment numbered not like I want

Post by Stefan Kottwitz »

Hi Michael!

You could use the nonumberplain style:

Code: Select all

\theoremstyle{nonumberplain}
\def\theoremframecommand{%
        \psshadowbox[fillstyle=solid,fillcolor=red,linecolor=black]}
\newshadedtheorem{proof}{Proof}

Stefan
LaTeX.org admin
thedoctor818
Posts: 92
Joined: Fri Apr 24, 2009 8:02 pm

Proof environment numbered not like I want

Post by thedoctor818 »

Thanks Stefan!

That does indeed work. However, I loose the qed symbol at the end of the proof enviornment.

I tried adding the following:

Code: Select all

\theoremsymbol{\rule{1ex}{1ex}}
and that brought the qed symbol back for some of my proofs except thoose that included an enumerated list within the body of the proof.

Additionally, in thoose proofs (the ones that included an enumerated list) I see that the end of theorem symbol is not at the end of the proof but rather midway towards the end of the proof. Any way to fix this?

Thanks so very much!
-Michael D
Post Reply