
분수가 포함된 일부 방정식을 제시하기 위해 사례를 사용하려고 하는데 선이 너무 압축되어 쉽게 읽을 수 없다는 사실을 발견했습니다. 줄 사이의 간격과 조판 문자의 크기를 모두 늘리는 방법이 있습니까? MWE는
\documentclass{article}
\usepackage{amsmath}
\begin{document}
\begin{align*}
A = \begin{cases}
\frac{B-.5b}{C-.5c} & \text{sometimes} \\
\frac{D-.3d}{E-.7e} & \text{other times}
\end{cases}
\end{align*}
\end{document}
생산하는
답변1
mathtools
amsmath
다음으로 확장 dcases
:
\documentclass{article}
\usepackage{mathtools}
\begin{document}
\[
A = \begin{dcases}
\frac{B-.5b}{C-.5c} & \text{sometimes} \\
\frac{D-.3d}{E-.7e} & \text{other times}
\end{dcases}
\]
\end{document}
답변2
cases
다음은 를 사용하여 복제하는 방법을 보여줍니다 array
.
\documentclass{article}
\usepackage{amsmath}
\begin{document}
\begin{align*}
A = \begin{cases}
\frac{B-.5b}{C-.5c} & \text{sometimes} \\
\frac{D-.3d}{E-.7e} & \text{other times}
\end{cases}
\end{align*}
\begin{align*}
A &= \begin{cases}
\frac{B-.5b}{C-.5c} & \text{sometimes} \\
\frac{D-.3d}{E-.7e} & \text{other times}
\end{cases} \\
A &= \renewcommand{\arraystretch}{1.5}\left\{\begin{array}{@{}l@{\quad}l@{}}
\frac{B-.5b}{C-.5c} & \text{sometimes} \\
\frac{D-.3d}{E-.7e} & \text{other times}
\end{array}\right.\kern-\nulldelimiterspace
\end{align*}
\end{document}
첫 번째는 align*
출력을 복제하고 두 번째는 align*
원본 cases
과 array
구현을 포함합니다. 를 사용할 때 " " 구성을 수직으로 늘리도록 array
조정할 수 있습니다 (다른 제안과 유사).\arraystretch
cases
테이블의 열 및 행 패딩).
아래 \arraystretch
에 대한 기본값은 다음과 같습니다.cases
amsmath
는 정의 1.2
에 묘사된 바와 같습니다 \env@cases
(에서 따옴)amsmath
.dtx`):
\def\env@cases{%
\let\@ifnextchar\new@ifnextchar
\left\lbrace
\def\arraystretch{1.2}%
\array{@{}l@{\quad}l@{}}%
}
물론 이 기본 확장 요소를 더 큰 값으로 변경할 수 있지만 내 가정에서는 전체 변경을 수행하기보다는 특정 인스턴스만 약간 공개하기를 1.2
원한다고 가정합니다 .cases
\dfrac
대신 를 사용하여 문자 크기를 조정할 수 있습니다 \frac
. 그러나 이를 \arraystretch
위해서는 1.5
. 시각적으로 이것을 통해 무엇을 얻을 수 있는지 잘 모르겠습니다.
답변3
내가 한 일은 각 줄을 호출 \displaystyle
하고 추가 빈 줄을 삽입하는 것뿐이었습니다. 패키지가 로드될 때 \dfrac
대신 사용하도록 편집되었습니다(Werner의 알림에 따라) .\displaystyle\frac
amsmath
\documentclass{article}
\usepackage{amsmath}
\begin{document}
\begin{align*}
A = \begin{cases}
\dfrac{B-.5b}{C-.5c} & \text{sometimes} \\
\\
\dfrac{D-.3d}{E-.7e} & \text{other times}
\end{cases}
\end{align*}
\end{document}
답변4
위의 모든 답변에 추가
유용한 기능은수직 거리cases
, array
또는 유사한 환경 의 방정식 사이 . 단순히 .\\[your distance with units]
\\
예를 들어 \\[1.5em]
. 음수 간격에도 작동합니다. 예:\\[-0.5em]
이 최소한의 예에서는\\[1.0em]
\documentclass{article}
\usepackage{amsmath}
\begin{document}
\begin{align*}
A = \begin{cases}
\dfrac{B-.5b}{C-.5c} & \text{sometimes} \\[1.0em]
\dfrac{D-.3d}{E-.7e} & \text{other times}
\end{cases}
\end{align*}
\end{document}
이 코드는 Steven B. Segletes가 수정한 것입니다. 제 생각에는 빈 줄을 하나 더 추가하는 것보다 더 멋져 보입니다. ;)