# Aligning an Expression - ! Missing } inserted

I am getting this error when I run this code. It all looks exactly like a different instance in which I was aligning stuff and had no problem:

\begin{align}
B \times B &=
\lbrace (1,1),(1,3),(1,5),(1,7),(3,1),(3,3),(3,5),(3,7), \right.    \nonumber\\
& \hspace{5mm} \left. (5,1),(5,3),(5,5),(5,7),(7,1),(7,3),(7,5),(7,7) \rbrace
\end{align}


The error is

! Missing } inserted.
<inserted text>
}
l.275 \end{align}
I've inserted something that you may have forgotten.
(See the <inserted text> above.)
With luck, this will get me unwedged. But if you
really didn't forget anything, try typing 2' now; then
my insertion and my current dilemma will both disappear.


I've just started with Latex so I might be missing something obvious.

• \left and \right should be a pair: \left\lbrace (1,1),(1,3),(1,5),(1,7),(3,1),(3,3),(3,5),(3,7), \right. \nonumber \\ & \hspace{5mm} \left. (5,1),(5,3),(5,5),(5,7),(7,1),(7,3),(7,5),(7,7) \right\rbrace – Akira Kakuto Apr 7 '15 at 2:57

## 3 Answers

Just remove \right. and \left. and you will get I believe you want. \lbrace and \rbrace are not required to be paired.

\documentclass[10pt,letterpaper]{article}
\usepackage{mathtools}
\begin{document}
\begin{align}
B \times B &=
\lbrace (1,1),(1,3),(1,5),(1,7),(3,1),(3,3),(3,5),(3,7),    \nonumber\\
& \hspace{5mm} (5,1),(5,3),(5,5),(5,7),(7,1),(7,3),(7,5),(7,7) \rbrace
\end{align}

\end{document}


To split something like that, we have multline

\documentclass{article}
\usepackage{mathtools}
\begin{document}
\begin{multline}
B \times B =
\{ (1,1),(1,3),(1,5),(1,7),(3,1),(3,3),(3,5),(3,7),    \\
(5,1),(5,3),(5,5),(5,7),(7,1),(7,3),(7,5),(7,7) \}
\end{multline}

\end{document}


Several good answers have already been given, but I would do things a little bit differently.

Like R. Schumacher, I would not use a \left, \right pair. Only I would put a \bigl, \bigr pair instead. (Two \big instructions would also have served, but \bigl and \bigr are more coherent and readable in this case, since they are supposed to be placed before left and right delimiters.)

Since there is only one equation, I would use an equation environment instead of align.

And as Harish Kumar suggested, I would split this equation in two lines, but since it is inside one equation here, the multlined environment of the mathtools package (a superset of amsmath) would be of use.

\documentclass{article}
\usepackage{mathtools}
\begin{document}
$$\begin{multlined} B \times B = \bigl\lbrace (1,1),(1,3),(1,5),(1,7),(3,1),(3,3),(3,5),(3,7), \\ (5,1),(5,3),(5,5),(5,7),(7,1),(7,3),(7,5),(7,7) \bigr\rbrace \end{multlined}$$
\end{document}
`