TeX - LaTeX Stack Exchange is a question and answer site for users of TeX, LaTeX, ConTeXt, and related typesetting systems. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

The below sum expression inside the equation throws an undefined control sequence error.

    \left\|x\left[t\right]-\textbf{1} F(X)\right\|^2 = \sum_{i = 1}^{n} \lambda_i^2t     \lvert x \left[ 0 \right] \rvert^2


Undefined control sequence.

|^2 = \sum_{i = 1}^{n} \lambda_i^2t \lvert 
                                        x \left[ 0 \right] \rvert^2

My guess is I am doing something wrong with the \lvert or \lambda. Don't know exactly. Any suggestion on how to solve this issue will be very helpful.

share|improve this question
Welcome to TeX.SE. It is always best to compose a fully compilable MWE that illustrates the problem including the \documentclass and the appropriate packages so that those trying to help don't have to recreate it. – Peter Grill May 21 '12 at 17:36
up vote 4 down vote accepted

You need to include \usepackage{amsmath}. The MWE below produces:

enter image description here

    \left\|x\left[t\right]-\textbf{1} F(X)\right\|^2 = \sum_{i = 1}^{n} \lambda_i^2t     \lvert x \left[ 0 \right] \rvert^2
share|improve this answer
Hi Peter, after including amsmath package, that problem is resolved but a new message is coming up "Package amsmath Error: Erroneous nesting of equation structures (amsmath) trying to recover with `aligned'." Any idea on why this is happening will be helpful. – Somnath Chakrabarti May 21 '12 at 17:38
@SomnathChakrabarti: Check whether you've inadvertently created nested equation environments. – Mico May 21 '12 at 18:01
As I suggested in the comments, please compose a fully compilable MWE that reproduces the problem including the \documentclass. – Peter Grill May 21 '12 at 18:01

Your Answer


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.