It would be nice if you could help me to draw NO2 in LaTeX. The figure should look like the example image.
On this website is some information about the chemfig/chemmakro package. My code untill now shows a NO2 molecule. Now I just need to add the arrows and nodes (red areas on the original image). How to do that? First of all I will thank @Sigur (he let the chemfig code work) and @ajeh who corrected my angles. And I will thank the German Texwelt (German LaTeX help forum). On that website a user named "Clemens" helped (20 Jul, 05:27) the user "goldsonne23" with the delocated bondings on this website. So all the Tikz part is just "stolen" from Clemns. Here the code:
\documentclass[a4paper, 12pt, twocolumn]{article}
\usepackage[utf8]{inputenc}
\usepackage{libertine}
\usepackage{chemfig, chemmacros}
\usetikzlibrary{decorations}
%delocated bondings
\pgfdeclaredecoration{ddbond}{initial}{
\state{initial}[width=4pt]{
\pgfpathlineto{\pgfpoint{4pt}{0pt}}
\pgfpathmoveto{\pgfpoint{2pt}{2pt}}
\pgfpathlineto{\pgfpoint{4pt}{2pt}}
\pgfpathmoveto{\pgfpoint{4pt}{0pt}}
}
\state{final}{\pgfpathlineto{\pgfpointdecoratedpathlast}}
}
\tikzset{
lddbond/.style={decorate,decoration=ddbond},
rddbond/.style={decorate,decoration={ddbond,mirror}},
elmove/.style={->,red,shorten >=3pt, shorten <=3pt}
}
\begin{document}
%\chemfig{<atom1><bond type>[<angle>,<coeff>,<tikz code>]<atom2>}
\chemfig{O-[:22.85,,,,rddbond]N-[:-22.85,,,,rddbond]O}
\end{document}
Anyone who can help? Yours faithfully, Basilius
:
for specified angles. Also, removingdraw
works very well:\chemfig{O=[:67.15,1]N=[:-67.15, 1]O}
starting package maintenance... installation directory: "d:\Program Files (x86)\MiKTeX 2.9" package repository: ftp://ctan.mirror.rafal.ca/pub/CTAN/systems/win32/miktex/tm/packages/ lightweight database digest: 759477432c5e6ba0426dad097cdc7af3 pdflatex.EXE: Unknown archive file size. pdflatex.EXE: Data: mh ! LaTeX Error: File 'mathtools.sty' not found. Type X to quit or <RETURN> to proceed, or enter new name. (Default extension: sty) Enter file name: