# How to combine two lines into one line using closing brackets in a case environment with 3 lines?

For example, in LaTeX, I have three conditions in one "cases" environment. Then I could get a new condition from the combination of the first and the second conditions, so I want to use a right curly bracket to combine them, just like the following:

However, I don't know how to insert such a bracket to cover these two "lambda" equations.

Any help would be appreciated.

$\begin{cases} 2 = 2 \lambda x \\ 3 = 2 \lambda y \\ x^2 + y^2 - 4 = 0 \end{cases} \quad \Rightarrow \quad \begin{cases} \lambda = \frac{1}{x}\\ \lambda = \frac{3}{2y}\\ x^2 + y^2 - 4 = 0 \end{cases}$

• Welcome to TeX.SE! Apr 1 at 3:05

There are a number of ways to do this. Here's one - using an array to insert a null delimiter on the left and \} on the right.

\documentclass{article}

\usepackage{amsmath}

\begin{document}

$\begin{cases} 2 = 2 \lambda x \\ 3 = 2 \lambda y \\ x^2 + y^2 - 4 = 0 \end{cases} \quad \Rightarrow \quad \begin{cases} \kern-\nulldelimiterspace \left.\begin{array}{@{}l@{}} \lambda = \frac{1}{x} \\[\jot] \lambda = \frac{3}{2y} \end{array}\right\} \\ x^2 + y^2 - 4 = 0 \end{cases}$

\end{document}


The mathtools package, which is superset of the amsmath package (and, in fact, automatically loads the amsmath package) provides environments called dcases and drcases, which render their contents in display math mode by default; using display math mode is indicated when having to typeset systems of equations. The letter r in drcases indicates that the tall curly brace will be placed to the right of the environment.

As is done in @Werner's answer, I also suggest executing \kern-\nulldelimiterspace immediately before \begin{drcases}, in order offset the amount of horizontal whitespace that's inserted right before that environment.

\documentclass{article}
\usepackage{mathtools} % for 'dcases' and 'drcases' environments
\begin{document}

$\begin{dcases} 2 = 2\lambda x \\ 3 = 2\lambda y \\ x^2+y^2-4=0 \end{dcases} \quad\Rightarrow\quad \begin{dcases} \kern-\nulldelimiterspace \begin{drcases} \lambda = 1/x \\ \lambda = 3/(2y) \end{drcases} \\ x^2+y^2-4=0 \end{dcases}$

\end{document}