0

I tried to connect 2 aromatic compunds (one is a submolecule). My problem is that LaTex does not connect them at the right atom. I want to connect 4 with B. I know how to set the optional bond argument in simple molecules but fail in this examples. I always tells me that the atom does not exist. So my question is where to I have to put the optional bond argument in aromatic molecules like in Example 1 so that it connects 4 with B and is it possible to connect 4 and B in Example 2 and automatically remove the H atom?

Thanks! Roland

\documentclass{article}

\usepackage{subcaption,graphicx}
\usepackage{chemfig}
%\usepackage[showframe]{geometry}

\begin{document}


%%%%%Example 1
\definesubmol{Y}{*6(A-B-C-D-E-F-)}

\chemfig{*6(1-2-3-4(-!{Y})-5-6-)}

%\chemfig{ABCD-[:90,,3,2]EFG}


%%%%%%Example 2
\definesubmol{Y2}{*6(A-\chembelow{B}{H}-C-D-E-F-)}

\chemfig{*6(1-2-3-4(-!{Y2})-5-6-)}

\end{document}

enter image description here

EDIT: The actual molecules I want to combine. So I want to connect it to the N molecule

 \documentclass{article}

\usepackage{subcaption,graphicx}
\usepackage{chemfig}
\usepackage{lipsum}
\newcommand{\decoRule}{\rule{\textwidth}{0.4pt}}
%\usepackage[showframe]{geometry}

\begin{document}


\definesubmol{Cbase}{*6(-\chembelow{N}{H}-(=O)-N=(-NH_2)-=)}

\definesubmol{a}{-P(=[::-90,0.75]O)(-[::90,0.75]OH)-}

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%in RNA
\definesubmol{CRbase}{*6(-N-(=O)-N=(-NH_2)-=)}

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

\begin{figure}
  \centering

    \chemfig{!{Cbase}}
    
    \chemfig{[:-54]*5((--[::42]O([::-24]!a\charge{135:3pt=$\scriptstyle\ominus$}{O}))<(-HO)-[,,,,line width=2pt](-OH)>(-!{CRbase})-O-)}
  
\end{figure}

\end{document}

[![enter image description here][2]][2]

It should alos be oiriented like that:

\definesubmol{Cbase}{*6(-\chembelow{N}{H}-(=O)-N=(-NH_2)-=)}
\chemfig{!{Cbase}}

[![enter image description here][3]][3]

In the End it should look like this:

enter image description here

1 Answer 1

1

If I understand this right ...

\documentclass{article}
\usepackage{chemfig}

\begin{document}

\definesubmol{Y}{B*6(-C-D-E-F-A-)}

\chemfig{1*6(-2-3-4(-!{Y})-5-6-)}

\end{document}

enter image description here

1
  • Hello and thanks for the effor. I edited my question to make it more clear. As far as I see you just changed the proberties of the submol molecule. I wanted to show the molecule in a figure and it is also a part of a larger molecule (RNA). So I wanted to use the submolecule and just add it to the sugar phosphate backbone.
    – Roland
    Commented Nov 18, 2020 at 10:05

You must log in to answer this question.

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