4

I have a display problem on an equation: one of the molecules appears on the equal sign but I don't understand why (I regularly use this package, and this is the first time this has happened to me)

reaction

\documentclass{article}
\usepackage{graphicx} % Required for inserting images
\usepackage[modules={all}]{chemmacros}%le module orbital a été commenté (lignes 3816 à 3824
\usepackage{siunitx}

\begin{document}


\begin{reaction*}
Ag\pch{}\aq{} + 2 NH3\aq{} == [Ag(NH3)2]\pch{}\aq{}
\end{reaction*}

\begin{reaction*}
[Ag(NH3)2]\pch{} + e\mch{} == Ag\sld{} + 2 NH3 \aq{}
\end{reaction*}

\end{document}

1 Answer 1

6

chemmacros looks for an optional argument to 'arrows' (which here includes ==). As you have a complex ion in square brackets, it looks like an optional argument. You need to stop the look-ahead:

Ag\pch{}\aq{} + 2 NH3\aq{} =={} [Ag(NH3)2]\pch{}\aq{}

You must log in to answer this question.

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