0

I have read about braces spanning more than two lines here, and in many other places but am not sure about the mistake i've made in the following code,

\begin{align}
p\left( {l,m,n} \right) &= \left( {\frac{{{A_1}}}{{{A_1} + {A_2} + 
{A_3}}},\frac{{{A_2}}}{{{A_1} + {A_2} + {A_3}}}, \right. \nonumber \\ 
&\qquad \left. {} \frac{{{A_3}}}{{{A_1} + {A_2} + {A_3}}}} \right)
\end{align}

It compiles and gives the desired result, but also returns the error

Missing } inserted. \end{align}

Please help me with this issue, Thanks in advance for your help.

manoj
  • 3
  • 1
    (i) please, convert your code snippet to complete small document begining with\documentclas{...} and ending with end{document}. (ii) your equation is probably generated with some equation editor, consequently it has many unnecessary curly braces (iii) check with some editor, if all braces are paired. welcome to tex.se! – Zarko Aug 04 '17 at 16:09

1 Answers1

2

after cleaning "forest" of superfluous curly braces in your code sniped, i obtain:

\begin{align}
p(l,m,n) 
    & = \left(\frac{A_1}{A_1} + A_2 + A_3,
        \frac{A_2}{A_1} + A_2 + A_3, \right. \nonumber \\
    &\qquad \left.\frac{A_3}{A_1} + A_2 + A_3 \right)
\end{align} 

or,

\begin{equation}
p(l,m,n) 
      = \left(\frac{A_1}{A_1} + A_2 + A_3,\;
        \frac{A_2}{A_1} + A_2 + A_3,\;
        \frac{A_3}{A_1} + A_2 + A_3 \right)
\end{equation}

which gives

enter image description here

and (to my taste, better looking):

enter image description here

without any warnings or errors.

addendum:

in two column document the second option gives to wide equation. beside first option is worth to consider multline math environment:

\begin{multline}
p\left( {l,m,n} \right)
    = \left(\frac{A_1}{A_1} + A_2 + A_3,\right.     \\
        \left.\frac{A_2}{A_1} + A_2 + A_3,
              \frac{A_3}{A_1} + A_2 + A_3 \right)
\end{multline}

enter image description here

Zarko
  • 296,517
  • @egreg, oh, yes, i overlooked them :( – Zarko Aug 04 '17 at 16:26
  • @Zako thanks a lot for the answer.. I did clear the forest myself and it worked..I converted a whole document from mathtype and did not want to remove those braces. I prefer the second option but unfortunately it does not fit well in a two column format – manoj Aug 04 '17 at 16:31
  • @manoj, instead align see, if multline better fit your needs. i will add this option asap. – Zarko Aug 04 '17 at 18:00