2

I read many related questions but could not find the solution for this (apparently simple) problem on which I spent too much time. Starting from the code used Radical ions with chemfig I tried to draw different kind of radicals/ions with the following code;

\documentclass{beamer}
  \usetheme{Warsaw}
\usepackage{chemfig}
\usepackage[version=3]{mhchem}
\setdoublesep{0.35700 em}  % 'Bond Spacing'
\setatomsep{1.78500 em}    % 'Fixed Length'
\setbondoffset{0.18265 em} % 'Margin Width'
\newcommand{\bondwidth}{0.06642 em} % 'Line Width'
\setbondstyle{line width = \bondwidth}
\newcommand*\radcationleft{\chemabove[0pt]{\lewis{4.,\rule[8pt]{0pt}{0pt}}}{\vspace{0pt} \tiny+ \hspace{2pt}}} %
\newcommand*\radcationright{\chemabove[0pt]{\lewis{0.,\rule[10pt]{0pt}{0pt}}}{\vspace{0pt} \tiny+ \hspace{-2pt}}} % \hspace{-5pt}
\newcommand*\radicabove{\chemabove[0pt]{}{\hspace{5pt}\large\lewis{2., \rule[0pt]{0pt}{5pt}}}} % OK
\newcommand*\radicright{\chemabove[0pt]{}{\hspace{1pt}\large\lewis{0.,\rule[3pt]{0pt}{1pt}}}} % OK
\newcommand*\radicleft{\chemabove[2pt]{}{\large\lewis{4.,\rule[0pt]{0pt}{0pt}}}} % OK
\begin{document}
\begin{frame}
\tiny 
\chemfig{HO-[,,,2]\radcationleft C(-[6,,2]H)-C(-[2]H)(-[6]H)-OH} %

\chemfig{HO-[,,,1]C\radcationright(-[6,,1]H)-[,,1]C(-[2]H)(-[6]H)-OH} % 

\chemfig{HO-\radicabove C(-[6,,2]H)-C(-[2]H)(-[6]H)-OH} %

\chemfig{HO-C\radicright(-[2,,1]OOH)(-[6]H)} %

\chemfig{\radicleft C(-[2,,2,]OO)(-[6,,2]OH)-H} %
\end{frame}
\end{document}

and got this:

Beamer slide 1

While reasonably satisfied by the radicals, I am not happy with the radical cations and especially with the second one \radicationright which I could not properly derive from the \radicationleft of the afore mentioned post.

I got an other question, closely related, while:

\chemfig{\radicleft C(-[2,,2,]OO)(-[6,,2]OH)-H}

works fine, if I try to substitute OO by O_2:

\chemfig{\radicleft C(-[2,,2,]OO)(-[6,,2]OH)-H}

I cannot align the vertical C-O bond with the O atom as can be seen here:

Beamer slide 2

1 Answer 1

1

Here's how I would input the formulas:

\documentclass{article}
\usepackage{chemfig}
\setdoublesep{0.35700 em}  % 'Bond Spacing'
\setatomsep{1.78500 em}    % 'Fixed Length'
\setbondoffset{0.18265 em} % 'Margin Width'
\newcommand{\bondwidth}{0.06642 em} % 'Line Width'
\setbondstyle{line width = \bondwidth}

\begin{document}

\chemfig{HO-\lewis{3.,\chemabove{C}{\scriptstyle+}}(-[6]H)-C(-[2]H)(-[6]H)-OH}

\bigskip

\chemfig{HO-\lewis{1.,\chemabove{C}{\scriptstyle+}}(-[6]H)-C(-[2]H)(-[6]H)-OH} 

\bigskip

\chemfig{HO-\lewis{2.,C}(-[6]H)-C(-[2]H)(-[6]H)-OH}

\bigskip

\chemfig{HO-\lewis{0.,C}(-[2]OOH)(-[6]H)}

\bigskip

\chemfig{\lewis{4.,C}(-[2]O|_2)(-[6]OH)-H}

\end{document}

enter image description here

You must log in to answer this question.

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