# How to make subequations

I need equation (1) followed by equation (1.a), (1.b), etc. But I am getting equation (1), then (2.a) (2.b), etc.

\documentclass{llncs}
\usepackage{amsmath}
\usepackage{placeins}

\begin{document}
$$Result = X + \sum\limits_{i=0}^{n}Y$$

\begin{subequations}
\begin{align}
X &= ab \\    Y &= cd
\end{align}
\end{subequations}
\end{document}

• @Mico it worked. Why not adding this as answer? – user6875880 Apr 3 '17 at 17:18
• Because the method in egreg's answer is far more general. \addtocounter{equation}{-1} is quite hackish in comparison. – Mico Apr 3 '17 at 17:22

You can use \ref:

\documentclass{article}
\usepackage{amsmath}

\begin{document}

\begin{subequations}\label{whatever}
\begin{gather}\tag{\ref{whatever}}
\mathrm{Result} = X + \sum\limits_{i=0}^{n}Y
\\
\begin{align}
X &= ab \\    Y &= cd
\end{align}
\end{gather}
\end{subequations}

\end{document}


Note how you can get the right vertical spacing instead of using equation and align with align nested in gather.

It's the same with llncs.