2

When writing reaction mechanism in chemfig with subscheme there are wide vertical gaps between the two compounds as seen in the figure attached. enter image description here

How can I achieve the desired position shown in the fig. Attempt so far

documentclass{book}
\usepackage[version=4,arrows=pgf-filled]{mhchem}
\usepackage{chemfig,chemmacros}
\setatomsep{1.5em}
\setbondoffset{0pt}
\begin{document}
\schemestart
\subscheme[-90]{
\chemfig{CH_3CH=[@{d}]CH_2}
\arrow{0[][][-10pt]}
\chemfig{@{e}Br-[@{f}]@{g}Br}
}
\ce{->}
\chemfig{CH_3\chemabove{C}{\scrp}HCH_2Br} \+ \chemfig{Br^{-}} 
\schemestop
\chemmove[cyan,>=latex,shorten <=2pt,shorten >=2pt]{ 
\draw[shorten >=1pt,->] (d) ..controls +(-90:1cm) and +(135:1cm) .. (e) ;} 
\chemmove[red,>=latex,shorten <=1pt,shorten >=2pt]{ 
\draw[shorten >=0pt,->] (f) ..controls +(-90:.5cm) and +(-90:1cm) .. (g) 
;}
\end{document}

2 Answers 2

3

Adjusting the dimensions of the invisible arrow between the propylene and the bromine should get you closer to the ecpected output.

I also replaced the deprecated

\setatomsep{1.5em}
\setbondoffset{0pt}

commands with

\setchemfig{atom sep=1.5em,
            bond offset=0pt}

to make the code compilable with chemfig versions newer than 1.3 (from march 2018).

Lastly, I included an alternative layout for the reaction, as reagents are usually drawn next to the reactant(s) or above the reaction arrow, instead of somewhere below the reactant.

enter image description here

\documentclass{book}
\usepackage[version=4,arrows=pgf-filled]{mhchem}
\usepackage{chemfig,chemmacros}

\setchemfig{atom sep=1.5em,
            bond offset=0pt}
\begin{document}
\schemestart
\subscheme[-90]{
\chemfig{CH_3CH=[@{d}]CH_2}
\arrow{0}[-90,0.25]
\chemfig{@{e}Br-[@{f}]@{g}Br}
}
\ce{->}
\chemfig{CH_3\chemabove{C}{\scrp}HCH_2Br} \+ \chemfig{Br^{-}} 
\schemestop
\chemmove[cyan,>=latex,shorten <=2pt,shorten >=2pt]{ 
\draw[shorten >=1pt,->] (d) ..controls +(-90:.75cm) and +(135:1cm) .. (e) ;} 
\chemmove[red,>=latex,shorten <=1pt,shorten >=2pt]{ 
\draw[shorten >=0pt,->] (f) ..controls +(-90:.5cm) and +(-90:1cm) .. (g) 
;}

\vspace{3cm}


\schemestart
\chemfig{CH_3CH=[@{d}]CH_2}
\arrow{->[\chemfig{@{e}Br-[@{f}]@{g}Br}]}
\chemfig{CH_3\chemabove{C}{\scrp}HCH_2Br} \+ \chemfig{Br^{-}} 
\schemestop
\chemmove[cyan,>=latex,shorten <=2pt,shorten >=2pt]{ 
\draw[shorten >=1pt,->] (d) ..controls +(90:.75cm) and +(135:.75cm) .. (e) ;} 
\chemmove[red,>=latex,shorten <=1pt,shorten >=2pt]{ 
\draw[shorten >=0pt,->] (f) ..controls +(90:.5cm) and +(90:.5cm) .. (g) 
;}
\end{document}
2

Two methods, using only commands from the "chemfig" package

  1. Positioning Br2 after the end of the chemical reaction:

    \setchemfig{atom sep=1.5em,bond offset=0pt}
    
    \begin{document}
    
    \schemestart
    
    \chemfig{CH_3CH=[@{a},1.5]CH_2}
    
    \arrow{->} 
    
    \chemfig{CH_3\chemabove{C}{\scriptstyle+}HCH_2Br} 
    
    \+ \chemfig{Br^{-}}
    
    \arrow(@{a}--){0}[320,.6]\chemfig{@{b}Br-[@{c},1.5]@{d}Br}
    
    %---------------------------------------------------------------
    
    \chemmove{
    
        \draw[red,shorten <=2pt,shorten >=1pt](a).. controls +(270:8mm) and +(90:8mm)..(b);
    
        \draw[red,shorten <=1pt,shorten >=1pt](c).. controls +(90:6mm) and +(90:6mm)..(d);
    
     }
    
    \schemestop
    
    \end{document}
    
  2. or placing Br2 at the beginning, but you will need to reposition the reaction arrow

     \begin{document}
    
     \schemestart
    
     \chemfig{CH_3CH=[@{a},1.5]C@{z}H_2}
    
     \arrow(@{a}--){0}[320,.6]\chemfig{@{b}Br-[@{c},1.5]@{d}Br}
    
     \arrow(@{z}--){->} 
    
     \chemfig{CH_3\chemabove{C}{\scriptstyle+}HCH_2Br}
    
     \+ \chemfig{Br^{-}}
    
     %---------------------------------------------------------------
    
     \chemmove{
    
     \draw[red,shorten <=2pt,shorten >=1pt](a).. controls +(270:8mm) and +(90:8mm)..(b); 
    
     \draw[red,shorten <=1pt,shorten >=1pt](c).. controls +(90:6mm) and +(90:6mm)..(d);
    
     }
    
     \schemestop
    
     \end{document}
    

Both have a very similar result.

enter image description here

With bromine at angle 270

\begin{document}
    \schemestart
    %
    \chemfig{CH_3CH=[@{a},1.5]C@{z}H_2}
    %
    \arrow(@{a}--){0}[320,.6]\chemfig{@{b}Br-[@{c},1.5]@{d}Br}
    %
    \arrow(@{z}--){->}
    %
    \chemfig{CH_3@{y}\chemabove{C}{\scriptstyle+}HCH_2Br}
    %
    \arrow(@{y}--){0}[-90,.3]\+ \chemfig{Br^{-}}
    %
    %---------------------------------------------------------------
    \chemmove{
        \draw[red,shorten <=2pt,shorten >=1pt](a).. controls +(270:8mm) and +(90:8mm)..(b);
        \draw[red,shorten <=1pt,shorten >=1pt](c).. controls +(90:6mm) and +(90:6mm)..(d);  
    }
\schemestop

\end{document}

enter image description here

4
  • I tried to place the last bromine atom at 90° or 270° and the product was not aligned with the arrow. Your kind treatment will be appreciated
    – Kidegalize
    Sep 25, 2021 at 16:11
  • @Kidegalize -- I added more code to my answer. Is that what you are looking for?
    – CrocoDuck
    Sep 25, 2021 at 19:25
  • apologies for I was not clear. The first step is very fine. I have drawn an arrow from Br^- to the C with + above it. I would like this Br to be at 270° in the final product.
    – Kidegalize
    Sep 26, 2021 at 4:30
  • 1
    @Kidegalize -- This? \chemfig{CH_3CHCH_2Br(-[6,,3]Br)}
    – CrocoDuck
    Sep 26, 2021 at 14:52

You must log in to answer this question.

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