如何增加 \begin{proof} 环境的行距?

如何增加 \begin{proof} 环境的行距?

我希望更改 amsthm 证明环境中的间距(在我的情况下,增加间距)。我已经包含了我的尝试。我不想要编号,所以我添加了 *。但是,我的尝试失败了,因为它没有在最右边的证明末尾包含 QED 符号(我需要它)。有人知道如何获得增加的间距和 QED 符号吗?我已经包含了我的代码的输出,以便每个人都可以看到我的 myplain2 环境和 \begin{proof} 环境之间的区别(我的代码有我想要的间距,但没有 QED 符号,而 \begin{proof} 环境没有我想要的间距,但有 QED 符号)。

\newtheoremstyle{myplain2}
 {-\baselineskip\topsep}   % ABOVESPACE
  {\topsep}   % BELOWSPACE
  {\normalfont\setstretch{2}}  % BODYFONT
  {0pt}       % INDENT (empty value is the same as 0pt)
  {\bfseries} % HEADFONT
  {.}         % HEADPUNCT
  {5pt plus 1pt minus 1pt} % HEADSPACE
  {}   
\theoremstyle{myplain2}
\newtheorem*{proof_new}{Proof}

\begin{proof}
Oh hi Mark.\\
Oh hi Mark.\\
Oh hi Mark.
\end{proof}

\begin{proof_new}
Oh hi Mark.\\
Oh hi Mark.\\
Oh hi Mark.
\end{proof_new}


在此处输入图片描述

答案1

我不确定原因是什么。无论如何……

\documentclass{article}
\usepackage{amsmath}
\usepackage{amsthm}
\usepackage{setspace}

\usepackage{lipsum} % for mock text

% spaced proof
\newenvironment{sproof}
 {\par\vspace{-\topsep}\begin{spacing}{1.5}\begin{proof}}
 {\end{proof}\end{spacing}\par\vspace{-\topsep}}

\begin{document}

\lipsum[1][1-5]

\begin{proof}
\lipsum[2][1-5]
\end{proof}

\lipsum[1][1-5]

\begin{sproof}
\lipsum[2][1-5]
\end{sproof}

\lipsum[1][1-5]

\end{document}

在此处输入图片描述

答案2

您可以使用 setspace 包来设置与空间环境的证明间距。

下面给出一个例子:

\documentclass[12pt,a4paper]{book} 
\usepackage{setspace}

\renewcommand{\baselinestretch}{1} 


\begin{document}
    
    Lorem Ipsum is simply dummy text of the printing and typesetting industry. Lorem Ipsum has been the industry's standard dummy text ever since the 1500s, when an unknown printer took a galley of type and scrambled it to make a type specimen book.
    
    \begin{spacing}{2}
        Lorem Ipsum is simply dummy text of the printing and typesetting industry. Lorem Ipsum has been the industry's standard dummy text ever since the 1500s, when an unknown printer took a galley of type and scrambled it to make a type specimen book. It has survived not only five centuries, but also the leap into electronic typesetting, remaining essentially unchanged. It was popularised in the 1960s with the release of Letraset sheets containing.
    \end{spacing}


    Lorem Ipsum is simply dummy text of the printing and typesetting industry. Lorem Ipsum has been the industry's standard dummy text ever since the 1500s, when an unknown pri.



\end{document}

间距输出

相关内容