
나는 정리와 같은 환경을 구성하고 싶습니다. 그것이 본문에서 눈에 띄게 만드는 효과적인 방법이기 때문입니다.
에 따르면곤잘로 메디나의 답변질문에정리문 주위의 상자, 패키지 \newmdtheoremenv
의 명령을 mdframed
사용하는 것이 좋습니다.
그러나 이러한 프레임 정리 환경 전후에는 수직 공간이 부족하다는 것을 알았습니다(아래 참조). 문서를 살펴봤지만 mdframed
이 문제를 해결할 수 있는 내용을 찾지 못했습니다.
제가 문서에서 뭔가를 놓쳤나요?
이 문제를 쉽고 효율적인(자동) 방법으로 어떻게 해결하시겠습니까?
mdframed
프레임 정리 환경에 더 적합한 패키지가 있습니까 ?
\documentclass{book}
\usepackage{amsmath}
\usepackage{amsthm}
\usepackage{mdframed}
\theoremstyle{definition}
\newmdtheoremenv{assum}{Assumption}[chapter]
\begin{document}
\chapter{Fluid mechanics}
\section{Fields}
The following fields are of particular interest:
\begin{itemize}
\item $\rho$: fluid density (time-dependent scalar field);
\item $p_{\text{tot}}$: total pressure in the fluid (time-dependent scalar field);
\item $v$: velocity of the fluid parcels (time-dependent vector field).
\end{itemize}
\begin{assum}[Differentiability of tensor fields]
\label{assum:differentiability}
All tensor fields of interest are differentiable (weakly, at least).
\end{assum}
Assumption~\ref{assum:differentiability} blah blah
\subsubsection{Mass-continuity equation}
The mass-continuity equation is derived from the principle of conservation of mass:
\begin{assum}[Conservation of mass]
\label{assum:conservation_of_mass}
Fluid density $\rho$ is a conserved quantity within fluid parcels:
if $V_{\text{fp}}(t)$ delimits a region of space occupied by a fluid parcel
at time $t$, then
\begin{equation}
\frac{\mathrm{d}\phantom{t}}{\mathrm{d}t}
\iiint_{ V_{\text{fp}}(t)} \rho \, \mathrm{d}V = 0\,.
\end{equation}
\end{assum}
blablah
\end{document}
답변1
예, 환경에 옵션을 전달할 수 있다는 점을 놓쳤습니다. 특히 다음을 사용할 수 있습니다 skipabove=<length>
.skipbelow=<length>
\newmdtheoremenv[skipabove=\topsep,skipbelow=\topsep]{assum}{Assumption}[chapter]
귀하의 예:
\documentclass{book}
\usepackage{amsmath}
\usepackage{amsthm}
\usepackage{mdframed}
\theoremstyle{definition}
\newmdtheoremenv[skipabove=\topsep,skipbelow=\topsep]{assum}{Assumption}[chapter]
\begin{document}
\chapter{Fluid mechanics}
\section{Fields}
The following fields are of particular interest:
\begin{itemize}
\item $\rho$: fluid density (time-dependent scalar field);
\item $p_{\text{tot}}$: total pressure in the fluid (time-dependent scalar field);
\item $v$: velocity of the fluid parcels (time-dependent vector field).
\end{itemize}
\begin{assum}[Differentiability of tensor fields]
\label{assum:differentiability}
All tensor fields of interest are differentiable (weakly, at least).
\end{assum}
Assumption~\ref{assum:differentiability} blah blah
\subsubsection{Mass-continuity equation}
The mass-continuity equation is derived from the principle of conservation of mass:
\begin{assum}[Conservation of mass]
\label{assum:conservation_of_mass}
Fluid density $\rho$ is a conserved quantity within fluid parcels: if $V_{\text{fp}}(t)$ delimits a region of space occupied by a fluid parcel at time $t$, then
\begin{equation}
\frac{\mathrm{d}\phantom{t}}{\mathrm{d}t} \iiint_{ V_{\text{fp}}(t)} \rho \, \mathrm{d}V = 0\,.
\end{equation}
\end{assum}
blablah
\end{document}
이것은 두 가지 첫 번째 질문에 대한 답변입니다. 세 번째와 관련하여 프레임이 페이지 나누기를 허용해야 하는 경우 가능성은 기본적으로 mdframed
또는 framed
; 이 질문은 그것들을 비교합니다.액자 또는 mdframed? (장점/단점).