For the following piecewise function
f(x)= \left\{ \begin{array}{lr} 1 - e^{-(c\lambda)x}& \text{if }X\text{ is exponential} \\1-(1-p_{X})^{cx} &\text{if }X\text{ is geometric}. \end{array} \right
I am trying to align "if X is exponential" and "if X is geometric".
Cheers.
Math & Science ⇒ piecewise function
piecewise function
Hi,
you could use the cases environment provided by the amsmath package:
you could use the cases environment provided by the amsmath package:
Code: Select all
\documentclass{article}
\usepackage{amsmath}
\begin{document}
\begin{equation}
f(x)=%
\begin{cases}
1 - e^{-(c\lambda)x} &\text{if $X$ is exponential} \\
1-(1-p_{X})^{cx} &\text{if $X$ is geometric}.
\end{cases}
\end{equation}
\end{document}
1,1,2,3,5,8,13,21,34,55,89,144,233,...