# Alignment of chemical equations

I would like to align some chemical reactions in my document. This is an example of what I did:

$$\nuclide[14][7]{N} + n \to \nuclide[14][6]{C} + p$$

<Some text>

\begin{align*}
&\nuclide[14][7]{N} + n \to \nuclide[11][5]{B} + \nuclide[4][2]{H}\\%
&\nuclide[14][7]{N} + n \to \nuclide[12][6]{C} + \nuclide[3][1]{H}\\%

\end{align*}


I would like to align the first equation with the next two. How can I do?

-
Have you tried one of amsmath’s environments, say align? – Qrrbrbirlbel Jan 3 '13 at 15:31
@FordPrefect: What was the sense of your change to Torbjorn’s edit in tex.stackexchange.com/revisions/89108/10? The way he made the indentation is exactly, how the syntax highlighting/markup system called Markdown expects it for showing code blocks. With your edit there came additional (useless) indentation. – Speravir Jan 3 '13 at 21:43
Re your edit: How long is <Some text>? For short text, use \intertext{<some text>} (or \shortintertext from mathtools) inside (!) one (!) align environment (or its kind). For long text (which indicates your paragraphs = empty lines in source) I’d advise against it. Though you could do it by some trickery with \hphantom and \mathllap (mathtools required). [cont …] – Qrrbrbirlbel Jan 3 '13 at 22:15
[… cont] Can you extend your question: what should aligned to what? Maybe you are more interested in the fleqn option (see amsmath manual, p. 3). – Qrrbrbirlbel Jan 3 '13 at 22:17

Wouldn't it be easier to use a chemistry package like mhchem (together with the already proposed amsmath) instead of tensor? mhchem's \cee macro is defined especially for use in alignment environments like {align}. For text between aligned equations one can use amsmath's \intertext{}.

\documentclass{book}
\usepackage[version=3]{mhchem}
\usepackage{amsmath}

\begin{document}
\begin{align*}
\cee{
^{14}_7N + n &-> ^{11}_5B  + ^4_2H \\
}
\intertext{Some text in between that is not aligned or anything.}
\cee{
^{14}_7N + n &-> ^{12}_6C  + ^3_1H \\
^{16}_8O + n &-> ^{10}_4Be + ^7_4Be
}
\end{align*}

\end{document}


Edit: In order to get the first equation numbered but not the second and third you have basically two options:

1. Use {align} (without the star!) and suppress the numbers of the second and third equation via \notag or \nonumber.
2. Use {align*} and add the number for the first manually by saying \tag{\refstepcounter{equation}\theequation}

Personally I prefer the first variant. BTW: if you haven't read it yet you might want to have a look at “Math Mode” by Herbert Voß.

\documentclass{book}
\usepackage[version=3]{mhchem}
\usepackage{amsmath}

\begin{document}

\begin{align}
\cee{
^{14}_7N + n &-> ^{11}_5B  + ^4_2H \\
}
\intertext{Some text in between that is not aligned or anything.}
\cee{
^{14}_7N + n &-> ^{12}_6C  + ^3_1H \nonumber \\
^{16}_8O + n &-> ^{10}_4Be + ^7_4Be \notag
}
\end{align}

\begin{align*}
\cee{
^{14}_7N + n &-> ^{11}_5B  + ^4_2H \tag{\refstepcounter{equation}\theequation}\\
}
\intertext{Some text in between that is not aligned or anything.}
\cee{
^{14}_7N + n &-> ^{12}_6C  + ^3_1H \\
^{16}_8O + n &-> ^{10}_4Be + ^7_4Be
}
\end{align*}

\end{document}


-
Thank you, but how if I wanna number the first equation? – Ford Prefect Jan 5 '13 at 10:02
@FordPrefect see my edited answer – clemens Jan 5 '13 at 12:32
Thank you very much! I learned a lot. – Ford Prefect Jan 6 '13 at 12:35

Try the align* environment, provided by amsmath package. To change the position of the aligment, change the & symbol.

\documentclass{book}
\usepackage{tensor}
\usepackage{amsmath}

\begin{document}
\begin{align*}
&\nuclide[14][7]{N} + n \to \nuclide[11][5]{B}  + \nuclide[4][2]{H}\\
&\nuclide[14][7]{N} + n \to \nuclide[12][6]{C}  + \nuclide[3][1]{H}\\
&\nuclide[16][8]{O} + n \to \nuclide[10][4]{Be} + \nuclide[7][4]{Be}
\end{align*}
\end{document}

-
The environment align works very well. But how do I do if between equations I have some text (that I would like rest "normal")? – Ford Prefect Jan 3 '13 at 17:06
@FordPrefect try \intertext{<text>}. Have you read Math Mode, yet? – clemens Jan 3 '13 at 17:26
@FordPrefect, text between equations should be written on a normal line? Or centered? Please, exemplify it. – Sigur Jan 3 '13 at 17:52
@Sigur I edited my question. Sorry for the bad explanations... – Ford Prefect Jan 3 '13 at 21:43