6

I am trying to align the equations, but the alignment has done something wrong to the spacing. The equation in the first line has moved to the right.

\documentclass[12pt,letterpaper]{article}
\usepackage[a4paper,left=20mm,top=25mm,right=20mm,bottom=25mm]{geometry}
\usepackage[utf8]{inputenc}
\usepackage{amsmath}
\begin{document}
Asymptotic equation of Motion
\begin{align*}
\mathcal{L}_n (\nabla_{\mu} n_{\nu}) &=& n^{\alpha} \nabla_{\alpha} ( 
\nabla_{\mu} n_{\nu}) + \nabla_{\alpha} n_{\nu} \nabla_{\mu} n^{\alpha} + 
\nabla_{\mu} n_{\alpha} \nabla_{\nu} n^{\alpha} \\
&=& n^{\alpha} \nabla_{\alpha} ( \nabla_{\mu} n_{\nu}) - n^{\alpha} 
\nabla_{\mu} ( \nabla_{\alpha} n_{\nu}) + n^{\alpha} \nabla_{\mu} ( 
\nabla_{\alpha} n_{\nu}) + \nabla_{\alpha} n_{\nu} \nabla_{\mu} n^{\alpha} + 
\nabla_{\mu} n_{\alpha} \nabla_{\nu} n^{\alpha} 
\end{align*}
\end{document}

These gives the following result enter image description here

How do I make it appropriate? Also I want to label the second equation as number 1 but not the first line. How to do that?

2 Answers 2

5

In align you use &=, not &=& like in eqnarray. For the numbering, change align* to align and add \nonumber to the end of the first line.

enter image description here

\documentclass[12pt,letterpaper]{article}
\usepackage[a4paper,left=20mm,top=25mm,right=20mm,bottom=25mm]{geometry}
\usepackage[utf8]{inputenc}
\usepackage{amsmath}
\begin{document}
Asymptotic equation of Motion
\begin{align}
\mathcal{L}_n (\nabla_{\mu} n_{\nu}) &= n^{\alpha} \nabla_{\alpha} ( 
\nabla_{\mu} n_{\nu}) + \nabla_{\alpha} n_{\nu} \nabla_{\mu} n^{\alpha} + 
\nabla_{\mu} n_{\alpha} \nabla_{\nu} n^{\alpha} \nonumber \\ % <----  add \nonumber here
&= n^{\alpha} \nabla_{\alpha} ( \nabla_{\mu} n_{\nu}) - n^{\alpha} 
\nabla_{\mu} ( \nabla_{\alpha} n_{\nu}) + n^{\alpha} \nabla_{\mu} ( 
\nabla_{\alpha} n_{\nu}) + \nabla_{\alpha} n_{\nu} \nabla_{\mu} n^{\alpha} + 
\nabla_{\mu} n_{\alpha} \nabla_{\nu} n^{\alpha} 
\end{align}
\end{document}
1
5

For a single equation, the choice should be split inside equation:

\documentclass[12pt]{article}
\usepackage[a4paper,left=20mm,top=25mm,right=20mm,bottom=25mm]{geometry}
\usepackage[utf8]{inputenc}
\usepackage{amsmath}

\begin{document}

Asymptotic equation of Motion
\begin{equation}
\begin{split}
\mathcal{L}_n (\nabla_{\mu} n_{\nu}) 
&= n^{\alpha} \nabla_{\alpha} ( \nabla_{\mu} n_{\nu}) 
   + \nabla_{\alpha} n_{\nu} \nabla_{\mu} n^{\alpha}   
   + \nabla_{\mu} n_{\alpha} \nabla_{\nu} n^{\alpha}
\\
&= n^{\alpha} \nabla_{\alpha} ( \nabla_{\mu} n_{\nu}) 
   - n^{\alpha} \nabla_{\mu} ( \nabla_{\alpha} n_{\nu}) 
   + n^{\alpha} \nabla_{\mu} ( \nabla_{\alpha} n_{\nu}) 
   + \nabla_{\alpha} n_{\nu} \nabla_{\mu} n^{\alpha}  
   + \nabla_{\mu} n_{\alpha} \nabla_{\nu} n^{\alpha}
\end{split}
\end{equation}

\end{document}

enter image description here

If you prefer the number to be at the bottom, this should be a global decision, that can be accomplished by calling amsmath with the tbtags option:

\usepackage[tbtags]{amsmath}

With this single change, the output would become

enter image description here

Note that amsmath alignment environments use &= (not &=&). I removed the letterpaper option, that does nothing and might be a bit unclear.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .