5
$\begingroup$

After finding out that the mhchem plugin for MathJaX doesn't support structural formulas (here), I decided to post this question. I would like to know what kind of solutions there are for writing these kinds formulas. It could be done in Photoshop or some other graphics design program, but that could get complicating or take some time. Is there any software commonly used for this? Maybe there's some online solutions?

$\endgroup$
  • $\begingroup$ I think our best bet would be to support this answer and revisit it with the SE team. Thanks for bringing this up again! $\endgroup$ – jonsca Aug 30 '13 at 22:59
4
$\begingroup$

I've used the chemfig LATEX package to do this in the past, which we might be able to use via Mathjax. It's not the easiest to use thing in the world, especially if you're making cyclic structures, but it seems to work.

You get something like this:

\chemfig{-[:210]N=[:150]N-[:90]=[:30]-[:330]N=[:270]-[:330](-[:30]N=[:330])=[:270]-[:330]=[:30]-[:90]-[:30](=[:330]N-[:30])-[:90]=[:30]-[:330]=[:270]-[:330]=[:270]N-[:330]=[:30]-[:90]N=[:150]N-[:210]}

And it renders this:

BTBP

Or:

\chemfig{H_{17}C_{8}-[:300]N(-[:240]{H_{17}C_8})-(=[:300]O)-[:60]-[:330]O-[:30]-[:300](=[:240]O)-N(-[:60]C_8H_{17})-[:300]C_8H_{17}}

Gets you:

TODGA

... Looking at these again, I think the syntax might be a bit too weird to be commonly usable, but it's an option, at least.

$\endgroup$
  • $\begingroup$ Had a talk to one of the guys who does MathJax via the github- basically if we want to use Chemfig we need to write a plugin ourselves (then get SE to authorise it). Current idea is to make a userscript to add a button that lets you use ChemDoodle instead? $\endgroup$ – Tomcat Sep 1 '13 at 12:15
  • $\begingroup$ @Snipergirl: I'm not so sure a solution that requires installing stuff into your browser is a good way to go. Is there any way to add it server-side? $\endgroup$ – Aesin Sep 1 '13 at 16:20
  • 1
    $\begingroup$ I think ManishEarth is going to talk to the SE guys at some point about that. Apparently Elec Eng among other places has some built in circuit diagram stuff for example? ChemDoodle can be embedded into a site but one question is about licencing $\endgroup$ – Tomcat Sep 1 '13 at 16:27
  • $\begingroup$ JME and MarvinSketch are other alternatives to Chemdoodle. JME would likely be free. Marvin is free for educational use - not sure if this counts. See also: en.wikipedia.org/wiki/Molecule_editor#Applets $\endgroup$ – Ben Norris Sep 21 '13 at 18:58

You must log in to answer this question.

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