Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

LaTeX: Numbering only last line of multi-line equation in \align

Tags:

latex

I want to number and make a reference to just the last line of a multi-line equation in \align. Here is an example:

\begin{align} z_1^2 &= \left( 2 e^{i \frac{\pi}{3}} \right) \left( 2 e^{i \frac{\pi}{3}} \right)\\ &= 4 e^{i \frac{2 \pi}{3}} \end{align} 

I only want to number the &= 4 e^{i \frac{2 \pi}{3}} part, rather than both lines of the \align. How do I do this?

like image 738
Chetan Avatar asked Sep 14 '10 07:09

Chetan


People also ask

How do you reference multiple equations in LaTeX?

You can then use \cref{eq2,eq1,eq3,eq5,thm2,def1} in order to do it. Show activity on this post. The amsmath package introduces the subequations environment. The first label, 'all1', before the \begin{align} , creates a label for the complete set of equations (1, in this case).

How do you reference a numbered equation in LaTeX?

If you want to refer to a numbered equation, you can put a \label{ } command between the \begin{equation} and the \end{equation} .

How do you handle long equations in LaTeX?

(1) LATEX doesn't break long equations to make them fit within the margins as it does with normal text. It is therefore up to you to format the equation appropriately (if they overrun the margin.) This typically requires some creative use of an eqnarray to get elements shifted to a new line to align nicely.

How do you break a line in math in LaTeX?

In general, the command \\ signifies a line break and within the correct math mode environment, it can start a new equation line. Try the example on the right which sets the same multiple equations in several ways.


1 Answers

From the amsmath documentatiom (amsldoc.pdf):

You can suppress the number on any particular line by putting \notag before the \\;

So your equation should look like this (some bits removed from your equation to make it shorter):

\begin{align} z_1^2 &= \left( ... \right) \left( ... \right)\notag\\ &= 4 e^{i \frac{2 \pi}{3}} \end{align} 
like image 53
Michael Anderson Avatar answered Sep 25 '22 05:09

Michael Anderson