# multiple equations in a single line, numbering problem

I have two relatively short equations which I want to fit in one line. Using the multicols and miniage I am getting :

equation1, (1) equation2. (2)

The numbers are on the right side of each equations but I want something like that:

equation1, equation2 (1),(2)

Where the both numbers are together on the far right. I've just spent the last hour looking for the answer and still no idea.

• Wouldn't that be confusing? Apr 28, 2014 at 2:48
• It's a strange usage. Apr 28, 2014 at 2:49
• Welcome to TeX.SX! Please help us to help you and add a minimal working example (MWE) that illustrates your problem. It will be much easier for us to reproduce your situation and find out what the issue is when we see compilable code, starting with \documentclass{...} and ending with \end{document}. Apr 28, 2014 at 2:58
• Are you using hyperref? What about this?
– Werner
Apr 28, 2014 at 3:21
• Related/duplicate: Two equation numbers within one set of brackets
– Werner
Apr 28, 2014 at 5:17

This is about as simple as it gets. The rule is used to provide context. Also, for some reason it doesn't like \stepcounter{equation}, so I had to do it old school.

\documentclass{article}
\usepackage{mathtools}

\makeatletter
\makeatother

\begin{document}
\noindent\rule{\textwidth}{1pt}
\renewcommand{\theequation}{\arabic{equation}\stepeq{),(}\arabic{equation}}
\begin{align}
x&=a & y&=b
\end{align}
\renewcommand{\theequation}{\arabic{equation}}
$$z=c$$

\end{document}


• This doesn't really work, since references don't function as expected.
– Werner
Apr 28, 2014 at 23:30
• Even using \tag, you can't create separate references for the two equations using \label and \ref. But it's not like we were encouraging this sort of thing. Apr 29, 2014 at 13:14