0

As the question described, how to implement the picture below in LaTeX ? Which package should I use?

enter image description here

xiuer
  • 1

3 Answers3

2

With less arbitrary alignments:

\documentclass{article}
\usepackage{amsmath}
\usepackage{chemformula}

\begin{document}

\begin{align} & \ch{PuF6} + 2\ch{PuF3} = 3\ch{PuF4} \quad\ \quad-\quad \notag \ & \ch{F2} + 2\ch{PuF3} = 2\ch{PuF4} \[-1.2ex] \cline{1-2} & \ch{PuF6} = \ch{PuF4} + \ch{F2} \end{align}

\end{document}

enter image description here

egreg
  • 1,121,712
1

Another solution with an alignat environment, chemformula and a \cmidrule:

\documentclass{article}
\usepackage{mathtools}
\usepackage{booktabs}
\usepackage{chemformula}

\usepackage{lipsum}

\begin{document}

{ \bfseries\boldmath\setlength{\aboverulesep}{-1.2ex}\setlength{\belowrulesep}{-0.5ex} \begin{alignat}{2} &\phantom{{}-{}} &\quad \ch{PuF6} + 2\ch{PuF3} & = 3\ch{PuF4} \ \notag &{}- {}& & \ & & \ch{F2} + 2\ch{PuF3} & = 2\ch{PuF4} \ \cmidrule\heavyrulewidth{1-4} & &\ch{PuF6} & = \ch{PuF4} + \ch{F2} \end{alignat} } \end{document}

enter image description here

Bernard
  • 271,350
0

Something like this:

\documentclass{article}
\usepackage{mathtools}
\usepackage{booktabs, tabularx}
\usepackage[version=4]{mhchem}

\usepackage{lipsum}

\begin{document} \begin{tabularx}{\linewidth}{X} \begin{gather} \ce{PuF6} + \ce{2PuF3} = 3\ce{Pu} \ \mathllap{-}
\ce{PuF6} + \ce{2PuF3} = 3\ce{Pu} \end{gather} \[-5ex] \cmidrule1pt{1-1} \[-8ex] \begin{gather} \ce{PuF6} + \ce{2PuF3} = 3\ce{Pu} \end{gather} \end{tabularx}

\lipsum[1][1-3] \end{document}

enter image description here

Zarko
  • 296,517