Increase row height in align* cases environment
mathtools
extends amsmath
with 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}
The following shows how you can replicate cases
using an 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}
The first align*
replicates your output, while the second align*
includes the original cases
plus an array
implementation. When using an array
, you can adjust \arraystretch
to stretch out the "cases
" construction vertically (similar to other suggestions in Column and row padding in tables).
Note that the default \arraystretch
for cases
under amsmath
is 1.2
, as depicted in the \env@cases
definition (taken from amsmath
.dtx`):
\def\env@cases{%
\let\@ifnextchar\new@ifnextchar
\left\lbrace
\def\arraystretch{1.2}%
\array{@{}l@{\quad}l@{}}%
}
Of course you could change this default 1.2
stretch factor to something larger, but my assumption is that you want only a specific instance of cases
to be slightly aired out rather than make a global change.
The size of the characters can be adjusted by using \dfrac
instead of \frac
. However, this would require a larger \arraystretch
than 1.5
. I'm not sure what is to be gained by this visually.
All that I did was to invoke \displaystyle
for each line and to insert an extra blank line. EDITED (upon Werner's reminder) to use \dfrac
instead of \displaystyle\frac
, when the amsmath
package is loaded.
\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}