More vertical space between rows in array

arraysmath-modevspace

I would like to have a little more space between the rows of an array for better clarity. I tried \vspace{} at the end of the rows but LateX ignored it. I can accomplish something close to what I want with extra rows but that adds a bit more space than I'd like (but I can live with it). Here's what I have:

\documentclass{amsbook} 
\begin{document}
BEFORE:

\[
f(n) = \left\{ 
\begin{array}{cl} 
        0 & \text{if n=1 }\\ 
        \frac{n}{2} & \text{if n is even} \\ 
        -\left( \frac{n-1}{2}  \right)   & \text{if n $\ge$ 1 is odd} 
\end{array} \right.
\]

This is cramped visually, especially given my poor eyesight.

AFTER:

\[
f(n) = \left\{ 
\begin{array}{cl} 
        0 & \text{if n=1 }\\ 
        \\
        \frac{n}{2} & \text{if n is even} \\ 
        \\
        -\left( \frac{n-1}{2}  \right)   & \text{if n $\ge$ 1 is odd} 
\end{array} \right.
\]

This works but is overkill.
\end{document}

Best Answer

The \\ command has an optional length parameter. So you can add, e.g.,

\documentclass{amsbook} 
\begin{document}
BEFORE:

\[
f(n) = \left\{ 
\begin{array}{cl} 
        0 & \text{if n=1 }\\[6pt] 
        \frac{n}{2} & \text{if n is even} \\[9pt] 
        -\left( \frac{n-1}{2}  \right)   & \text{if n $\ge$ 1 is odd} 
\end{array} \right.
\]

This is cramped visually, especially given my poor eyesight.

AFTER:

\[
f(n) = \left\{ 
\begin{array}{cl} 
        0 & \text{if n=1 }\\[12pt] 
        \frac{n}{2} & \text{if n is even} \\[15pt] 
        -\left( \frac{n-1}{2}  \right)   & \text{if n $\ge$ 1 is odd} 
\end{array} \right.
\]

This works but is overkill.
\end{document}

according to your taste.

To tell the truth, I would rather write -\left( \dfrac{n-1}{2} \right) & \text{if $n \ge 1$ is odd} and so on, so that the number $n$ is always in math mode.

Related Question