0

I would love to be able to represent a network of reactions in a square like so (pardon the scribbling)

enter image description here

note: I don't care about the squares around the nodes of the reaction, I can live without those.

I've been doing my reactions using mhchem, and I found this answer showing how to display a network of chemical reactions using chemfig. However, I need the arrows in the reactions to show the reatcion rates, like in the picture above, and I couldn't find how to do that with chemfig, nor with mhchem.

2 Answers 2

2

Here is a tikz-cd option:

enter image description here

\documentclass{article}

\usepackage{tikz-cd}

\begin{document}

\begin{tikzcd}[row sep=1.5cm, column sep=1.5cm, cells={nodes={draw, outer sep=3mm, minimum height=8mm}}]
P_{00}\arrow[r, harpoon, shift left, "k_{H^+}"]\arrow[d, harpoon', shift right, "k_{S^+}"']
    & |[red, text=black]|P_{10}\arrow[l, harpoon, shift left, "k_{H^-}"]\arrow[d, harpoon, shift left, "k_{HS^+}"]\\
P_{01}\arrow[r, harpoon', shift right, "k_{SH^+}"']\arrow[u, harpoon', shift right, "k_{S^-}"']
    & |[red, dashed, text=black]|P_{11}\arrow[l, harpoon', shift right, "k_{SH^-}"']\arrow[u, harpoon, shift left, "k_{HS^-}"]
\end{tikzcd}

\end{document}
2
  • Thanks for that demonstration of tikz-cd. I just wondered if you can raise the + and - in the subscripts a bit more. Making them a bit smaller could be achieved by {\small +}, but raising that?
    – alchemist
    Feb 7 at 22:16
  • Yes. There are several ways to do this. For example, see here or here
    – Sandy G
    Feb 7 at 23:03
4

Using only chemfig

\documentclass[border=2mm]{standalone}
\usepackage{chemfig}
\usepackage{amsmath}
\begin{document}
    \schemestart
    \chemfig{@{a}P_{00}} \arrow{<=>[$R_{H+}$][$R_{H-}$]}[0,1.5] \chemfig{@{b}P_{10}}
    \arrow(@{a}--){<=>[$K_{S+}$][$K_{S-}$]}[270,1.5] \chemfig{P_{01}} \arrow{<=>[$K_{SH+}$][$K_{SH-}$]}[0,1.5] \chemfig{P_{11}}
    \arrow(@{b}--){<=>[$R_{HS+}$][$R_{HS-}$]}[270,1.5]
    \schemestop
\end{document}

enter image description here

Or, using the command \tiny

\documentclass[border=2mm]{standalone}
\usepackage{chemfig}
\usepackage{amsmath}
\begin{document}
    \schemestart
    \chemfig{@{a}P_{00}} \arrow{<=>[{\tiny $R_{H+}$}][{\tiny$R_{H-}$}]}[0,1.5] \chemfig{@{b}P_{10}}
    \arrow(@{a}--){<=>[*0{\tiny$K_{S+}$}][*0{\tiny$K_{S-}$}]}[270,1.5] \chemfig{P_{01}} \arrow{<=>[{\tiny$K_{SH+}$}][{\tiny$K_{SH-}$}]}[0,1.5] \chemfig{P_{11}}
    \arrow(@{b}--){<=>[*0{\tiny$R_{HS+}$}][*0{\tiny$R_{HS-}$}]}[270,1.5]
    \schemestop
\end{document}

enter image description here

3
  • I didn't know this was possible, didn't see it in the docu. In any case, I prefer the labels on the vertical arrows being horizontal, but this is nice.
    – Puff
    Feb 9 at 15:55
  • 1
    @puff -- is possible put all text in horizontal
    – CrocoDuck
    Feb 9 at 16:24
  • Man the docu is so incomplete
    – Puff
    Feb 10 at 14:51

You must log in to answer this question.

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