Re: mhchem ed align

#62310
Up
0
Down
::


Ciao a tutti, volevo riproporre il mio problema:
creare un ambiente reactions in cui sia possibile inserire equazioni chimiche allineate e tabulate con gli strumenti del pacchetto mhchem.
Tale pacchetto suggerisce di creare un comando per reazioni singole del tipo:
`
\makeatletter
\newcounter{reaction}
%%% >> for article << %\renewcommand\thereaction{C\,\arabic{reaction}} %%% << for article << %%% >> for report and book >>
\renewcommand\thereaction{C\,\thechapter.\arabic{reaction}}
\@addtoreset{reaction}{chapter}
%%% << for report and book << \newcommand\reactiontag{\refstepcounter{reaction}\tag{\thereaction}} \newcommand\reaction@[2][]{\begin{equation}\ce{#2}% \ifx\@empty#1\@empty\else\label{#1}\fi% \reactiontag\end{equation}} \newcommand\reaction@nonumber[1]{\begin{equation*}\ce{#1}% \end{equation*}} \newcommand\reaction{\@ifstar{\reaction@nonumber}{\reaction@}} \makeatother ` Io vorrei inserire il comando reaction all’interno dell’ambiente matematico aligned, di modo da ottenere reazioni correttamente distanziate ed allineate e numerate in modo coerente con le reazioni singole presenti nel testo.

Il risultato dovrebbe essere qualcosa del tipo
`\newenvironment{reazioni}{\begin{aligned}\reaction}{\end{aligned}}`
che ovviamente non funziona in quanto \reaction è un comando.
Ancora grazie

Go to top