How do I define a equation e.g. x +y that shall be true for e.g. <5 and >0 in one equation? I was thinking of using a large brace, but I can't find any example of how to achieve this.
Asked
Active
Viewed 2.1k times
6
Franz Kafka
- 205
2 Answers
12
\documentclass{article}
\usepackage{amsmath}
\begin{document}
\[ x+y = \begin{cases} \mbox{true,} & \mbox{if } 0 < x < 5 \\ \mbox{false,} & \mbox{otherwise} \end{cases} \]
\end{document}
would give you:

Maarten Dhondt
- 5,860
-
1also I'm not sure if there should be commas after
trueorfalse(in English) but there should be comma after<5and perhaps a dot afterotherwise. – daleif Jan 28 '15 at 14:09
9
Another solution with \dcases* from mathtools
\documentclass{article}
\usepackage{mathtools}
\begin{document}
\[
x+y =
\begin{dcases*}
\text{true,} & if $0 < x < 5$ \\
\text{false,} & otherwise
\end{dcases*}
\]
\end{document}
Output

karlkoeller
- 124,410
\begin{cases} j & k \\ u & p \end{cases}?? – Sigur Jan 28 '15 at 13:36