Take the 2-minute tour ×
TeX - LaTeX Stack Exchange is a question and answer site for users of TeX, LaTeX, ConTeXt, and related typesetting systems. It's 100% free, no registration required.

I'm getting errors in the align environment that I'm not getting for the exact same line that compiles without error in the equation one and I can't figure it out. Can someone shed some light on this? Here's the code:

\begin{align*}
t\left(2^{\left(m+1\right)} \right) &= t\left(\frac{2^{\left(m+1\right)}}            
{2}\right)+3\log 2^{\left(m+1\right)}\\ 
&= t\left(2^m\right)+3\left(m+1\right)\\ &=t'\left(2^m)+3(m+1)\\ 
&=\frac{3\left(\log_2 n\right)\left(\log_2 n+1\right)}  {2}
\end{align*}

the error is showing up for the last line:

! Extra }, or forgotten \right.
! Missing \right. inserted.
share|improve this question
    
See #10 in Documents with typical LaTeX errors. –  Werner Oct 27 '12 at 23:54
add comment

1 Answer

up vote 3 down vote accepted

You have a missing \right in

&=t'\left(2^m)+3(m+1)\\

Corrected code:

\documentclass{article}
\usepackage{amsmath}

\begin{document}

\begin{align*}
t\left(2^{\left(m+1\right)} \right) 
      &= t\left(\frac{2^{\left(m+1\right)}}
        {2}\right)+3\log 2^{\left(m+1\right)}\\
      &= t\left(2^m\right)+3\left(m+1\right)\\ 
      &=t'\left(2^m\right)+3(m+1)\\
      &=\frac{3\left(\log_2 n\right)\left(\log_2 n+1\right)}  {2}
      \end{align*}

\end{document}

enter image description here

share|improve this answer
    
You were faster than me!! lol –  Sigur Oct 27 '12 at 23:30
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.