5
\documentclass[twoside,11pt]{book}
\usepackage[left=2.5cm,right=2cm,top=2cm,bottom=2cm,papersize={15.5cm,23.5cm}]{geometry}
\renewcommand{\thechapter}{\Roman{chapter}}
\renewcommand{\thesection}{\arabic{chapter}.\arabic{section}.}
\renewcommand{\thesubsection}{\arabic{chapter}.\arabic{section}.\arabic{subsection}.}
\usepackage{amsthm}
\newtheorem{definition}{Definition}[section]
\newtheorem{theorem}{Theorem}[section]
\renewcommand{\thetheorem}{\thesection\arabic{theorem}}
\renewenvironment{proof}{{\noindent\bfseries Proof.}}{\qedsymbol}
\renewcommand{\qedsymbol}{\rule{1ex}{1ex}}

\begin{document}
    \chapter{ABC}
    blablabla
    \section{ONE}
    \begin{theorem}
        dddd
    \end{theorem}
\begin{proof}
    It is clear.
\end{proof}
\end{document}

I want the text Proof is bold. So I write:

\renewenvironment{proof}{{\noindent\bfseries Proof.}}{\qedsymbol}

Now, I want to Q.E.D. symbol is black square, so I write

\renewcommand{\qedsymbol}{\rule{1ex}{1ex}}

Why the Q.E.D. symbol show after the sentence end and can't show right aligned (as picture below)? How to make it?

enter image description here

I want:

enter image description here

2
  • 4
    \renewenvironment{proof}{{\noindent\bfseries Proof.}}{\qedsymbol} has completely removed all the definition of the proof environment and its placement of the header and of the qed symbol, the end code just dumps the symbol as if you had written \qedsymbol at the end of the text. Apr 3, 2022 at 14:13
  • 5
    Why are you redefining proof to begin with? If it's just in order to get “Proof” in boldface, there are much better methods: see tex.stackexchange.com/a/251251/4427
    – egreg
    Apr 3, 2022 at 14:34

3 Answers 3

5

My suggestion is to use https://tex.stackexchange.com/a/251251/4427 with also a redefinition of \qedsymbol.

\documentclass{article}

\usepackage{amsthm}
\usepackage{xpatch}

\providecommand{\proofnamefont}{\itshape}% the default
\xpatchcmd{\proof}{\itshape}{\normalfont\proofnamefont}{}{}
\renewcommand{\proofnamefont}{\bfseries}% your preference

\renewcommand{\qedsymbol}{\rule{1ex}{1ex}}

\begin{document}

\begin{proof}
Obvious, isn't it?
\end{proof}

\end{document}

enter image description here

6

From your MWE, came to understand that you need the Proof name in Bold face and the qedsymbol should be in solid black square, for that no need to redefine the proof environment, you can modify the \proofname and \qedsymbol as you wish, and the modified MWE is:

\documentclass[twoside,11pt]{book}
\usepackage[left=2.5cm,right=2cm,top=2cm,bottom=2cm,papersize={15.5cm,23.5cm}]{geometry}
\renewcommand{\thechapter}{\Roman{chapter}}
\renewcommand{\thesection}{\arabic{chapter}.\arabic{section}.}
\renewcommand{\thesubsection}{\arabic{chapter}.\arabic{section}.\arabic{subsection}.}
\usepackage{amsthm}
\newtheorem{definition}{Definition}[section]
\newtheorem{theorem}{Theorem}[section]
\renewcommand{\thetheorem}{\thesection\arabic{theorem}}
%\renewenvironment{proof}{{\noindent\bfseries Proof.}}{\qedsymbol}
\renewcommand{\proofname}{\upshape\textbf{Proof}}
\renewcommand{\qedsymbol}{\rule{1ex}{1ex}}

\begin{document}
    \chapter{ABC}
    blablabla
    \section{ONE}
    \begin{theorem}
        dddd
    \end{theorem}
\begin{proof}
    It is clear.
\end{proof}
\end{document}

And the output is:

enter image description here

4

You can redefine the \proofname and \qedsymbol as folows. It's not necessary to create a black square by the rule command since there is a \blacksquare command in the amssymb package which could produce a black square as the same size as the (white) square.

\documentclass[twoside,11pt]{book}
\usepackage[left=2.5cm,right=2cm,top=2cm,bottom=2cm,papersize={15.5cm,23.5cm}]{geometry}
\renewcommand{\thechapter}{\Roman{chapter}}
\renewcommand{\thesection}{\arabic{chapter}.\arabic{section}.}
\renewcommand{\thesubsection}{\arabic{chapter}.\arabic{section}.\arabic{subsection}.}
\usepackage{amsthm}
\newtheorem{definition}{Definition}[section]
\newtheorem{theorem}{Theorem}[section]
\renewcommand{\thetheorem}{\thesection\arabic{theorem}}

\renewcommand{\proofname}{\upshape\bfseries Proof}
\usepackage{amssymb}
\renewcommand{\qedsymbol}{\ensuremath\blacksquare}

\begin{document}
    \chapter{ABC}
    blablabla
    \section{ONE}
    \begin{theorem}
        dddd
    \end{theorem}
\begin{proof}
    It is clear.
\end{proof}
\end{document}

And the output is as follows.

enter image description here


By the way, the chapter numbers should not be roman since the prefixes in section numbers are arabic. Also, it's not necessary to add dots after section numbers since there are no dots after chapter numbers.

4
  • Can you link to more information on the roman/arabic prefixes
    – Brandon
    Apr 4, 2022 at 9:34
  • @Brandon I don't know what you want and how to link to my mind...
    – M. Logic
    Apr 4, 2022 at 9:45
  • is there any reason other than that they are different?
    – Brandon
    Apr 4, 2022 at 9:46
  • In fact, the chapter numbers and the prefixes in section numbers should be the same since they refer to the same object.
    – M. Logic
    Apr 4, 2022 at 9:48

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .