This has been sleeping for quite a while. Some new features here, some polishing there, correcting bugs, completely forgetting about if after I didn’t need it anymore… Well, here it is: ENdiagram. The package for the creation of potential energy curves. Another chemistry niche filled with a package. Before I tell you just a little bit what it does let’s see some pictures: This picture was created using the following lines: [cce lang=”latex”]% arara: pdflatex \documentclass{scrartcl} \usepackage{endiagram} \begin{document} \begin{endiagram} \ENcurve{1,4,0} \end{endiagram} \end{document}[/cce] Actually I won’t tell you much. I’ll let the pictures speak for themselves, in addition to the source code. So here we go: a few words, a picture, code, a few words, a picture, code, a few words… You can visualize energy gain or loss by simply adding one command: [cce lang=”latex”]% arara: pdflatex \documentclass{scrartcl} \usepackage{endiagram} \begin{document} \begin{endiagram} \ENcurve{3,4,0} \ShowGain[label] \end{endiagram} \end{document}[/cce] You can also visualize the activation energy by using a similar command: [cce lang=”latex”]% arara: pdflatex \documentclass{scrartcl} \usepackage{endiagram} \begin{document} \begin{endiagram} \ENcurve{1,5,2.5,4,0} \ShowEa[from={(0,1) to (6,4)}] \end{endiagram} \end{document}[/cce] It’s not limited to one curve… you can insert as many as you like (and also use colors): [cce lang=”latex”]% arara: pdflatex \documentclass{scrartcl} \usepackage{endiagram} \begin{document} \begin{endiagram} \ENcurve[tikz=blue]{1,4,0} \ENcurve[tikz=red]{1,2.5,0} \ShowEa[tikz={red,<->}] \end{endiagram} \end{document}[/cce] The curves can have a different numbers of maxima, a different line style, shifted maxima, … [cce lang=”latex”]% arara: pdflatex \documentclass{scrartcl} \usepackage{endiagram} \begin{document} \begin{endiagram} \ENcurve[step=4]{1,6,0} \ENcurve[tikz={densely dotted}] {1,4[1],2.5,3[-1],0} \end{endiagram} \end{document}[/cce] Now let’s add some numbers. The packages allows to add a scale to the y-axis and calculate energy gain/loss automatically: [cce lang=”latex”]% arara: pdflatex \documentclass{scrartcl} \usepackage{endiagram} \DeclareSIUnit{\calory}{cal} \begin{document} \sisetup{per-mode = fraction} \ENsetup{ energy-step = 100, energy-unit = \kilo\calory\per\mole, energy-unit-separator = { in }, y-label = above, AddAxisLabel/font = \footnotesize } \begin{endiagram}[scale=1.5] \ENcurve{2.232,4.174,.308} \AddAxisLabel*{0;1;2;3;4} \ShowEa[label,connect={draw=none}] \ShowGain[label] \end{endiagram} \end{document}[/cce] Intrigued? I need feedback if I want to improve the package and before I’ll upload it to CTAN. So if you find the package useful for your needs you can get it here. Many parts of the package may still be very buggy and are at least experimental. Also you may expect difficulties and an update as soon TeX Live 2012 is officially released and the l3kernel packages are updated. ENdiagram is available from CTAN and also part of MiKTeX and TeX Live 2012.

9 thoughts on “ENdiagram — Potential Energy Curves

  1. Wow: I’ll be using this! Perfect timing as I start as a lecturer in September 🙂

    1. cgnieder says:

      I’m glad if it’s useful. I’m pretty sure it must be buggy, though! Please let me know any problems you encounter.

  2. Philippe says:


    Thanks for the package. I have one request : could the package allow the user to choose himself the X and Y coordinates (I would like to name them différently as [cci_latex]$\xi$[/cci_latex] or [cci_latex]$E$[/cci_latex].


    1. Philippe says:

      I should have read the user-manuel before my post !!!!!!! Sorry for the noise.

  3. Steven says:

    Wow! I just found this package yesterday and I am already impressed. I have been asking everyone in my lab how to make these types of figures for my reaction rates I am calculating via DFT studies… but no one could help. This project is a life saver… Please, please do not let this go dormant.

    1. cgnieder says:

      I’m glad if the package proofs useful. Let me know if you find any bugs. Just curious: if you have calculated data wouldn’t pgfplots be a suitable choice? ENdiagram is only capable of qualitative diagrams (even if it has some support for a quantitative energy scale).

      1. steven says:

        I have never heard of that one…. I will have to look into that as well.
        I am new to LaTex.

  4. Guntram says:

    Nice one!!!

    Would it be possible to implement a display mode, where the connection of the energy levels is done without the curvature but a straight (dotted) line (more like you did in your MO-package) ?
    This would be more abstract – the current drawing implicits knowledge of the path between the reactants, which can most times be doubted ;-).

    1. cgnieder says:

      I not sure I understand what you mean. Something like this maybe:

      [cce lang=”latex”]\documentclass{article}





Leave a Reply

Your email address will not be published. Required fields are marked *