为了确定分子的路易斯结构,我使用了提出的方法这里但我对某些分子如氧气有阻断作用:
如何在每个原子上放置双键和双线?
\documentclass{standalone}
\usepackage{stackengine}
\usepackage{graphicx,ifthen}
\newcommand\lewis[7]{\,%
\ifthenelse{\equal{#3}{}}%
{\def\RHS{}\def\RRHS{\hspace{.5ex}}}%
{\def\RHS{\,\rotatebox{90}{\makebox[1.5ex]{#3}}\,}\def\RRHS{}}%
\stackengine{2ex}{%
\rotatebox{90}{\makebox[1.5ex]{#5}}\,%
\stackengine{0.6ex}{%
\stackengine{1.9ex}{#1}{#2}{O}{c}{F}{F}{L}%
}{#4}{U}{c}{F}{F}{L}%
\RHS$^{#6}$\RRHS%
}{$#7$}{U}{c}{F}{F}{L}%
}
\savestack\Bond{\rule{1.2ex}{0.75pt}}
\savestack{\PBond}{\rotatebox{90}{\Bond}}
\begin{document}
\sffamily
\stackunder{%
O\lewis{O}{}{\Bond}{}{\PBond}{}{}
}{}
\end{document}