Sometimes in mathematics, when defining a function, I see something like
f(x) = 0 if x is even
1 if x is odd
where an open brace is used in front of the values 0 and 1. How can I do that in LaTeX?
Take a look here: http://en.wikibooks.org/wiki/LaTeX/Advanced_Mathematics#The_cases_environment, which perfectly answers your question.
Remember to include the amsmath package in your preamble: \usepackage{amsmath}
casesenvironment fromamsmathor perhapsdcasesfrommathtools; have a look at How to write conditional equations with one-sided curly brackets for example- there are lots of others on this site as well: search forcases site:tex.stackexchange.com– cmhughes Nov 12 '13 at 03:08