# resizing delimiters in LaTeX with line breaks

IEEE uses a two-column format that is a bit narrow for large formulae, and it makes parenthesis resizing a pain when you have to break lines, because LaTeX (apparently) will not match parenthesis sizes across lines. For example, consider

\mathbb{P}\left(\frac{1}{N}\sum_{i=1}^{N}\mathbf{1}(\mathbf{y}(Tc\in{D(Z_{i,c})})>G\right)

So if you have a \exp \left( followed by some tall expression, like - \sum_{i=1}^{n} \frac{1}{2^i} \int_{\mathbb{R}} \langle f_i(t), g(t) \rangle dt + \prod_{i=1}^{n} f_i(0) - \lim_{x \to \infty} \frac{g(t)}{2 \pi} you start to run into problems fitting the whole thing on the line so that the corresponding \right) fits within the page margin. Furthermore, if the equation has multiple opening brackets and different size elements, the opening and closing brackets may not match in size when you break the line.

My old hack for this was to manually resize the \left( by using \Big\left( or something like that, putting empty \right. commands before the line break, and then starting the next line with empty \left. commands. If you have multiple opening and closing brackets you have to futz around, putting a \Big or \Bigger around each delimiter to make it fit, but a (somewhat) easier hack is to insert a tall whitespace like this:

\\rule{0pt}{15pt} \\right. \\right. \\nonumber \\\\
&
\\left. \\left. \\rule{0pt}{15pt}


This isn’t too great a savings, since I now have to resize 2 things instead of 4, but it’s something at least, and the delimiters end up the same size. I could probably write a macro to do this, but that seems like a waste of time.

## 2 thoughts on “resizing delimiters in LaTeX with line breaks”

1. Roy says:

Funny but I’ve never used \Big and \Bigger. Somewhere along the way I adopted \bigl and \bigr and \Bigl and \Bigr. (Maybe they are amsmath terminology?) For a two line break, you could make a macro with two arguments where each argument is the math that goes on a line. The marco would puts each argument in a box, measures the height of each box, then puts a strut next to each that is the max height of the two boxes. You could also put the various \left and \right commands in the macro. However, that solution will be limited to equaitons broken over two lines so maybe itsnot worth the trouble.

Another thought is that if you are writing equations that don’t fit on one line, then you haven’t defined enough functions.

2. Somehow creating a macro for two-line equations seems like it would make the tex less readable, but I think that’s probably the least of my worries.

I thought about defining functions for everything so that I would have \exp(-n D(x||y) + small terms), but I thought that would be harder to read…

This site uses Akismet to reduce spam. Learn how your comment data is processed.