Niko Gamulin - 5 months ago 30
LaTeX Question

# How to display two-rows bracket in Latex?

Does anyone know how to modify the following string in order to display the two-lines bracket?

str = '$$c_i =\{\begin{array}{l l} 1 \quad L\left(Q_i\right) < 0 \\ 0 \quad L\left(Q_i\right) \geq 0 \\ \end{array}$$';


The current output is the following:

The sign '{' has to embrace both rows (1 and 0).

$$c_i =\begin{cases} 1 & L\left(Q_i\right) < 0 \\ 0 & L\left(Q_i\right) \geq 0 \end{cases}$$

The tex file should have \usepackage{amsmath} in the preamble.