% \iffalse meta-comment
%% File: ccycle.dtx
%
%  Copyright 1993,1996,1998,2001,2002,2004,2009,2010,2013 by Shinsaku Fujita
%
%  This file is part of XyMTeX system.
%  -------------------------------------
%
% This file is a successor to:
%
% ccycle.sty
% %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% \typeout{XyMTeX for Drawing Chemical Structural Formulas. Version 1.00}
% \typeout{       -- Released December 1, 1993 by Shinsaku Fujita}
% Copyright (C) 1993 by Shinsaku Fujita, all rights reserved.
%
% This file is a part of the macro package ``XyMTeX'' which has been 
% designed for typesetting chemical structural formulas.
%
% This file is to be contained in the ``xymtex'' directory which is 
% an input directory for TeX. It is a LaTeX optional style file and 
% should be used only within LaTeX, because several macros of the file 
% are based on LaTeX commands. 
%
% For the review of XyMTeX, see
%  (1)  Shinsaku Fujita, ``Typesetting structural formulas with the text
%    formatter TeX/LaTeX'', Computers and Chemistry, in press.    
% The following book deals with an application of TeX/LaTeX to 
% preparation of manuscripts of chemical fields:
%  (2)  Shinsaku Fujita, ``LaTeX for Chemists and Biochemists'' 
%    Tokyo Kagaku Dozin, Tokyo (1993) [in Japanese].  
%
% This work may be distributed and/or modified under the
% conditions of the LaTeX Project Public License, either version 1.3
% of this license or (at your option) any later version.
% The latest version of this license is in
%   http://www.latex-project.org/lppl.txt
% and version 1.3 or later is part of all distributions of LaTeX
% version 2005/12/01 or later.
%
% This work has the LPPL maintenance status `maintained'. 
% The Current Maintainer of this work is Shinsaku Fujita.
%
% This work consists of the files ccycle.dtx and ccycle.ins
% and the derived file ccycle.sty.
%
% Please report any bugs, comments, suggestions, etc. to:
%   Shinsaku Fujita, 
%   Shonan Institute of Chemoinformatics and Mathematical Chemistry
%   Kaneko 479-7 Ooimachi, Ashigara-Kami-Gun, Kanagawa 250-0019 Japan
%  (old address)
%   Ashigara Research Laboratories, Fuji Photo Film Co., Ltd., 
%   Minami-Ashigara, Kanagawa-ken, 250-01, Japan.
%
% %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% \def\j@urnalname{ccycle}
% \def\versi@ndate{December 01, 1993}
% \def\versi@nno{ver1.00}
% \def\copyrighth@lder{SF} % Shinsaku Fujita
% %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% \def\j@urnalname{ccycle}
% \def\versi@ndate{March 05, 1994}
% \def\versi@nno{ver1.01}
% \def\copyrighth@lder{SF} % Shinsaku Fujita
% %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% \def\j@urnalname{ccycle}
% \def\versi@ndate{August 16, 1996}
% \def\versi@nno{ver1.01a}
% \def\copyrighth@lder{SF} % Shinsaku Fujita
% %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% \def\j@urnalname{ccycle}
% \def\versi@ndate{October 31, 1998}
% \def\versi@nno{ver1.02}
% \def\copyrighth@lder{SF} % Shinsaku Fujita
% %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% \def\j@urnalname{ccycle}
% \def\versi@ndate{December 25, 1998}
% \def\versi@nno{ver2.00}
% \def\copyrighth@lder{SF} % Shinsaku Fujita
% %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% \def\j@urnalname{ccycle}
% \def\versi@ndate{June 20, 2001}
% \def\versi@nno{ver2.01}
% \def\copyrighth@lder{SF} % Shinsaku Fujita
% %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% \def\j@urnalname{ccycle}
% \def\versi@ndate{April 30, 2002}
% \def\versi@nno{ver3.00}
% \def\copyrighth@lder{SF} % Shinsaku Fujita
% %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% \def\j@urnalname{ccycle}
% \def\versi@ndate{May 30, 2002}
% \def\versi@nno{ver4.00}
% \def\copyrighth@lder{SF} % Shinsaku Fujita
% %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% \def\j@urnalname{ccycle}
% \def\versi@ndate{August 30, 2004}
% \def\versi@nno{ver4.01}
% \def\copyrighth@lder{SF} % Shinsaku Fujita
% %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% \def\j@urnalname{ccycle}
% \def\versi@ndate{December 20, 2004}
% \def\versi@nno{ver4.02}
% \def\copyrighth@lder{SF} % Shinsaku Fujita
% %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% \def\j@urnalname{ccycle}
% \def\versi@ndate{June 15, 2009}
% \def\versi@nno{ver4.04}
% \def\copyrighth@lder{SF} % Shinsaku Fujita
% %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% \def\j@urnalname{ccycle}
% \def\versi@ndate{October 01, 2010}
% \def\versi@nno{ver5.00}
% \def\copyrighth@lder{SF} % Shinsaku Fujita
% %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% \def\j@urnalname{ccycle}
% \def\versi@ndate{April 01, 2013}
% \def\versi@nno{ver5.01b}
% \def\copyrighth@lder{SF} % Shinsaku Fujita
% %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% \def\j@urnalname{ccycle}
% \def\versi@ndate{June 26, 2013}
% \def\versi@nno{ver5.01bb}
% \def\copyrighth@lder{SF} % Shinsaku Fujita
% %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%
% \fi
%
% \CheckSum{3681}
%% \CharacterTable
%%  {Upper-case    \A\B\C\D\E\F\G\H\I\J\K\L\M\N\O\P\Q\R\S\T\U\V\W\X\Y\Z
%%   Lower-case    \a\b\c\d\e\f\g\h\i\j\k\l\m\n\o\p\q\r\s\t\u\v\w\x\y\z
%%   Digits        \0\1\2\3\4\5\6\7\8\9
%%   Exclamation   \!     Double quote  \"     Hash (number) \#
%%   Dollar        \$     Percent       \%     Ampersand     \&
%%   Acute accent  \'     Left paren    \(     Right paren   \)
%%   Asterisk      \*     Plus          \+     Comma         \,
%%   Minus         \-     Point         \.     Solidus       \/
%%   Colon         \:     Semicolon     \;     Less than     \<
%%   Equals        \=     Greater than  \>     Question mark \?
%%   Commercial at \@     Left bracket  \[     Backslash     \\
%%   Right bracket \]     Circumflex    \^     Underscore    \_
%%   Grave accent  \`     Left brace    \{     Vertical bar  \|
%%   Right brace   \}     Tilde         \~}
%
% \setcounter{StandardModuleDepth}{1}
%
% \StopEventually{}
% \MakeShortVerb{\|}
%
% \iffalse
% \changes{v1.01a}{1996/06/17}{first edition for LaTeX2e}
% \changes{v1.02}{1998/10/31}{revised edition for LaTeX2e}
% \changes{v2.00}{1998/12/25}{enhanced edition for LaTeX2e}
% \changes{v2.01}{2001/06/20}{Size reduction and Clipping information}
% \changes{v2.01}{2001/06/21}{The command \cs{dotorline} is added.}
% \changes{v3.00}{2002/04/30}{sfpicture environment, etc.}
% \changes{v4.00}{2002/05/30}{PostScript output and ShiftPicEnv}
% \changes{v4.01}{2004/08/30}{Minor additions}
% \changes{v4.02}{2004/12/20}{Wedge bonds}
% \changes{v4.04}{2009/6/15}{Wavy bonds}
% \changes{v5.00}{2010/10/01}{bond coloring and the LaTeX Project Public License}
% \changes{v5.01b}{2013/04/01}{Wavy bonds for \cs{bornane}}
% \changes{v5.01}{2013/06/24}{bornane, adamantane, hadamantane: front-to-back crossing}
% \changes{v5.01}{2013/06/25}{bornane 7SU and 7SV added, bug fix}
% \changes{v5.01}{2013/06/26}{bug fix, added 7SA, 7SB, 7Su, 7Sd}
% \changes{v5.01}{2013/07/23}{background color}
% \fi
%
% \iffalse
%<*driver>
\NeedsTeXFormat{pLaTeX2e}
% \fi
\ProvidesFile{ccycle.dtx}[2013/07/23 v5.01 XyMTeX{} package file]
% \iffalse
\documentclass{ltxdoc}
\GetFileInfo{ccycle.dtx}
%
% %%XyMTeX Logo: Definition 2%%%
\def\UPSILON{\char'7}
\def\XyM{X\kern-.30em\smash{%
\raise.50ex\hbox{\UPSILON}}\kern-.30em{M}}
\def\XyMTeX{\XyM\kern-.1em\TeX}
% %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\title{Further Cyclic Compounds by {\sffamily ccycle.sty} 
(\fileversion) of \XyMTeX{}}
\author{Shinsaku Fujita \\ 
Shonan Institute of Chemoinformatics and Mathematical Chemistry, \\
Kaneko 479-7 Ooimachi, Ashigara-Kami-Gun, Kanagawa 250-0019 Japan
% % (old address)
% %Department of Chemistry and Materials Technology, \\
% %Kyoto Institute of Technology, \\
% %Matsugasaki, Sakyoku, Kyoto, 606-8585 Japan
% %% (old address)
% %% Ashigara Research Laboratories, 
% %% Fuji Photo Film Co., Ltd., \\ 
% %% Minami-Ashigara, Kanagawa, 250-01 Japan
}
\date{\filedate}
%
\begin{document}
   \maketitle
   \DocInput{ccycle.dtx}
\end{document}
%</driver>
% \fi
%
% \section{Introduction}\label{ccycle:intro}
%
% \subsection{Options for {\sffamily docstrip}}
%
% \DeleteShortVerb{\|}
% \begin{center}
% \begin{tabular}{|l|l|}
% \hline
% \emph{option} & \emph{function}\\ \hline
% ccycle & ccycle.sty \\
% driver & driver for this dtx file \\
% \hline
% \end{tabular}
% \end{center}
% \MakeShortVerb{\|}
%
% \subsection{Version Information}
%
%    \begin{macrocode}
%<*ccycle>
\typeout{XyMTeX for Drawing Chemical Structural Formulas. Version 5.01}
\typeout{       -- Released July 23, 2013 by Shinsaku Fujita}
% %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\def\j@urnalname{ccycle}
\def\versi@ndate{July 23, 2013}
\def\versi@nno{ver5.01}
\def\copyrighth@lder{SF} % Shinsaku Fujita
% %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\typeout{XyMTeX Macro File `\j@urnalname' (\versi@nno) <\versi@ndate>%
\space[\copyrighth@lder]}
%    \end{macrocode}
%
% \section{List of commands for ccycle.sty}
%
% \begin{verbatim}
% ********************************
% * ccycle.sty: list of commands *
% ********************************
%
%  Setting of Bonds
%
%     \@chaira (for cyclohexane chair)
%     \@chairb
%     \@chairc
%     \@chaird
%     \@chaire
%     \@chairf
%
%     \@borna (for bornanes)
%     \@bornb
%     \@bornc
%     \@bornd
%     \@borne
%     \@bornf
%     \@borng
%
%  Basic Macros
%
%     \chair                     \@chair
%     \bicychepv                 \@bicychepv
%     \bicycheph                 \@bicycheph
%     \bornane                   \@bornane
%     \adamantane                \@damantane
%
%  (Added March 05, 1994 by Shinsaku Fujita)
%  Setting of Bonds
%
%     \@chairia (for cyclohexane chair inversed)
%     \@chairib  \@chairic  \@chairid
%     \@chairie  \@chairif
%
%  Basic Macros
%
%     \chairi                     \@chairi
% 
%  (Added June 16, 1996 by Shinsaku Fujita)
%  Setting of Bonds
%
%     \@chairiI (for horizontal-type adamantane)
%     \@chairiII    \@chairiIII    \@chairiIV
%     \@chairiV     \@chairiVI     \@chairiVII
%     \@chairiVIII  \@chairiIX     \@chairiX
%     
%  Basic Macros
%
%     \hadamantane                \@hadamantane
%
%  Macros for adjusting substitution sites (for Version 1.02)
%
%     \ylchairposition
%     \ylchairiposition
%     \ylbornaneposition
%     \yladamanposition
%     \ylhadamanposition
%
% \end{verbatim}
%
% \section{Input of basic macros}
%
% To assure the compatibility to \LaTeX{}2.09 (the native mode), 
% the commands added by \LaTeXe{} have not been used in the resulting sty 
% files ({\sf ccycle.sty} for the present case).  Hence, the combination 
% of |\input| and |\@ifundefined| is used to crossload sty 
% files ({\sf chemstr.sty} for the present case) in place of the 
% |\RequirePackage| command of \LaTeXe{}. 
%
%    \begin{macrocode}
% *************************
% * input of basic macros *
% *************************
\@ifundefined{setsixringv}{\input chemstr.sty\relax}{}
\unitlength=0.1pt
%    \end{macrocode}
%
% \begin{macro}{\ifmolfront}
% \changes{v4.02}{2004/12/20}{Avoid wedged front bonds} 
%    \begin{macrocode}
\@ifundefined{ifmolfront}{\newif\ifmolfront \molfrontfalse}{}
%    \end{macrocode}
% \end{macro}
%
%
% \section{Chair-form cyclohexanes}
% \subsection{Macros for setting substituents}
% 
% Macros |\@chaira| to |\@chairf| are used to set substituents 
% on each position of cyclohexane. Note that comments (conerning locant 
% numbers) on the end of each row have lost the exact meaning, 
% since such a command moiety is used in many macros after copying. 
%
% \begin{macro}{\@chaira}
% \changes{v1.02}{1998/10/31}{Adding \cs{yl@xdiff} and \cs{yl@ydiff}}
% \changes{v4.04}{2009/06/15}{Adding wavy bonds}
%    \begin{macrocode}
% **********************************************
% * treatment of the chair form of cyclohexane *
% **********************************************
% %%%%%%%%%%%%%%%
% % subst. on 1 %
% %%%%%%%%%%%%%%%
\def\@chaira{%
   \if\@tmpb S%single bond
    \ifx\@tmpc\empty%
     \yl@xdiff=10
     \yl@ydiff=10
           \Put@Line(0,0)(-1,1){120}% single bond at 1
           \putlatom{-130}{110}{\@memberb}% left type
    \else\if\@tmpc a%(a) axial
     \yl@xdiff=42
     \yl@ydiff=-12
           \Put@Line(0,0)(0,1){168}% single bond at 1 axial
           \putlratom{-42}{180}{\@memberb}% left & right type
    \else\if\@tmpc e%(e) beta
     \yl@xdiff=16
     \yl@ydiff=44
           \Put@Line(0,0)(-5,-3){144}% single bond at 1 equatorial
           \putlatom{-160}{-130}{\@memberb}% left type
    \fi\fi\fi%
%2009/06/15
    \else\if\@tmpb U%(U) alpha undefined
     \yl@xdiff=10
     \yl@ydiff=10
           \putlatom{-130}{110}{\@memberb}% left type
           {%
           \WaveBonds%
           \Put@Line(0,0)(-1,1){120}% single bond at 1
           }%
%
   \else \if\@tmpb D%double bond
     \yl@xdiff=10
     \yl@ydiff=10
           \Put@Line(-10,-10)(-1,1){120}% double bond at 1
           \Put@Line(10,10)(-1,1){120}% double bond at 1
           \putlatom{-130}{110}{\@memberb}% left type
          \else%
     \yl@xdiff=10
     \yl@ydiff=10
           \Put@Line(0,0)(-1,1){120}% single bond at 1
           \putlatom{-130}{110}{\@memberb}% left type
   \fi\fi\fi}%
%    \end{macrocode}
% \end{macro}
%
% \begin{macro}{\@chairb}
% \changes{v1.02}{1998/10/31}{Adding \cs{yl@xdiff} and \cs{yl@ydiff}}
% \changes{v4.04}{2009/06/15}{Adding wavy bonds}
%    \begin{macrocode}
% %%%%%%%%%%%%%%%
% % subst. on 2 %
% %%%%%%%%%%%%%%%
\def\@chairb{%
   \if\@tmpb S%single bond
    \ifx\@tmpc\empty%
     \yl@xdiff=10
     \yl@ydiff=70
           \Put@Line(170,-226)(-1,-1){120}% single bond at 2
           \putlatom{40}{-416}{\@memberb}% left type
    \else\if\@tmpc a%(a) axial
     \yl@xdiff=32
     \yl@ydiff=92
           \Put@Line(170,-226)(0,-1){168}% single bond at 2 axial
           \putlratom{138}{-486}{\@memberb}% left & right type
    \else\if\@tmpc e%(e) beta
     \yl@xdiff=16
     \yl@ydiff=34
           \Put@Line(170,-226)(-5,3){144}% single bond at 2 equatorial
           \putlatom{10}{-174}{\@memberb}% left type
    \fi\fi\fi%
%2009/06/15
    \else\if\@tmpb U%(U) alpha undefined
     \yl@xdiff=10
     \yl@ydiff=70
           \putlatom{40}{-416}{\@memberb}% left type
           {%
           \WaveBonds%
           \Put@Line(170,-226)(-1,-1){120}% single bond at 2
           }%
%           
   \else \if\@tmpb D%double bond
     \yl@xdiff=10
     \yl@ydiff=70
           \Put@Line(160,-216)(-1,-1){120}% double bond at 2
           \Put@Line(180,-236)(-1,-1){120}% double bond at 2
           \putlatom{40}{-416}{\@memberb}% left type
          \else%
     \yl@xdiff=10
     \yl@ydiff=70
           \Put@Line(170,-226)(-1,-1){120}% single bond at 2
           \putlatom{40}{-416}{\@memberb}% left type
   \fi\fi\fi}%
%    \end{macrocode}
% \end{macro}
%
% \begin{macro}{\@chairc}
% \changes{v1.02}{1998/10/31}{Adding \cs{yl@xdiff} and \cs{yl@ydiff}}
% \changes{v4.04}{2009/06/15}{Adding wavy bonds}
%    \begin{macrocode}
% %%%%%%%%%%%%%%%
% % subst. on 3 %
% %%%%%%%%%%%%%%%
\def\@chairc{%
   \if\@tmpb S%single bond
    \ifx\@tmpc\empty%
     \yl@xdiff=-10
     \yl@ydiff=24
           \Put@Line(573,-91)(5,4){170}% single bond at 3
           \putratom{753}{21}{\@memberb}% right type
    \else\if\@tmpc a%(a) axial
     \yl@xdiff=40
     \yl@ydiff=-24
           \Put@Line(573,-91)(0,1){168}% single bond at 3 axial
           \putlratom{533}{101}{\@memberb}% left type
    \else\if\@tmpc e%(e) beta
     \yl@xdiff=-36
     \yl@ydiff=83
           \Put@Line(573,-91)(5,-3){144}% single bond at 3 equatorial
           \putlatom{753}{-260}{\@memberb}% left type
    \fi\fi\fi%
%2009/06/15
    \else\if\@tmpb U%(U) alpha undefined
     \yl@xdiff=-10
     \yl@ydiff=24
           \putratom{753}{21}{\@memberb}% right type
           {%
           \WaveBonds%
           \Put@Line(573,-91)(5,4){170}% single bond at 3
           }%
%           
   \else \if\@tmpb D%double bond
     \yl@xdiff=0
     \yl@ydiff=0
           \Put@Line(563,-83)(5,4){170}% double bond at 3
           \Put@Line(583,-99)(5,4){170}% double bond at 3
           \putratom{733}{41}{\@memberb}% right type
          \else%
     \yl@xdiff=-10
     \yl@ydiff=24
           \Put@Line(573,-91)(5,4){170}% single bond at 3
           \putratom{753}{21}{\@memberb}% right type
   \fi\fi\fi}%
%    \end{macrocode}
% \end{macro}
%
% \begin{macro}{\@chaird}
% \changes{v1.02}{1998/10/31}{Adding \cs{yl@xdiff} and \cs{yl@ydiff}}
% \changes{v4.04}{2009/06/15}{Adding wavy bonds}
%    \begin{macrocode}
% %%%%%%%%%%%%%%%
% % subst. on 4 %
% %%%%%%%%%%%%%%%
\def\@chaird{%
   \if\@tmpb S%single bond
    \ifx\@tmpc\empty%
     \yl@xdiff=10
     \yl@ydiff=70
           \Put@Line(843,-181)(1,-1){120}% single bond at 4
           \putratom{953}{-371}{\@memberb}% right type
    \else\if\@tmpc a%(a) axial
     \yl@xdiff=42
     \yl@ydiff=91
           \Put@Line(843,-181)(0,-1){168}% single bond at 4 axial
           \putlratom{801}{-440}{\@memberb}% left & right type
    \else\if\@tmpc e%(e) beta
     \yl@xdiff=-16
     \yl@ydiff=16
           \Put@Line(843,-181)(5,3){144}% single bond at 4 equatorial
           \putratom{1003}{-111}{\@memberb}% right type
    \fi\fi\fi%
%2009/06/15
    \else\if\@tmpb U%(U) alpha undefined
     \yl@xdiff=10
     \yl@ydiff=70
           \putratom{953}{-371}{\@memberb}% right type
           {%
           \WaveBonds%
           \Put@Line(843,-181)(1,-1){120}% single bond at 4
           }%
%           
   \else \if\@tmpb D%double bond
     \yl@xdiff=10
     \yl@ydiff=70
           \Put@Line(833,-191)(1,-1){120}% double bond at 4
           \Put@Line(853,-171)(1,-1){120}% double bond at 4
           \putratom{953}{-371}{\@memberb}% right type
          \else%
     \yl@xdiff=10
     \yl@ydiff=70
           \Put@Line(843,-181)(1,-1){120}% single bond at 4
           \putratom{953}{-371}{\@memberb}% right type
   \fi\fi\fi}%
%    \end{macrocode}
% \end{macro}
%
% \begin{macro}{\@chaire}
% \changes{v1.02}{1998/10/31}{Adding \cs{yl@xdiff} and \cs{yl@ydiff}}
% \changes{v4.04}{2009/06/15}{Adding wavy bonds}
%    \begin{macrocode}
% %%%%%%%%%%%%%%%
% % subst. on 5 %
% %%%%%%%%%%%%%%%
\def\@chaire{%
   \if\@tmpb S%single bond
    \ifx\@tmpc\empty%
     \yl@xdiff=-10
     \yl@ydiff=10
           \Put@Line(673,46)(1,1){120}% single bond at 5
           \putratom{803}{158}{\@memberb}% right type
    \else\if\@tmpc a%(a) axial
     \yl@xdiff=40
     \yl@ydiff=-24
           \Put@Line(673,46)(0,1){168}% single bond at 5 axial
           \putlratom{633}{238}{\@memberb}% left & right type
    \else\if\@tmpc e%(e) beta
     \yl@xdiff=-6
     \yl@ydiff=63
           \Put@Line(673,46)(5,-3){144}% single bond at 5 equatorial
           \putratom{823}{-103}{\@memberb}% right type
    \fi\fi\fi%
%2009/06/15
    \else\if\@tmpb U%(U) alpha undefined
     \yl@xdiff=-10
     \yl@ydiff=10
           \putratom{803}{158}{\@memberb}% right type
           {%
           \WaveBonds%
           \Put@Line(673,46)(1,1){120}% single bond at 5
           }%
%           
   \else \if\@tmpb D%double bond
     \yl@xdiff=-10
     \yl@ydiff=10
           \Put@Line(663,53)(1,1){120}% double bond at 5
           \Put@Line(683,38)(1,1){120}% double bond at 5
           \putratom{803}{158}{\@memberb}%  right type
          \else%
     \yl@xdiff=-10
     \yl@ydiff=24
           \Put@Line(673,46)(5,4){170}% single bond at 5
           \putratom{853}{158}{\@memberb}% right type
   \fi\fi\fi}%
%    \end{macrocode}
% \end{macro}
%
% \begin{macro}{\@chairf}
% \changes{v1.02}{1998/10/31}{Adding \cs{yl@xdiff} and \cs{yl@ydiff}}
% \changes{v4.04}{2009/06/15}{Adding wavy bonds}
%    \begin{macrocode}
% %%%%%%%%%%%%%%%
% % subst. on 6 %
% %%%%%%%%%%%%%%%
\def\@chairf{%
   \if\@tmpb S%single bond
    \ifx\@tmpc\empty%
     \yl@xdiff=0
     \yl@ydiff=54
           \Put@Line(270,-90)(-5,-4){170}% single bond at 6
           \putlatom{100}{-280}{\@memberb}% left type
    \else\if\@tmpc a%(a) axial
     \yl@xdiff=32
     \yl@ydiff=92
           \Put@Line(270,-90)(0,-1){168}% single bond at 6 axial
           \putlratom{238}{-350}{\@memberb}% left type
    \else\if\@tmpc e%(e) beta
     \yl@xdiff=26
     \yl@ydiff=-14
           \Put@Line(270,-90)(-5,3){144}% single bond at 6 equatorial
           \putratom{100}{18}{\@memberb}% left type
    \fi\fi\fi%
%2009/06/15
    \else\if\@tmpb U%(U) alpha undefined
     \yl@xdiff=0
     \yl@ydiff=54
           \putlatom{100}{-280}{\@memberb}% left type
           {%
           \WaveBonds%
           \Put@Line(270,-90)(-5,-4){170}% single bond at 6
           }%
%           
   \else \if\@tmpb D%double bond
     \yl@xdiff=0
     \yl@ydiff=54
           \Put@Line(260,-80)(-5,-4){170}% double bond at 2
           \Put@Line(280,-100)(-5,-4){170}% double bond at 2
           \putlatom{100}{-280}{\@memberb}% left or right type
          \else%
     \yl@xdiff=0
     \yl@ydiff=54
           \Put@Line(270,-90)(-5,-4){170}% single bond at 2
           \putlatom{100}{-280}{\@memberb}% left type
   \fi\fi\fi}%
%    \end{macrocode}
% \end{macro}
%
% \subsection{Drawing of Chair-form cyclohexanes}
% 
% The standard skeleton of a chair form of cyclohexane is selected 
% to have the following locant numbers. 
%
% \begin{verbatim}
% ***************************
% * cyclohexane derivatives *
% *  (chair type)           *
% ***************************
% The following numbering is adopted in this macro. 
%
%                 5 
%              /  3  *
%     1  *  6  /    *  4
%        *  2 
%
% \end{verbatim}
%
% The macro |\chair| has an argument |SUBSLIST| as well as an optional 
% argument |BONDLIST|.  
%
% \begin{verbatim}
%   \chair[BONDLIST]{SUBSLIST}
% \end{verbatim}
%
% The |BONDLIST| argument contains one or more 
% characters selected from a to f, each of which indicates the presence of 
% an inner (endcyclic) double bond on the corresponding position. 
% \begin{verbatim}
%
%     BONDLIST = 
%
%           none       :  cyclohexane
%           a          :  1,2-double bond
%           b          :  2,3-double bond
%           c          :  4,3-double bond
%           d          :  4,5-double bond
%           e          :  5,6-double bond
%           f          :  6,1-double bond
% \end{verbatim}
%
% The |SUBSLIST| argument contains one or more substitution descriptors 
% which are separated from each other by a semicolon.  Each substitution 
% descriptor has a locant number with a bond modifier and a substituent, 
% where these are separated with a double equality symbol. 
% \begin{verbatim}
%
%     SUBSLIST: list of substituents (max 12 substitution positions)
%
%       for n = 1 to 6 
%
%           nD         :  exocyclic double bond at n-atom
%           nSa        :  axial single bond at n-atom
%           nSe        :  equatorial single bond at n-atom
%
% \end{verbatim}
%
% Several examples are shown as follows.
%
% \begin{verbatim}
%        \chair{1==Cl;2==F}
%        \chair[a]{1==Cl;4==F;2==CH$_{3}$}
%        \chair[eb]{1D==O;4Se==MeO;4Sa==OMe;5==Cl;6==Cl}
% \end{verbatim}
%
% The definition of |\@chair| uses a picture environment, in which 
% bonds are put directly, while subsituents are typset by using 
% the macros |\@chaira| to |\@chairf| described above.  
% \changes{v1.02}{1998/10/31}{Adding \cs{ylchairposition}, \cs{if@ylsw},
% \cs{yl@shifti}, \cs{@ylii}, \cs{yl@shiftii}, \cs{@ylii}, 
% \cs{yl@xdiff} and \cs{yl@ydiff}}
% \changes{v5.00}{2010/10/01}{For bond coloring}
%
% \begin{macro}{\@chair}
% \begin{macro}{\chair}
%    \begin{macrocode}
\def\chair{\@ifnextchar[{\@chair}{\@chair[r]}}
\def\@chair[#1]#2{%
\@reset@ylsw%
\ylchairposition{#2}%
\def\@@ylii{0}\def\@@yli{0}%
\begin{ShiftPicEnvB}(0,0)(-\yl@shiftii,-\yl@shifti)/%
(1600,800)(-400,-500){chair}%
(400,500)%2002/4/30 by S. Fujita
%skeletal bonds
   {\thicklines%
    \molfronttrue%
      \Put@Line(0,0)(3,-4){170}%          % bond 1 to 2
      \Put@Line(170,-226)(3,1){403}%      %      2 to 3
      \Put@Line(573,-91)(3,-1){270}%      %      3 to 4
   }%
   \thinlines%
      \Put@Line(843,-181)(-3,4){170}%     %      4 to 5
      \Put@Line(673,46)(-3,-1){403}%      %      5 to 6
      \Put@Line(0,0)(3,-1){270}%          %      1 to 6
% inner double bonds
\@tfor\member:=#1\do{%
\if\member r%no endcyclic bonds
\else \if\member a%
      \Put@Line(76,-42)(3,-4){110}%       % double bond 1 to 2
\else \if\member b%
      \Put@Line(200,-186)(3,1){343}%      %             2 to 3
\else \if\member c%
      \Put@Line(603,-70)(3,-1){190}%      %             3 to 4
\else \if\member d%
      \Put@Line(780,-141)(-3,4){110}%     %             4 to 5
\else \if\member e%
      \Put@Line(661,6)(-3,-1){343}%       %             5 to 6
\else \if\member f%
      \Put@Line(75,-50)(3,-1){170}%       %             1 to 6
\fi\fi\fi\fi\fi\fi\fi}%
% setting substituents
\@forsemicol\member:=#2\do{%
\ifx\member\empty\else
\expandafter\@m@mb@r\member;\relax%
\expandafter\threech@r\@membera{}{}%
\ifx\@memberb\@yl\else
\ifcase\@tmpa%0 omit
 \or\setBScolor{\@chaira}% subst. on 1
% \@chaira% subst. on 1
 \or\setBScolor{\@chairb}% subst. on 2
% \@chairb% subst. on 2
 \or\setBScolor{\@chairc}% subst. on 3
% \@chairc% subst. on 3
 \or\setBScolor{\@chaird}% subst. on 4
% \@chaird% subst. on 4
 \or\setBScolor{\@chaire}% subst. on 5
% \@chaire% subst. on 5
 \or\setBScolor{\@chairf}% subst. on 6
% \@chairf% subst. on 6
\fi%end of ifcase
\fi\fi%
}%
\end{ShiftPicEnvB}%
}%               %end of \chair macro
%    \end{macrocode}
% \end{macro}
% \end{macro}
%
% The command |\ylchairposition| is to obtain the shift values 
% |\@ylii| and |\@yli| which are used for shifting the standard 
% point of a substituent. 
% \changes{v1.02}{1998/10/23}{New ommands for setting substituents}
%
% \begin{macro}{\ylchairposition}
%    \begin{macrocode}
\def\ylchairposition#1{%
\@@ylswfalse%%%\@reset@ylsw
\@forsemicol\member:=#1\do{%
\if@@ylsw\else
\ifx\member\empty\else
\expandafter\@m@mb@r\member;\relax
\expandafter\threech@r\@membera{}{}\relax
\ifx\@memberb\@yl\relax\@@ylswtrue\else\@@ylswfalse\fi
\if@@ylsw
\ifcase\@tmpa%0 omit
 \or\gdef\@ylii{0}\gdef\@yli{0}\global\@ylswtrue% subst. on 1
 \or\gdef\@ylii{-170}\gdef\@yli{226}\global\@ylswtrue% subst. on 2
 \or\gdef\@ylii{-573}\gdef\@yli{91}\global\@ylswtrue% subst. on 3
 \or\gdef\@ylii{-843}\gdef\@yli{181}\global\@ylswtrue% subst. on 4
 \or\gdef\@ylii{-673}\gdef\@yli{-46}\global\@ylswtrue% subst. on 5
 \or\gdef\@ylii{-270}\gdef\@yli{90}\global\@ylswtrue% subst. on 6
\fi%end of ifcase
\fi\fi\fi}}%
%    \end{macrocode}
% \end{macro}
%
% \section{Inverse chair-form cyclohexanes}
% \subsection{Macros for setting substituents}
% 
% Macros |\@chairia| to |\@chairif| are used to set substituents 
% on each position of cyclohexane.  Note that they corresopond to 
% the counterparts of chair-form cyclohexanes described above. 
%
% \begin{macro}{\@chairia}
% \changes{v1.02}{1998/10/31}{Adding \cs{yl@xdiff} and \cs{yl@ydiff}}
% \changes{v4.04}{2009/6/15}{Adding wavy bonds}
%    \begin{macrocode}
% ********************************************************
% * treatment of the chair form (inverse) of cyclohexane *
% *  added March 05, 1994 by Shinsaku Fujita             *
% ********************************************************
% %%%%%%%%%%%%%%%
% % subst. on 1 %
% %%%%%%%%%%%%%%%
\def\@chairia{%
   \if\@tmpb S%single bond
    \ifx\@tmpc\empty%
     \yl@xdiff=10
     \yl@ydiff=90
           \Put@Line(0,0)(-1,-1){120}% single bond at 1
           \putlatom{-130}{-210}{\@memberb}% left type
    \else\if\@tmpc a%(a) axial
     \yl@xdiff=42
     \yl@ydiff=92
           \Put@Line(0,0)(0,-1){168}% single bond at 1 axial
           \putlratom{-42}{-260}{\@memberb}% left & right type
    \else\if\@tmpc e%(e) beta
     \yl@xdiff=16
     \yl@ydiff=36
           \Put@Line(0,0)(-5,3){144}% single bond at 1 equatorial
           \putlatom{-160}{50}{\@memberb}% left type
    \fi\fi\fi%
%2009/06/15
    \else\if\@tmpb U%(U) alpha undefined
      \yl@xdiff=10\relax
      \yl@ydiff=90\relax
           \putlatom{-130}{-210}{\@memberb}%     % left type
           {%
           \WaveBonds%
           \Put@Line(0,0)(-1,-1){120}%      % single bond at 1
           }%
%
   \else \if\@tmpb D%double bond
     \yl@xdiff=10
     \yl@ydiff=90
           \Put@Line(-10,10)(-1,-1){120}% double bond at 1
           \Put@Line(10,-10)(-1,-1){120}% double bond at 1
           \putlatom{-130}{-210}{\@memberb}% left type
          \else%
     \yl@xdiff=10
     \yl@ydiff=90
           \Put@Line(0,0)(-1,-1){120}% single bond at 1
           \putlatom{-130}{-210}{\@memberb}% left type
   \fi\fi\fi}%
%    \end{macrocode}
% \end{macro}
%
% \begin{macro}{\@chairif}
% \changes{v1.02}{1998/10/31}{Adding \cs{yl@xdiff} and \cs{yl@ydiff}}
% \changes{v4.04}{2009/06/15}{Adding wavy bonds}
%    \begin{macrocode}
% %%%%%%%%%%%%%%%
% % subst. on 6 %
% %%%%%%%%%%%%%%%
\def\@chairif{%
   \if\@tmpb S%single bond
    \ifx\@tmpc\empty%
     \yl@xdiff=10
     \yl@ydiff=30
           \Put@Line(170,226)(-1,1){120}% single bond at 6
           \putratom{40}{316}{\@memberb}% right type
    \else\if\@tmpc a%(a) axial
     \yl@xdiff=32
     \yl@ydiff=-12
           \Put@Line(170,226)(0,1){168}% single bond at 6 axial
           \putlratom{138}{406}{\@memberb}% left & right type
    \else\if\@tmpc e%(e) beta
     \yl@xdiff=16
     \yl@ydiff=46
           \Put@Line(170,226)(-5,-3){144}% single bond at 6 equatorial
           \putlatom{10}{94}{\@memberb}% left type
    \fi\fi\fi%
%2009/06/15
    \else\if\@tmpb U%(U) alpha undefined
      \yl@xdiff=10\relax
      \yl@ydiff=30\relax
           \putratom{40}{316}{\@memberb}% right type
           {%
           \WaveBonds%
           \Put@Line(170,226)(-1,1){120}% single bond at 6
           }%
%
   \else \if\@tmpb D%double bond
     \yl@xdiff=10
     \yl@ydiff=30
           \Put@Line(160,216)(-1,1){120}% double bond at 6
           \Put@Line(180,236)(-1,1){120}% double bond at 6
           \putlatom{40}{316}{\@memberb}% left type
          \else%
     \yl@xdiff=10
     \yl@ydiff=30
           \Put@Line(170,226)(-1,1){120}% single bond at 6
           \putlatom{40}{316}{\@memberb}% left type
    \fi\fi\fi}%
%    \end{macrocode}
% \end{macro}
%
% \begin{macro}{\@chairie}
% \changes{v1.02}{1998/10/31}{Adding \cs{yl@xdiff} and \cs{yl@ydiff}}
% \changes{v4.04}{2009/06/15}{Adding wavy bonds}
%    \begin{macrocode}
% %%%%%%%%%%%%%%%
% % subst. on 5 %
% %%%%%%%%%%%%%%%
\def\@chairie{%
   \if\@tmpb S%single bond
    \ifx\@tmpc\empty%
     \yl@xdiff=-10
     \yl@ydiff=76
           \Put@Line(573,91)(5,-4){170}% single bond at 5
           \putratom{753}{-101}{\@memberb}% right type
    \else\if\@tmpc a%(a) axial
     \yl@xdiff=40
     \yl@ydiff=104
           \Put@Line(573,91)(0,-1){168}% single bond at 5 axial
           \putlratom{533}{-181}{\@memberb}% left type
    \else\if\@tmpc e%(e) beta
     \yl@xdiff=-36
     \yl@ydiff=3
           \Put@Line(573,91)(5,3){144}% single bond at 5 equatorial
           \putlatom{753}{180}{\@memberb}% left type
    \fi\fi\fi%
%2009/06/15
    \else\if\@tmpb U%(U) alpha undefined
     \yl@xdiff=-10
     \yl@ydiff=76
           \putratom{753}{-101}{\@memberb}% right type
           {%
           \WaveBonds%
           \Put@Line(573,91)(5,-4){170}% single bond at 5
           }%
%
   \else \if\@tmpb D%double bond
     \yl@xdiff=-10
     \yl@ydiff=96
           \Put@Line(563,83)(5,-4){170}% double bond at 5
           \Put@Line(583,99)(5,-4){170}% double bond at 5
           \putratom{733}{-141}{\@memberb}% right type
          \else%
     \yl@xdiff=-10
     \yl@ydiff=76
           \Put@Line(573,91)(5,-4){170}% single bond at 5
           \putratom{753}{-121}{\@memberb}% right type
   \fi\fi\fi}%
%    \end{macrocode}
% \end{macro}
%
% \begin{macro}{\@chairid}
% \changes{v1.02}{1998/10/31}{Adding \cs{yl@xdiff} and \cs{yl@ydiff}}
% \changes{v4.04}{2009/06/15}{Adding wavy bonds}
%    \begin{macrocode}
% %%%%%%%%%%%%%%%
% % subst. on 4 %
% %%%%%%%%%%%%%%%
\def\@chairid{%
   \if\@tmpb S%single bond
    \ifx\@tmpc\empty%
     \yl@xdiff=10
     \yl@ydiff=30
           \Put@Line(843,181)(1,1){120}% single bond at 4
           \putratom{953}{271}{\@memberb}% right type
    \else\if\@tmpc a%(a) axial
     \yl@xdiff=42
     \yl@ydiff=-11
           \Put@Line(843,181)(0,1){168}% single bond at 4 axial
           \putlratom{801}{360}{\@memberb}% left & right type
    \else\if\@tmpc e%(e) beta
     \yl@xdiff=-16
     \yl@ydiff=64
           \Put@Line(843,181)(5,-3){144}% single bond at 4 equatorial
           \putratom{1003}{31}{\@memberb}% right type
    \fi\fi\fi%
%2009/06/15
    \else\if\@tmpb U%(U) alpha undefined
     \yl@xdiff=10
     \yl@ydiff=30
           \putratom{953}{271}{\@memberb}% right type
           {%
           \WaveBonds%
           \Put@Line(843,181)(1,1){120}% single bond at 4
           }%
%
   \else \if\@tmpb D%double bond
     \yl@xdiff=10
     \yl@ydiff=30
           \Put@Line(833,191)(1,1){120}% double bond at 4
           \Put@Line(853,171)(1,1){120}% double bond at 4
           \putratom{953}{271}{\@memberb}% right type
          \else%
     \yl@xdiff=10
     \yl@ydiff=30
           \Put@Line(843,181)(1,1){120}% single bond at 4
           \putratom{953}{271}{\@memberb}% right type
   \fi\fi\fi}%
%    \end{macrocode}
% \end{macro}
%
% \begin{macro}{\@chairic}
% \changes{v1.02}{1998/10/31}{Adding \cs{yl@xdiff} and \cs{yl@ydiff}}
% \changes{v4.04}{2009/06/15}{Adding wavy bonds}
%    \begin{macrocode}
% %%%%%%%%%%%%%%%
% % subst. on 3 %
% %%%%%%%%%%%%%%%
\def\@chairic{%
   \if\@tmpb S%single bond
    \ifx\@tmpc\empty%
     \yl@xdiff=-10
     \yl@ydiff=92
           \Put@Line(673,-46)(1,-1){120}% single bond at 3
           \putratom{803}{-258}{\@memberb}% right type
    \else\if\@tmpc a%(a) axial
     \yl@xdiff=40
     \yl@ydiff=110
           \Put@Line(673,-46)(0,-1){168}% single bond at 3 axial
           \putlratom{633}{-318}{\@memberb}% left & right type
    \else\if\@tmpc e%(e) beta
     \yl@xdiff=-6
     \yl@ydiff=17
           \Put@Line(673,-46)(5,3){144}% single bond at 3 equatorial
           \putratom{823}{23}{\@memberb}% right type
    \fi\fi\fi%
%2009/06/15
    \else\if\@tmpb U%(U) alpha undefined
     \yl@xdiff=-10
     \yl@ydiff=92
           \putratom{803}{-258}{\@memberb}% right type
           {%
           \WaveBonds%
           \Put@Line(673,-46)(1,-1){120}% single bond at 3
           }%
%
   \else \if\@tmpb D%double bond
     \yl@xdiff=-5
     \yl@ydiff=96
           \Put@Line(663,-53)(1,-1){120}% double bond at 3
           \Put@Line(683,-38)(1,-1){120}% double bond at 3
           \putratom{803}{-258}{\@memberb}%  right type
          \else%
     \yl@xdiff=-10
     \yl@ydiff=76
           \Put@Line(673,-46)(5,-4){170}% single bond at 3
           \putratom{853}{-258}{\@memberb}% right type
   \fi\fi\fi}%
%    \end{macrocode}
% \end{macro}
%
% \begin{macro}{\@chairib}
% \changes{v1.02}{1998/10/31}{Adding \cs{yl@xdiff} and \cs{yl@ydiff}}
% \changes{v4.04}{2009/06/15}{Adding wavy bonds}
%    \begin{macrocode}
% %%%%%%%%%%%%%%%
% % subst. on 2 %
% %%%%%%%%%%%%%%%
\def\@chairib{%
   \if\@tmpb S%single bond
    \ifx\@tmpc\empty%
     \yl@xdiff=0
     \yl@ydiff=46
           \Put@Line(270,90)(-5,4){170}% single bond at 2
           \putlatom{100}{180}{\@memberb}% left type
    \else\if\@tmpc a%(a) axial
     \yl@xdiff=32
     \yl@ydiff=-12
           \Put@Line(270,90)(0,1){168}% single bond at 2 axial
           \putlratom{238}{270}{\@memberb}% left type
    \else\if\@tmpc e%(e) beta
     \yl@xdiff=26
     \yl@ydiff=94
           \Put@Line(270,90)(-5,-3){144}% single bond at 2 equatorial
           \putratom{100}{-98}{\@memberb}% left type
    \fi\fi\fi%
%2009/06/15
    \else\if\@tmpb U%(U) alpha undefined
     \yl@xdiff=0
     \yl@ydiff=46
           \putlatom{100}{180}{\@memberb}% left type
           {%
           \WaveBonds%
           \Put@Line(270,90)(-5,4){170}% single bond at 2
           }%
%
   \else \if\@tmpb D%double bond
     \yl@xdiff=0
     \yl@ydiff=26
           \Put@Line(260,80)(-5,4){170}% double bond at 2
           \Put@Line(280,100)(-5,4){170}% double bond at 2
           \putlatom{100}{200}{\@memberb}% left or right type
          \else%
     \yl@xdiff=0
     \yl@ydiff=26
           \Put@Line(270,90)(-5,4){170}% single bond at 2
           \putlatom{100}{200}{\@memberb}% left type
   \fi\fi\fi}%
%    \end{macrocode}
% \end{macro}
%
% \subsection{Drawing of inverse chair-form cyclohexanes}
% 
% The standard skeleton of an inverse chair form of cyclohexane is selected 
% to have the following locant numbers. 
%
% \begin{verbatim}
% ***************************
% * cyclohexane derivatives *
% *  (inverse chair type)   *
% ***************************
% The following numbering is adopted in this macro. 
%
%          6            4
%       *      `  5  *
%     1  *  2        *
%              `  3
%
% \end{verbatim}
%
% The macro |\chairi| has an argument |SUBSLIST| as well as an optional 
% argument |BONDLIST|.  
%
% \begin{verbatim}
%   \chairi[BONDLIST]{SUBSLIST}          
% \end{verbatim}
%
% The |BONDLIST| argument contains one or more 
% characters selected from a to f, each of which indicates the presence of 
% an inner (endcyclic) double bond on the corresponding position. 
% \begin{verbatim}
%     BONDLIST = 
%
%           none       :  cyclohexane
%           a          :  1,2-double bond
%           b          :  2,3-double bond
%           c          :  4,3-double bond
%           d          :  4,5-double bond
%           e          :  5,6-double bond
%           f          :  6,1-double bond
% \end{verbatim}
%
% The |SUBSLIST| argument contains one or more substitution descriptors 
% which are separated from each other by a semicolon.  Each substitution 
% descriptor has a locant number with a bond modifier and a substituent, 
% where these are separated with a double equality symbol. 
% \begin{verbatim}
%
%     SUBSLIST: list of substituents (max 8 substitution positions)
%
%       for n = 1 to 6 
%
%           nD         :  exocyclic double bond at n-atom
%           nSa        :  axial single bond at n-atom
%           nSe        :  equatorial single bond at n-atom
%
% \end{verbatim}
%
% Several examples are shown as follows.
%
% \begin{verbatim}
%       e.g. 
%        
%        \chairi[eb]{1D==O;4Se==MeO;4Sa==OMe;5==Cl;6==Cl}
% \end{verbatim}
%
% The definition of |\@chairi| uses a picture environment, in which 
% bonds are put directly, while subsituents are typset by using 
% the macros |\@chairia| to |\@chairif| described above.  
% \changes{v1.02}{1998/10/31}{Adding \cs{ylchairiposition}, \cs{if@ylsw},
% \cs{yl@shifti}, \cs{@ylii}, \cs{yl@shiftii}, \cs{@ylii}, 
% \cs{yl@xdiff} and \cs{yl@ydiff}}
% \changes{v5.00}{2010/10/01}{For bond coloring}
%
% \begin{macro}{\@chairi}
% \begin{macro}{\chairi}
%    \begin{macrocode}
\def\chairi{\@ifnextchar[{\@chairi}{\@chairi[r]}}
\def\@chairi[#1]#2{%
\@reset@ylsw%
\ylchairiposition{#2}%
\def\@@ylii{0}\def\@@yli{0}%
\begin{ShiftPicEnvB}(0,0)(-\yl@shiftii,-\yl@shifti)/%
(1600,800)(-400,-319){chairi}%
(400,319)%2002/4/30 by S. Fujita
% skeletal bonds
   \thinlines%
      \Put@Line(0,0)(3,4){170}%         % bond 1 to 6
      \Put@Line(170,226)(3,-1){403}%    %      6 to 5
      \Put@Line(573,91)(3,1){270}%      %      5 to 4
   {\thicklines%
    \molfronttrue%
      \Put@Line(843,181)(-3,-4){170}%    %      4 to 3
      \Put@Line(673,-46)(-3,1){403}%     %      3 to 2
      \Put@Line(0,0)(3,1){270}%          %      1 to 2
   }%
   \thinlines%
% inner double bonds
\@tfor\member:=#1\do{%
\if\member r%no endcyclic bonds
\else \if\member c%%%a%
       \Put@Line(767,139)(-3,-4){110}%   % double bond 3 to 4
\else \if\member b%%%d%%%b%
      \Put@Line(640,-5)(-3,1){343}%      %             4 to 5
\else \if\member a%%%e%%%%c%
       \Put@Line(240,111)(-3,-1){190}%   %             5 to 6
\else \if\member f%%%d%
      \Put@Line(63,40)(3,4){110}%        %             6 to 7
\else \if\member e%%%l%
      \Put@Line(182,187)(3,-1){343}%     %             7 to 10
\else \if\member d%%%k%%%f%
      \Put@Line(768,131)(-3,-1){170}%    %             10 to 3
\fi\fi\fi\fi\fi\fi\fi}%
% %
\@forsemicol\member:=#2\do{%
\ifx\member\empty\else
\expandafter\@m@mb@r\member;\relax%
\expandafter\threech@r\@membera{}{}%
\ifx\@memberb\@yl\else
\ifcase\@tmpa%0 omit
 \or\setBScolor{\@chairia}% subst. on 1
% \@chairia% subst. on 1
 \or\setBScolor{\@chairib}% subst. on 2
% \@chairib% subst. on 2
 \or\setBScolor{\@chairic}% subst. on 3
% \@chairic% subst. on 3
 \or\setBScolor{\@chairid}% subst. on 4
% \@chairid% subst. on 4
 \or\setBScolor{\@chairie}% subst. on 5
% \@chairie% subst. on 5
 \or\setBScolor{\@chairif}% subst. on 6
% \@chairif% subst. on 6
\fi %end of ifcase
\fi\fi%
}\end{ShiftPicEnvB}}%               %end of \chairi macro
% End of addition 1994/03/05 SF
%    \end{macrocode}
% \end{macro}
% \end{macro}
%
% The command |\ylchairiposition| is to obtain the shift values 
% |\@ylii| and |\@yli| which are used for shifting the standard 
% point of a substituent. 
% \changes{v1.02}{1998/10/23}{New ommands for setting substituents}
%
% \begin{macro}{\ylchairiposition}
%    \begin{macrocode}
\def\ylchairiposition#1{%
\@@ylswfalse%%%\@reset@ylsw
\@forsemicol\member:=#1\do{%
\if@@ylsw\else
\ifx\member\empty\else
\expandafter\@m@mb@r\member;\relax
\expandafter\threech@r\@membera{}{}\relax
\ifx\@memberb\@yl\relax\@@ylswtrue\else\@@ylswfalse\fi
\if@@ylsw
\ifcase\@tmpa%0 omit
 \or\gdef\@ylii{0}\gdef\@yli{0}\global\@ylswtrue% subst. on 1
 \or\gdef\@ylii{-270}\gdef\@yli{-90}\global\@ylswtrue% subst. on 2
 \or\gdef\@ylii{-673}\gdef\@yli{46}\global\@ylswtrue% subst. on 3
 \or\gdef\@ylii{-843}\gdef\@yli{-181}\global\@ylswtrue% subst. on 4
 \or\gdef\@ylii{-573}\gdef\@yli{-91}\global\@ylswtrue% subst. on 5
 \or\gdef\@ylii{-170}\gdef\@yli{-226}\global\@ylswtrue% subst. on 6
\fi%end of ifcase
\fi\fi\fi}}%
%    \end{macrocode}
% \end{macro}
%
% \section{Bicycloheptanes}
% \subsection{Drawing of a flat and vertical type}
%
% The flat-and-vertical-type skeleton of bicycloheptanes is selected 
% to have the following locant numbers. 
%
% \begin{verbatim}
% *************************************
% * bicyclo[2.2.1]heptane derivatives *
% *  (flat, vertical type)            *
% *************************************
% The following numbering is adopted in this macro. 
%
%          1
%          * 
%     6  *   *  2
%       |  7  |
%       |     |
%     5  *   *  3
%          *
%          4 <===== the original point
% \end{verbatim}
%
% The macro |\bicyclohepv| has an argument |SUBSLIST| as well as an optional 
% argument |BONDLIST|.  
%
% \begin{verbatim}
%   \bicychepv[BONDLIST]{SUBSLIST} 
% \end{verbatim}
%
% The |BONDLIST| argument contains one or more 
% characters selected from a to f, each of which indicates the presence of 
% an inner (endcyclic) double bond on the corresponding position. 
% In order to put dimethyl subsitutents on the top position (7), 
% the character `7' is used in the |BONDLIST|.  The delocalization 
% of $\pi$-electron can be described with the character `A' written in 
% the |BONDLIST|. 
% \begin{verbatim}
%
%     BONDLIST = 
%
%           none       :  bicyclo[2.2.1]heptane
%           a          :  1,2-double bond
%           b          :  2,3-double bond
%           c          :  4,3-double bond
%           d          :  4,5-double bond
%           e          :  5,6-double bond
%           f          :  6,1-double bond
%           A          :  aromatic circle 
%           7          :  7,7-dimethyl
% \end{verbatim}
%
% The |SUBSLIST| argument takes the standard format of \XyMTeX{}, in which 
% more substitution descriptors are separated from each other 
% by a semicolon.  
% \begin{verbatim}
%
%     SUBSLIST: list of substituents (max 12 substitution positions)
%
%       for n = 1 to 7 
%
%           nD         :  exocyclic double bond at n-atom
%           n or nS    :  exocyclic single bond at n-atom
%           nA         :  alpha single bond at n-atom
%           nB         :  beta single bond at n-atom
%           nSA        :  alpha single bond at n-atom (boldface)
%           nSB        :  beta single bond at n-atom (dotted line)
%           nSa        :  alpha (not specified) single bond at n-atom
%           nSb        :  beta (not specifed) single bond at n-atom
% \end{verbatim}
%
% Several examples are shown as follows.
%
% \begin{verbatim}
%       e.g. 
%        
%     \bicychepv{1==Cl;2==F}
%     \bicychepv[c]{1==Cl;4==F;2==CH$_{3}$}
%     \bicychepv[eb]{1D==O;4==Me;5==Cl;6==Cl}
% \end{verbatim}
%
% The definition of |\@bicyclohepv| uses a picture environment, in which 
% bonds are put directly, while subsituents are typset by using 
% the macro |\setsixringv| defined in chemstr.sty of \XyMTeX{} system.
% \changes{v1.02}{1998/10/31}{Adding \cs{ylposition}, \cs{if@ylsw},
% \cs{yl@shifti}, \cs{@ylii}, \cs{yl@shiftii}, \cs{@ylii}, 
% \cs{yl@xdiff} and \cs{yl@ydiff}}
%
% \begin{macro}{\@bicyclohepv}
% \begin{macro}{\bicyclohepv}
%    \begin{macrocode}
\def\bicychepv{\@ifnextchar[{\@bicychepv}{\@bicychepv[r]}}
\def\@bicychepv[#1]#2{%
\@reset@ylsw%
\ylposition{#2}{0}{0}{7}{0}%
\begin{ShiftPicEnv}(0,0)(-\yl@shiftii,-\yl@shifti)/%
(800,880)(-400,-240){bicychepv}%
(400,240)%2002/4/30 by S. Fujita
  \Put@Line(0,406)(-5,-3){171}%       %bond 1-6
  \Put@Line(0,406)(5,-3){171}%        %bond 1-2
  \Put@Line(0,0)(-5,3){171}%          %bond 4-5
  \Put@Line(0,0)(5,3){171}%           %bond 4-3
  \Put@Line(171,103)(0,1){200}%       %bond 3-2
  \Put@Line(-171,103)(0,1){200}%      %bond 5-6
{\thicklines%
  \molfronttrue%
  \Put@Line(0,0)(1,4){51}%            %bond 4-7
  \Put@Line(0,406)(1,-4){51}}%         %bond 1-7
\@tfor\member:=#1\do{%
\if\member r%no endcyclic double bonds
\else \if\member a%
  \Put@Line(6,364)(5,-3){126}%        %double bond 1-2
\else \if\member b%
  \Put@Line(138,129)(0,1){148}%       %double bond 3-2
\else \if\member c%
  \Put@Line(6,42)(5,3){126}%          %double bond 4-3
\else \if\member d%
  \Put@Line(-6,42)(-5,3){126}%        %double bond 4-5
\else \if\member e%
  \Put@Line(-138,129)(0,1){148}%      %double bond 5-6
\else \if\member f%
  \Put@Line(-6,364)(-5,-3){126}%      %double bond 1-6
\else \if\member 7%
 {\thicklines%
  \Put@Line(51,204)(-1,0){70}%        %7,7-dimethyl
  \Put@Line(51,204)(1,0){70}}%      
\else \if\member A%aromatic circle 
  \Put@oCircle(0,203){240}%            %circle
\fi\fi\fi\fi\fi\fi\fi\fi\fi}%
% %
\setsixringv{#2}{0}{0}{7}{0}%
\end{ShiftPicEnv}%
}%               %end of \bicychepv macro
%    \end{macrocode}
% \end{macro}
% \end{macro}
%
% \subsection{Drawing of a flat and horizontal type}
%
% The flat-and-horizontal-type skeleton of bicycloheptanes is selected 
% to have the following locant numbers. 
%
% \begin{verbatim}
% *************************************
% * bicyclo[2.2.1]heptane derivatives *
% *  (flat, horizontal type)          *
% *************************************
% The following numbering is adopted in this macro. 
%
%                                2      3
%                                 -----
%                               *       *
%   the original point ===> 1 *     7     * 4
%          (0,0)                *       *
%                                 -----
%                                6      5
% \end{verbatim}
%
% The macro |\bicycloheph| has an argument |SUBSLIST| as well as an optional 
% argument |BONDLIST|.  
%
% \begin{verbatim}
%   \bicycheph[BONDLIST]{SUBSLIST}
% \end{verbatim}
%
% The |BONDLIST| argument contains one or more 
% characters selected from a to f, each of which indicates the presence of 
% an inner (endcyclic) double bond on the corresponding position. 
% In order to put dimethyl subsitutents on the top position (7), 
% the character `7' is used in the |BONDLIST|.  The delocalization 
% of $\pi$-electron can be described with the character `A' written in 
% the |BONDLIST|. 
% \begin{verbatim}
%     BONDLIST = 
%
%           none       :  bicyclo[2.2.1]heptane
%           a          :  1,2-double bond
%           b          :  2,3-double bond
%           c          :  4,3-double bond
%           d          :  4,5-double bond
%           e          :  5,6-double bond
%           f          :  6,1-double bond
%           A          :  aromatic circle 
%           7          :  7,7-dimethyl
% \end{verbatim}
%
% The |SUBSLIST| argument takes the standard format of \XyMTeX{}, in which 
% more substitution descriptors are separated from each other 
% by a semicolon.  
% \begin{verbatim}
%
%     SUBSLIST: list of substituents (max 8 substitution positions)
%
%       for n = 1 to 6 
%
%           nD         :  exocyclic double bond at n-atom
%           n or nS    :  exocyclic single bond at n-atom
%           nA         :  alpha single bond at n-atom
%           nB         :  beta single bond at n-atom
%           nSA        :  alpha single bond at n-atom (boldface)
%           nSB        :  beta single bond at n-atom (dotted line)
%           nSa        :  alpha (not specified) single bond at n-atom
%           nSb        :  beta (not specifed) single bond at n-atom
% \end{verbatim}
%
% Several examples are shown as follows.
%
% \begin{verbatim}
%       e.g. 
%        
%        \bicycheph{1==Cl;2==F}
%        \bicycheph[c]{1==Cl;4==F;2==CH$_{3}$}
%        \bicycheph[eb]{1D==O;4==Me;5==Cl;6==Cl}
% \end{verbatim}
%
% The definition of |\@bicycloheph| uses a picture environment, in which 
% bonds are put directly, while subsituents are typset by using 
% the macro |\setsixringh| defined in chemstr.sty of \XyMTeX{} system.
% \changes{v1.02}{1998/10/31}{Adding \cs{ylpositionh}, \cs{if@ylsw},
% \cs{yl@shifti}, \cs{@ylii}, \cs{yl@shiftii}, \cs{@ylii}, 
% \cs{yl@xdiff} and \cs{yl@ydiff}}
%
% \begin{macro}{\@bicycloheph}
% \begin{macro}{\bicycloheph}
%    \begin{macrocode}
\def\bicycheph{\@ifnextchar[{\@bicycheph}{\@bicycheph[r]}}
\def\@bicycheph[#1]#2{%
\@reset@ylsw%
\ylpositionh{#2}{0}{0}{7}{0}%
\begin{ShiftPicEnv}(0,0)(-\yl@shiftii,-\yl@shifti)/%
(880,800)(-240,-400){bicycheph}%
(240,400)%2002/4/30 by S. Fujita
  \Put@Line(0,0)(3,5){103}%          %bond 1-2
  \Put@Line(0,0)(3,-5){103}%          %bond 1-6
  \Put@Line(406,0)(-3,5){103}%        %bond 4-3
  \Put@Line(406,0)(-3,-5){103}%       %bond 4-3
  \Put@Line(103,171)(1,0){200}%       %bond 2-3
  \Put@Line(103,-171)(1,0){200}%      %bond 6-5
{\thicklines%
  \molfronttrue%
  \Put@Line(0,0)(4,1){203}%            %bond 4-7
  \Put@Line(406,0)(-4,1){203}}%         %bond 1-7
\@tfor\member:=#1\do{%
\if\member r%no endcyclic double bonds
\else \if\member a%
  \Put@Line(42,6)(3,5){78}%           %double bond 1-2
\else \if\member b%
  \Put@Line(129,138)(1,0){148}%       %double bond 2-3
\else \if\member c%
  \Put@Line(364,6)(-3,5){78}%         %double bond 4-3
\else \if\member d%
  \Put@Line(364,-6)(-3,-5){78}%       %double bond 4-5
\else \if\member e%
  \Put@Line(129,-138)(1,0){148}%      %double bond 6-5
\else \if\member f%
  \Put@Line(42,-6)(3,-5){78}%         %double bond 1-6
\else \if\member 7%
 {\thicklines%
  \Put@Line(204,51)(0,-1){70}%        %7,7-dimethyl
  \Put@Line(204,51)(0,1){70}}%      
\else \if\member A%aromatic circle 
  \Put@oCircle(203,0){240}%            %circle
\fi\fi\fi\fi\fi\fi\fi\fi\fi}%
% %
\setsixringh{#2}{0}{0}{7}{0}%
\end{ShiftPicEnv}%
}%               %end of \bicycheph macro
%    \end{macrocode}
% \end{macro}
% \end{macro}
%
% \subsection{Drawing of a stereo type}
%
% \subsubsection{Macros for setting substituents}
% 
% Macros |\@borna| to |\@borng| are used to set substituents 
% on each position of bornane.  
%
% \begin{macro}{\@borna}
% \changes{v1.02}{1998/10/31}{Adding \cs{yl@xdiff} and \cs{yl@ydiff}}
% \changes{v5.01}{2013/06/26}{Adding A, B}
%    \begin{macrocode}
% ***********************************************
% * setting bonds and substituents for bornanes *
% * (bicycloe[2.2.1]heptane derivatives)        *
% ***********************************************
% %%%%%%%%%%%%%%%
% % subst. on 1 %
% %%%%%%%%%%%%%%%
\def\@borna{%
   \if\@tmpb S%single bond
    \ifx\@tmpc\empty%
     \yl@xdiff=8
     \yl@ydiff=3
          \Put@Line(318,247)(2,5){40}%      % single bond 1
           \putratom{350}{360}{\@memberb}%    % right type
    \else\if\@tmpc a%(a) alpha
     \yl@xdiff=8
     \yl@ydiff=3
          \Put@Line(318,247)(2,5){40}%      % single bond 1
           \putratom{350}{360}{\@memberb}%    % right type
    \else\if\@tmpc b%(b) beta
     \yl@xdiff=8
     \yl@ydiff=3
          \Put@Line(318,247)(2,5){40}%      % single bond 1
          \putratom{350}{360}{\@memberb}%     % right type
    \fi\fi\fi%
%2013/04/01
    \else\if\@tmpb U%(U) alpha undefined
      \yl@xdiff=8\relax
      \yl@ydiff=3\relax
           {%
           \WaveBonds%
           \Put@Line(318,247)(2,5){40}%      % wavy bond at 1
           }%
           \putratom{350}{360}{\@memberb}%     % right type
%2013/06/26
    \else\if\@tmpb A%(A) alpha 
      \yl@xdiff=8\relax
      \yl@ydiff=3\relax
          \dotorline(318,247)(2,5){40}/(318,247)(358,347)% 
          \putratom{350}{360}{\@memberb}%     % right type
%2013/06/26
    \else\if\@tmpb B%(B) beta
      \yl@xdiff=8\relax
      \yl@ydiff=3\relax
           {%
           \thicklines%
           \Put@Line(318,247)(2,5){40}%      % wavy bond at 1
           }%
           \putratom{350}{360}{\@memberb}%     % right type
%
   \else%
     \yl@xdiff=8
     \yl@ydiff=3
          \Put@Line(318,247)(2,5){40}%      % single bond 1
           \putratom{350}{360}{\@memberb}%     % right type
   \fi\fi\fi\fi
   }%
%    \end{macrocode}
% \end{macro}
%
% \begin{macro}{\@bornb}
% \changes{v1.02}{1998/10/31}{Adding \cs{yl@xdiff} and \cs{yl@ydiff}}
% \changes{v5.01}{2013/06/26}{Bug fix exchange A and B}
%    \begin{macrocode}
% %%%%%%%%%%%%%%%
% % subst. on 2 %
% %%%%%%%%%%%%%%%
\def\@bornb{%
 \begin{sfpicture}(200,200)(0,0)
   \if\@tmpb S%single bond
    \ifx\@tmpc\empty%
     \yl@xdiff=-10
     \yl@ydiff=20
           \Put@Line(0,0)(5,2){160}% 
           \putratom{170}{44}{\@memberb}%      % left type
    \else\if\@tmpc B%(B) beta%bug fix 2013/06/26
     \yl@xdiff=0
     \yl@ydiff=-5
           {%
           \thicklines%
           \Put@Line(0,0)(4,3){140}%         % endo (a)
           }%
           \putratom{140}{115}{\@memberb}%     % right type
    \else\if\@tmpc A%(A) alpha%bug fix 2013/06/26
     \yl@xdiff=10
     \yl@ydiff=30
       \dotorline(0,0)(5,-2){140}/(0,0)(140,-56)%
       \putratom{150}{-86}{\@memberb}%     % right type
    \else\if\@tmpc a%(a) alpha
     \yl@xdiff=10
     \yl@ydiff=30
           \Put@Line(0,0)(5,-2){140}%        % endo (a)
           \putratom{150}{-86}{\@memberb}%     % right type
    \else\if\@tmpc b%(b) beta
     \yl@xdiff=0
     \yl@ydiff=-10
           \Put@Line(0,0)(4,3){140}%         % exo (b)
           \putratom{140}{115}{\@memberb}%     % right type
    \fi\fi\fi\fi\fi%
   \else \if\@tmpb D%double bond
     \yl@xdiff=-10
     \yl@ydiff=20
           \Put@Line(-10,-15)(5,2){160}% 
           \Put@Line(-5,15)(5,2){160}% 
           \putratom{170}{44}{\@memberb}%      % right type
   \else \if\@tmpb B%beta single bond%bug fix 2013/06/26
     \yl@xdiff=-10
     \yl@ydiff=20
           {%
           \thicklines%
           \Put@Line(0,0)(5,2){160}% 
           }%
           \putratom{170}{44}{\@memberb}%      % right type
   \else \if\@tmpb A%alpha single bond%bug fix 2013/06/26
     \yl@xdiff=-10
     \yl@ydiff=20
       \dotorline(0,0)(5,2){160}/(0,0)(160,64)%
       \putratom{170}{44}{\@memberb}%      % right type
%2013/04/01
    \else\if\@tmpb U%(U) alpha undefined
      \yl@xdiff=-10\relax
      \yl@ydiff=20\relax
           {%
           \WaveBonds%
           \Put@Line(0,0)(5,2){160}% % wavy bond at 2
           }%
           \putratom{170}{44}{\@memberb}%     % left type
%
   \else%
     \yl@xdiff=-10
     \yl@ydiff=20
           \Put@Line(0,0)(5,2){160}% 
           \putratom{170}{44}{\@memberb}%      % right type
   \fi\fi\fi\fi\fi\end{sfpicture}}%
%    \end{macrocode}
% \end{macro}
%
% \begin{macro}{\@bornc}
% \changes{v1.02}{1998/10/31}{Adding \cs{yl@xdiff} and \cs{yl@ydiff}}
% \changes{v5.01}{2013/06/26}{Bug fix exchange A and B}
%    \begin{macrocode}
% %%%%%%%%%%%%%%%
% % subst. on 3 %
% %%%%%%%%%%%%%%%
\def\@bornc{%
 \begin{sfpicture}(200,200)(0,0)
   \if\@tmpb S%single bond
    \ifx\@tmpc\empty%
     \yl@xdiff=-10
     \yl@ydiff=30
           \Put@Line(0,0)(5,-2){140}%
           \putratom{150}{-86}{\@memberb}%    % right type
    \else\if\@tmpc B%(B) beta%bug fix 2013/06/26
     \yl@xdiff=-10
     \yl@ydiff=30
           {%
           \thicklines%
           \Put@Line(0,0)(5,2){140}%        % endo (a)
           }%
           \putratom{150}{26}{\@memberb}%     % right type
    \else\if\@tmpc A%(A) alpha%bug fix 2013/06/26
     \yl@xdiff=0
     \yl@ydiff=40
       \dotorline(0,0)(4,-3){140}/(0,0)(140,-105)%% exo (b)
       \putratom{140}{-145}{\@memberb}%   % right type
    \else\if\@tmpc a%(a) alpha
     \yl@xdiff=0
     \yl@ydiff=40
           \Put@Line(0,0)(4,-3){140}%       % endo (a)
           \putratom{140}{-145}{\@memberb}%   % right type
    \else\if\@tmpc b%(b) beta
     \yl@xdiff=-10
     \yl@ydiff=30
           \Put@Line(0,0)(5,2){140}%        % exo (b)
           \putratom{150}{26}{\@memberb}%     % right type
    \fi\fi\fi\fi\fi
   \else \if\@tmpb D%double bond
     \yl@xdiff=10
     \yl@ydiff=50
           \Put@Line(10,15)(5,-2){160}% 
           \Put@Line(5,-15)(5,-2){160}% 
           \putratom{170}{-124}{\@memberb}%   % right type
   \else \if\@tmpb B%beta single bond%bug fix 2013/06/26
     \yl@xdiff=-10
     \yl@ydiff=30
           {%
           \thicklines%
           \Put@Line(0,0)(5,-2){140}%       % endo (a)
           }%
           \putratom{150}{-86}{\@memberb}%    % right type
   \else \if\@tmpb A%alpha single bond%bug fix 2013/06/26
     \yl@xdiff=-10
     \yl@ydiff=30
       \dotorline(0,0)(5,-2){140}/(0,0)(140,-56)% exo (b)
       \putratom{150}{-86}{\@memberb}%    % right type
%2013/04/01
    \else\if\@tmpb U%(U) alpha undefined
      \yl@xdiff=-10\relax
      \yl@ydiff=20\relax
           {%
           \WaveBonds%
           \Put@Line(0,0)(5,2){160}% % wavy bond at 3
           }%
           \putratom{170}{44}{\@memberb}%     % left type
%
   \else%
     \yl@xdiff=-10
     \yl@ydiff=20
           \Put@Line(0,0)(5,2){160}% 
           \putratom{170}{44}{\@memberb}%     % right type
   \fi\fi\fi\fi\fi%
\end{sfpicture}}%
%    \end{macrocode}
% \end{macro}
%
% \begin{macro}{\@bornd}
% \changes{v1.02}{1998/10/31}{Adding \cs{yl@xdiff} and \cs{yl@ydiff}}
% \changes{v5.01}{2013/06/26}{Adding A, B}
%    \begin{macrocode}
% %%%%%%%%%%%%%%%
% % subst. on 4 %
% %%%%%%%%%%%%%%%
\def\@bornd{%
   \if\@tmpb S%single bond
    \ifx\@tmpc\empty%
     \yl@xdiff=30
     \yl@ydiff=87
          \Put@Line(237,47)(-2,-5){40}%      % single bond 4
          \putlratom{167}{-150}{\@memberb}%    % left & right type
    \else\if\@tmpc a%(a) alpha
     \yl@xdiff=30
     \yl@ydiff=87
          \Put@Line(237,47)(-2,-5){40}%      % single bond 4
          \putlratom{167}{-150}{\@memberb}%    % left & right type
    \else\if\@tmpc b%(b) beta
     \yl@xdiff=30
     \yl@ydiff=87
          \Put@Line(237,47)(-2,-5){40}%      % single bond 4
          \putlratom{167}{-150}{\@memberb}%    % left & right type
    \fi\fi\fi%
%2013/04/01
    \else\if\@tmpb U%(U) alpha, beta undefined
      \yl@xdiff=30\relax
      \yl@ydiff=87\relax
           {%
           \WaveBonds%
          \Put@Line(237,47)(-2,-5){40}%      % single bond 4
           }%
          \putlratom{167}{-150}{\@memberb}%    % left & right type
%2013/06/26
    \else\if\@tmpb A%(A) alpha 
      \yl@xdiff=30\relax
      \yl@ydiff=87\relax
          \dotorline(237,47)(-2,-5){40}/(237,47)(197,-53)% 
          \putlratom{167}{-150}{\@memberb}%    % left & right type
%2013/06/26
    \else\if\@tmpb B%(B) beta
      \yl@xdiff=30\relax
      \yl@ydiff=87\relax
           {%
           \thicklines%
          \Put@Line(237,47)(-2,-5){40}%      % single bond 4
           }%
          \putlratom{167}{-150}{\@memberb}%    % left & right type
%
     \else%
     \yl@xdiff=30
     \yl@ydiff=87
          \Put@Line(237,47)(-2,-5){40}%      % single bond 4
          \putlratom{167}{-150}{\@memberb}%    % left & right type
   \fi\fi\fi\fi%
   }%
%    \end{macrocode}
% \end{macro}
%
% \begin{macro}{\@borne}
% \changes{v1.02}{1998/10/31}{Adding \cs{yl@xdiff} and \cs{yl@ydiff}}
% \changes{v5.01}{2013/06/26}{Bug fix exchange A and B}
%    \begin{macrocode}
% %%%%%%%%%%%%%%%
% % subst. on 5 %
% %%%%%%%%%%%%%%%
\def\@borne{%
 \begin{sfpicture}(200,200)(0,0)
   \if\@tmpb S%single bond
    \ifx\@tmpc\empty%
     \yl@xdiff=10
     \yl@ydiff=30
           \Put@Line(0,0)(-5,-2){140}%
           \putlatom{-150}{-86}{\@memberb}%    % left type
    \else\if\@tmpc B%(B) beta%bug fix 2013/06/26
     \yl@xdiff=10
     \yl@ydiff=30
           {%
           \thicklines%
           \Put@Line(0,0)(-5,2){140}%        % endo (a)
           }%
           \putlatom{-150}{26}{\@memberb}%     % left type
    \else\if\@tmpc A%(A) alpha%bug fix 2013/06/26
     \yl@xdiff=0
     \yl@ydiff=40
       \dotorline(0,0)(-4,-3){140}/(0,0)(-140,-105)%% exo (b)
       \putlatom{-140}{-145}{\@memberb}%   % left type
    \else\if\@tmpc a%(a) alpha
     \yl@xdiff=0
     \yl@ydiff=30
           \Put@Line(0,0)(-4,-3){140}%       % endo (a)
           \putlatom{-140}{-145}{\@memberb}%   % left type
    \else\if\@tmpc b%(b) beta
     \yl@xdiff=10
     \yl@ydiff=30
           \Put@Line(0,0)(-5,2){140}%        % exo (b)
           \putlatom{-150}{26}{\@memberb}%     % left type
    \fi\fi\fi\fi\fi
   \else \if\@tmpb D%double bond
     \yl@xdiff=0
     \yl@ydiff=64
           \Put@Line(-10,15)(-5,-2){160}% 
           \Put@Line(-5,-15)(-5,-2){160}% 
           \putlatom{-170}{-124}{\@memberb}%   % left type
   \else \if\@tmpb B%beta single bond%bug fix 2013/06/26
     \yl@xdiff=10
     \yl@ydiff=30
           {%
           \thicklines%
           \Put@Line(0,0)(-5,-2){140}%       % endo (a)
           }%
           \putlatom{-150}{-86}{\@memberb}%    % left type
   \else \if\@tmpb A%alpha single bond%bug fix 2013/06/26
     \yl@xdiff=10
     \yl@ydiff=30
       \dotorline(0,0)(-5,-2){140}/(0,0)(-140,-56)%% exo (b)
       \putlatom{-150}{-86}{\@memberb}%    % left type
%2013/04/01
    \else\if\@tmpb U%(U) alpha undefined
      \yl@xdiff=10\relax
      \yl@ydiff=20\relax
           {%
           \WaveBonds%
           \Put@Line(0,0)(-5,2){160}%  wavy bond at 5
           }%
           \putlatom{-170}{44}{\@memberb}%     % left type
%
   \else%
     \yl@xdiff=10
     \yl@ydiff=20
           \Put@Line(0,0)(-5,2){160}% 
           \putlatom{-170}{44}{\@memberb}%     % left type
   \fi\fi\fi\fi\fi%
\end{sfpicture}}%
%    \end{macrocode}
% \end{macro}
%
% \begin{macro}{\@bornf}
% \changes{v1.02}{1998/10/31}{Adding \cs{yl@xdiff} and \cs{yl@ydiff}}
% \changes{v5.01}{2013/06/26}{Bug fix exchange A and B}
%    \begin{macrocode}
% %%%%%%%%%%%%%%%
% % subst. on 6 %
% %%%%%%%%%%%%%%%
\def\@bornf{%
 \begin{sfpicture}(200,200)(0,0)
   \if\@tmpb S%single bond
    \ifx\@tmpc\empty%
     \yl@xdiff=10
     \yl@ydiff=30
           \Put@Line(0,0)(-5,2){160}% 
           \putlatom{-170}{44}{\@memberb}%      % left type
    \else\if\@tmpc B%(B) beta%bug fix 2013/06/26
     \yl@xdiff=10
     \yl@ydiff=-10
           {%
           \thicklines%
           \Put@Line(0,0)(-4,3){140}%         % endo (a)
           }%
           \putlatom{-140}{115}{\@memberb}%     % left type
    \else\if\@tmpc A%(A) alpha%bug fix 2013/06/26
     \yl@xdiff=0
     \yl@ydiff=30
       \dotorline(0,0)(-5,-2){140}/(0,0)(-140,-56)%% exo (b)
       \putlatom{-150}{-86}{\@memberb}%     % left type
    \else\if\@tmpc a%(a) alpha
     \yl@xdiff=10
     \yl@ydiff=30
           \Put@Line(0,0)(-5,-2){140}%        % endo (a)
           \putlatom{-150}{-86}{\@memberb}%     % left type
    \else\if\@tmpc b%(b) beta
     \yl@xdiff=0
     \yl@ydiff=-10
           \Put@Line(0,0)(-4,3){140}%         % exo (b)
           \putlatom{-140}{115}{\@memberb}%     % left type
    \fi\fi\fi\fi\fi%
   \else \if\@tmpb D%double bond
     \yl@xdiff=0
     \yl@ydiff=20
           \Put@Line(10,-15)(-5,2){160}% 
           \Put@Line(5,15)(-5,2){160}% 
           \putlatom{-170}{44}{\@memberb}%      % left type
   \else \if\@tmpb B%beta single bond%bug fix 2013/06/26
     \yl@xdiff=10
     \yl@ydiff=30
           {%
           \thicklines%
           \Put@Line(0,0)(-5,2){160}% 
           }%
           \putlatom{-170}{44}{\@memberb}%      % left type
   \else \if\@tmpb A%alpha single bond%bug fix 2013/06/26
     \yl@xdiff=10
     \yl@ydiff=30
       \dotorline(0,0)(-5,2){160}/(0,0)(-160,64)%
       \putlatom{-170}{44}{\@memberb}%      % left type
%2013/04/01
    \else\if\@tmpb U%(U) alpha undefined
      \yl@xdiff=10\relax
      \yl@ydiff=20\relax
           {%
           \WaveBonds%
           \Put@Line(0,0)(-5,2){160}%  wavy bond at 6
           }%
           \putlatom{-170}{44}{\@memberb}%     % left type
%
   \else%
     \yl@xdiff=10
     \yl@ydiff=20
           \Put@Line(0,0)(-5,2){160}% 
           \putlatom{-170}{44}{\@memberb}%      % left type
   \fi\fi\fi\fi\fi\end{sfpicture}}%
%    \end{macrocode}
% \end{macro}
%
% \begin{macro}{\@borng}
% \changes{v1.02}{1998/10/31}{Adding \cs{yl@xdiff} and \cs{yl@ydiff}}
% \changes{v5.01}{2013/06/26}{Adding SU, SV, SA, SB, Su, Sd}
%    \begin{macrocode}
% %%%%%%%%%%%%%%%
% % subst. on 7 %
% %%%%%%%%%%%%%%%
\def\@borng{%
 \begin{sfpicture}(200,200)(0,0)
   \if\@tmpb S%single bond
    \ifx\@tmpc\empty%
     \yl@xdiff=40
     \yl@ydiff=-20
           \Put@Line(0,0)(0,1){160}% 
           \putlratom{-40}{180}{\@memberb}%      % left & right type
    \else\if\@tmpc a%(a) left
     \yl@xdiff=0
     \yl@ydiff=-10
           \Put@Line(0,0)(-4,3){140}%          % left (a)
           \putlatom{-140}{115}{\@memberb}%      % left type
    \else\if\@tmpc b%(b) right
     \yl@xdiff=0
     \yl@ydiff=-10
           \Put@Line(0,0)(4,3){140}%           % right (b)
           \putratom{140}{115}{\@memberb}%       % right type
%2013/06/25
    \else\if\@tmpc U%(U) alpha undefined
      \yl@xdiff=0\relax
      \yl@ydiff=-10\relax
           {%
           \WaveBonds%
           \Put@Line(0,0)(-4,3){140}%          % left (U)
           }%
           \putlatom{-140}{115}{\@memberb}%      % left type
%2013/06/25
    \else\if\@tmpc V%(V) beta undefined
      \yl@xdiff=0\relax
      \yl@ydiff=-10\relax
           {%
           \WaveBonds%
           \Put@Line(0,0)(4,3){140}%           % right (V)
           }%
           \putratom{140}{115}{\@memberb}%       % right type
%2013/06/26
    \else\if\@tmpc A%(A) alpha 
      \yl@xdiff=0\relax
      \yl@ydiff=-10\relax
           \dotorline(0,0)(-4,3){140}/(0,0)(-140,105)% 
           \putlatom{-140}{115}{\@memberb}%      % left type
%2013/06/26
    \else\if\@tmpc B%(B) beta
      \yl@xdiff=0\relax
      \yl@ydiff=-10\relax
           {%
           \thicklines%
           \Put@Line(0,0)(4,3){140}%           % 
           }%
           \putratom{140}{115}{\@memberb}%       % right type
%2013/06/26
    \else\if\@tmpc u%(u) beta alternative
      \yl@xdiff=0\relax
      \yl@ydiff=-10\relax
           {%
           \thicklines%
           \Put@Line(0,0)(-4,3){140}%           % 
           }%
           \putlatom{-140}{115}{\@memberb}%       % left type
%2013/06/26
    \else\if\@tmpc d%(d) alpha alternative
      \yl@xdiff=0\relax
      \yl@ydiff=-10\relax
           \dotorline(0,0)(4,3){140}/(0,0)(140,105)% 
           \putratom{140}{115}{\@memberb}%      % right type
%
    \fi\fi\fi\fi\fi\fi\fi\fi\fi
    %\fi\fi%
   \else \if\@tmpb D%double bond
     \yl@xdiff=40
     \yl@ydiff=-20
           \Put@Line(-10,0)(0,1){160}% 
           \Put@Line(10,0)(0,1){160}% 
           \putlratom{-40}{180}{\@memberb}%      % left & right type
   \else%
     \yl@xdiff=40
     \yl@ydiff=-20
           \Put@Line(0,0)(0,1){160}% 
           \putlratom{-40}{180}{\@memberb}%      % left & right type
   \fi\fi\end{sfpicture}}%
%    \end{macrocode}
% \end{macro}
%
% \subsubsection{Drawing of borane derivatives}
% 
% The stereo-type skeleton of bicycloheptanes is selected 
% to have the following locant numbers. 
%
% \begin{verbatim}
% ***********************************************
% * bornane derivatives                         *
% * (bicycloe[2.2.1]heptane derivatives)        *
% ***********************************************
% The following numbering is adopted in this macro. 
%
%                7   g
%           f    / `
%            _  / - 1_ a
%     e    6  / h     - 2
%       *    /        *
%     5  -  4       * b
%        d     c` 3
%
% \end{verbatim}
%
% The macro |\bornane| has an argument |SUBSLIST| as well as an optional 
% argument |BONDLIST|.  
%
% \begin{verbatim}
%   \bornane[BONDLIST]{SUBSLIST}          
% \end{verbatim}
%
% The |BONDLIST| argument contains one or more 
% characters selected from a to h, each of which indicates the presence of 
% an inner (endcyclic) double bond on the corresponding position. 
% \begin{verbatim}
%
%     BONDLIST = 
%
%           none       :  bicyclo[2.2.1]heptane
%           a          :  1,2-double bond
%           b          :  2,3-double bond
%           c          :  4,3-double bond
%           d          :  4,5-double bond
%           e          :  5,6-double bond
%           f          :  6,1-double bond
%           g          :  1,7-double bond
%           h          :  4,7-double bond
% \end{verbatim}
%
% The |SUBSLIST| argument takes the standard format of \XyMTeX{}, in which 
% more substitution descriptors are separated from each other 
% by a semicolon.  
% \begin{verbatim}
%
%     SUBSLIST: list of substituents (max 7 substitution positions)
%
%       for n = 1 to 6
%
%           nD         :  exocyclic double bond at n-atom
%           n or nS    :  exocyclic single bond at n-atom
%           nA         :  alpha single bond at n-atom
%           nB         :  beta single bond at n-atom
%           nSA        :  alpha single bond at n-atom (boldface)
%           nSB        :  beta single bond at n-atom (dotted line)
%           nSa        :  alpha single bond at n-atom
%           nSb        :  beta single bond at n-atom
% \end{verbatim}
% 
% The 7-position of a bornane skeleton cannot be specified by 
% capital characters `A' and `B'.  
% \begin{verbatim}
%       for n = 7 (bridge position)
%
%           nD         :  exocyclic double bond at 7-atom
%           n or nS    :  exocyclic single bond at 7-atom
%           nSa        :  left single bond at 7-atom
%           nSb        :  right single bond at 7-atom
%
% \end{verbatim}
%
% Several examples are shown as follows.
%
% \begin{verbatim}
%       e.g. 
%        
%        \bornane{1==N}{1==Cl;2==F}
%        \bornane[c]{1==N}{1==Cl;4==F;2==CH$_{3}$}
%        \bornane[eb]{1==N}{1D==O;4==MeO;5==Cl;6==Cl}
% \end{verbatim}
%
% The definition of |\@bicycloheph| uses a picture environment, in which 
% bonds are put directly, while subsituents are typset by using 
% the macro |\@borna| to |\@borng| defined in chemstr.sty of \XyMTeX{} 
% system.
%
% \changes{v1.01b}{1998/10/08}{The drawing are of \cs{bornane} 
% has been changed by SF.}
% \changes{v1.02}{1998/10/31}{Adding \cs{ylbornaneposition}, \cs{if@ylsw},
% \cs{yl@shifti}, \cs{@ylii}, \cs{yl@shiftii}, \cs{@ylii}, 
% \cs{yl@xdiff} and \cs{yl@ydiff}}
% \changes{v5.00}{2010/10/01}{For bond coloring}
% \changes{v5.01}{2013/06/24}{bornane front-to-back crossing}
%
% \begin{macro}{\@bornane}
% \begin{macro}{\iffrontthicktothin}
% \begin{macro}{\bornane}
%    \begin{macrocode}
\def\BackGroundColor{\color{white}}%default color for background 2013/07/23
\newif\iffrontthicktothin \frontthicktothinfalse%default front thickline2013/06/24
\def\bornane{\@ifnextchar[{\@bornane}{\@bornane[r]}}
\def\@bornane[#1]#2{%
\@reset@ylsw%
\ylbornaneposition{#2}%
\def\@@ylii{0}\def\@@yli{0}%
\begin{ShiftPicEnvB}(0,0)(-\yl@shiftii,-\yl@shifti)/%
(1000,1000)(-200,-240){bornane}%
(200,240)%2002/4/30 by S. Fujita
% skeletal bonds
 \thinlines%
  \Put@Line(462,-43)(2,5){80}%         % bond 3 to 2 (b)
  \Put@Line(543,157)(-5,2){225}%       % bond 2 to 1 (a)
  \Put@Line(318,247)(-5,-1){237}%      % bond 1 to 6 (f)
  \Put@Line(80,200)(-2,-5){80}%        % bond 6 to 5 (e)
  \Put@Line(318,247)(-2,5){80}%        % back part of bridge (g)
 {\iffrontthicktothin\thinlines\else\thicklines\fi%2013/06/24
  \molfronttrue
  \Put@Line(0,0)(5,1){237}%            % bond 5 to 4 (d)
  \Put@Line(237,47)(5,-2){225}%        % bond 4 to 3 (c)
  {\def\thinLineWidth{5pt}\BackGroundColor% front-to-back crossing2013/06/24-07/23
  \thinlines%                          %
  \Put@Line(237,200)(0,1){80}}%        % front-to-back crossing2013/06/24-07/23
  \Put@Line(237,47)(0,1){400}%         % front part of bridge (h)
 }%
% inner double bond
\@tfor\member:=#1\do{%
\if\member r%no endcyclic bonds
\else \if\member a%%%%
   \Put@Line(513,127)(-5,2){180}%       % bond 2 to 1
\else \if\member b%%%%
   \Put@Line(446,-3)(2,5){60}%          % bond 3 to 2
\else \if\member c%%%%
   \Put@Line(267,77)(5,-2){180}%        % bond 4 to 3
\else \if\member d%%%%
   \Put@Line(40,42)(5,1){180}%          % double bond 5 to 4
\else \if\member e%%%
   \Put@Line(100,180)(-2,-5){60}%       % bond 6 to 5
\else \if\member f%
   \Put@Line(288,207)(-5,-1){180}%      % bond 1 to 6
\else \if\member g%
  \Put@Line(288,260)(-2,5){40}%         % back part of bridge (g)
\else \if\member h%
  \Put@Line(257,77)(0,1){290}%          % front part of bridge (h)
\fi\fi\fi\fi\fi\fi\fi\fi\fi}%
%
\@forsemicol\member:=#2\do{%
\ifx\member\empty\else
\expandafter\@m@mb@r\member;\relax%
\expandafter\threech@r\@membera{}{}%
\ifx\@memberb\@yl\else
\ifcase\@tmpa%0 omit
 \or\setBScolor{\@borna}% subst. on 1
% \@borna% subst. on 1
 \or\setBScolor{\Put@Direct(543,157){\@bornb}}% subst. on 2
% \Put@Direct(543,157){\@bornb}% subst. on 2
 \or\setBScolor{\Put@Direct(462,-43){\@bornc}}% subst. on 3
% \Put@Direct(462,-43){\@bornc}% subst. on 3
 \or\setBScolor{\@bornd}% subst. on 4
% \@bornd% subst. on 4
 \or\setBScolor{\Put@Direct(0,0){\@borne}}% subst. on 5
% \Put@Direct(0,0){\@borne}% subst. on 5
 \or\setBScolor{\Put@Direct(80,200){\@bornf}}% subst. on 6
% \Put@Direct(80,200){\@bornf}% subst. on 6
 \or\setBScolor{\Put@Direct(237,440){\@borng}}% subst. on 7
% \Put@Direct(237,440){\@borng}% subst. on 7
\fi%end of ifcase
\fi\fi%
}%
\end{ShiftPicEnvB}%
\iniatom\iniflag}%     %end of \bornane macro
%    \end{macrocode}
% \end{macro}
% \end{macro}
% \end{macro}
%
% The command |\ylbornaneposition| is to obtain the shift values 
% |\@ylii| and |\@yli| which are used for shifting the standard 
% point of a substituent. 
% \changes{v1.02}{1998/10/23}{New ommands for setting substituents}
%
% \begin{macro}{\ylbornaneposition}
%    \begin{macrocode}
\def\ylbornaneposition#1{%
\@@ylswfalse%%%\@reset@ylsw
\@forsemicol\member:=#1\do{%
\if@@ylsw\else
\ifx\member\empty\else
\expandafter\@m@mb@r\member;\relax
\expandafter\threech@r\@membera{}{}\relax
\ifx\@memberb\@yl\relax\@@ylswtrue\else\@@ylswfalse\fi
\if@@ylsw
\ifcase\@tmpa%0 omit
 \or\gdef\@ylii{-318}\gdef\@yli{-247}\global\@ylswtrue% subst. on 1
 \or\gdef\@ylii{-543}\gdef\@yli{-157}\global\@ylswtrue% subst. on 2
 \or\gdef\@ylii{-462}\gdef\@yli{43}\global\@ylswtrue% subst. on 3
 \or\gdef\@ylii{-237}\gdef\@yli{-47}\global\@ylswtrue% subst. on 4
 \or\gdef\@ylii{0}\gdef\@yli{0}\global\@ylswtrue% subst. on 5
 \or\gdef\@ylii{-80}\gdef\@yli{-200}\global\@ylswtrue% subst. on 6
 \or\gdef\@ylii{-237}\gdef\@yli{-440}\global\@ylswtrue% subst. on 7
\fi%end of ifcase
\fi\fi\fi}}%
%    \end{macrocode}
% \end{macro}
%
% \section{Adamantanes}
%
% \subsection{Vertical drawing}
% 
% The macros |\@adamanea| to |\@adamanej| are used to 
% set substituents on each edge of an adamantane skeleton 
% drawn by the |\adamantane| commands. 
% \changes{v1.02}{1998/10/24}{The macros \cs{@adamanea} to \cs{@adamanej} 
% are separated from the original definition of \cs{adamantane}.}
%
% \begin{macro}{\@adamanea}
% \begin{macro}{\@adamaneb}
% \begin{macro}{\@adamanec}
% \begin{macro}{\@adamaned}
% \begin{macro}{\@adamanee}
% \begin{macro}{\@adamanef}
% \begin{macro}{\@adamaneg}
% \begin{macro}{\@adamaneh}
% \begin{macro}{\@adamanei}
% \begin{macro}{\@adamanej}
% \changes{v1.02}{1998/10/24}{A new command for setting substituents}
%    \begin{macrocode}
% %%%%%%%%%%%%%%%
% % subst. on 1 %
% %%%%%%%%%%%%%%%
\def\@adamanea{%
     \yl@xdiff=12
     \yl@ydiff=21
   \Put@Direct(-360,720){\hbox to0pt{\hss \@memberb}}%     %atom 1
 \if\@tmpb a%
   \Put@Line(-240,660)(-4,3){108}%                %bond 1
  \else \ifx\@tmpb\empty%
   \Put@Line(-240,660)(-4,3){108}%                %bond 1
 \fi\fi}% 
%    \end{macrocode}
%
% \changes{v1.02}{1998/10/24}{A new command for setting substituents}
%    \begin{macrocode}
% %%%%%%%%%%%%%%%
% % subst. on 2 %
% %%%%%%%%%%%%%%%
\def\@adamaneb{%
  \if\@tmpb a%
     \yl@xdiff=6
     \yl@ydiff=-16
   \Put@Line(0,780)(1,4){26}%                     %bond 2-ax
   \Put@Direct(20,900){\hbox to0pt{\@memberb \hss}}%       %atom 2-ax
  \else \if\@tmpb b%
     \yl@xdiff=-6
     \yl@ydiff=-16
   \Put@Line(0,780)(-1,4){26}%                    %bond 2-eq
   \Put@Direct(-20,900){\hbox to0pt{\hss \@memberb}}%      %atom 2-eq
  \else \ifx\@tmpb\empty%
     \yl@xdiff=42
     \yl@ydiff=-22
   \Put@Direct(-42,910){\hbox to0pt{\hss \@memberb}}%      %atom 2
   \Put@Line(0,780)(0,1){108}%                    %bond 2
  \else \if\@tmpb D%
     \yl@xdiff=42
     \yl@ydiff=-22
   \putlratom{-42}{910}{\@memberb}%                 %atom 2
   \Put@Line(-12,780)(0,1){108}%                  %double bond 2
   \Put@Line(12,780)(0,1){108}%                   %double bond 2
 \fi\fi\fi\fi}
%    \end{macrocode}
%
% \changes{v1.02}{1998/10/24}{A new command for setting substituents}
%    \begin{macrocode}
% %%%%%%%%%%%%%%%
% % subst. on 3 %
% %%%%%%%%%%%%%%%
\def\@adamanec{%
     \yl@xdiff=-12
     \yl@ydiff=21
   \Put@Direct(360,720){\hbox to0pt{\@memberb \hss}}%      %atom 3
%  \if\@tmpb S%
  \if\@tmpb a%1998/10/24 by SF
   \Put@Line(240,660)(4,3){108}%                  %bond 3
  \else \ifx\@tmpb\empty%
   \Put@Line(240,660)(4,3){108}%                  %bond 3
 \fi\fi}
%    \end{macrocode}
%
% \changes{v1.02}{1998/10/24}{A new command for setting substituents}
%    \begin{macrocode}
% %%%%%%%%%%%%%%%
% % subst. on 4 %
% %%%%%%%%%%%%%%%
\def\@adamaned{%
  \if\@tmpb a%
     \yl@xdiff=-17
     \yl@ydiff=33
   \Put@Line(300,420)(4,-3){103}%                 %bond 4-ax
   \Put@Direct(420,310){\hbox to0pt{\@memberb \hss}}%      %atom 4-ax
  \else \if\@tmpb b%
     \yl@xdiff=26
     \yl@ydiff=-26
   \Put@Line(300,420)(1,4){26}%                   %bond 4-eq
   \Put@Direct(300,540){\hbox to0pt{\@memberb \hss}}%      %atom 4-eq
  \else \ifx\@tmpb\empty%
     \yl@xdiff=-17
     \yl@ydiff=33
   \Put@Line(300,420)(4,-3){103}%                 %bond 4
   \Put@Direct(420,310){\hbox to0pt{\@memberb \hss}}%      %atom 4
  \else \if\@tmpb D%
     \yl@xdiff=-17
     \yl@ydiff=33
   \Put@Line(296,432)(5,-3){103}%                 %double bond 4
   \Put@Line(292,408)(5,-3){103}%                 %double bond 4
   \Put@Direct(420,310){\hbox to0pt{\@memberb \hss}}%      %atom 4
  \fi\fi\fi\fi}
%    \end{macrocode}
%
% \changes{v1.02}{1998/10/24}{A new command for setting substituents}
%    \begin{macrocode}
% %%%%%%%%%%%%%%%
% % subst. on 5 %
% %%%%%%%%%%%%%%%
\def\@adamanee{%
     \yl@xdiff=20
     \yl@ydiff=110
%  \if\@tmpb S%
  \if\@tmpb a%1998/10/24 by SF
   \Put@Line(60,240)(1,-5){30}%                   %bond 5
   \Put@Direct(70,-20){\hbox to0pt{\@memberb  \hss}}%      %atom 5
  \else \ifx\@tmpb\empty%
   \Put@Line(60,240)(1,-5){30}%                   %bond 5
   \Put@Direct(70,-20){\hbox to0pt{\@memberb  \hss}}%      %atom 5
  \fi\fi}
%    \end{macrocode}
%
% \changes{v1.02}{1998/10/24}{A new command for setting substituents}
%    \begin{macrocode}
% %%%%%%%%%%%%%%%
% % subst. on 6 %
% %%%%%%%%%%%%%%%
\def\@adamanef{%
  \if\@tmpb a%
     \yl@xdiff=33
     \yl@ydiff=103
   \Put@Line(0,0)(4,-3){103}%                     %bond 6-ax
   \Put@Direct(70,-180){\hbox to0pt{\@memberb \hss}}%      %atom 6-ax
  \else \if\@tmpb b%
     \yl@xdiff=-33
     \yl@ydiff=103
   \Put@Line(0,0)(-4,-3){103}%                    %bond 6-eq
   \Put@Direct(-70,-180){\hbox to0pt{\hss \@memberb}}%     %atom 6-eq
  \else \ifx\@tmpb\empty%
     \yl@xdiff=22
     \yl@ydiff=94
   \Put@Line(0,0)(0,-1){108}%                     %bond 6
   \Put@Direct(-22,-202){\hbox to0pt{\hss \@memberb}}%     %atom 6
  \else \if\@tmpb D%
     \yl@xdiff=42
     \yl@ydiff=94
   \Put@Line(-12,0)(0,-1){108}%                   %double bond 6
   \Put@Line(12,0)(0,-1){108}%                    %double bond 6
   \putlratom{-42}{-202}{\@memberb}%                %atom 6
 \fi\fi\fi\fi}
%    \end{macrocode}
%
% \changes{v1.02}{1998/10/24}{A new command for setting substituents}
%    \begin{macrocode}
% %%%%%%%%%%%%%%%
% % subst. on 7 %
% %%%%%%%%%%%%%%%
\def\@adamaneg{%
     \yl@xdiff=-20
     \yl@ydiff=110
%  \if\@tmpb S%
  \if\@tmpb a%1998/10/24 by SF
   \Put@Line(-60,240)(-1,-5){30}%                 %bond 7
   \Put@Direct(-70,-20){\hbox to0pt{\hss \@memberb}}%      %atom 7
  \else \ifx\@tmpb\empty%
   \Put@Line(-60,240)(-1,-5){30}%                 %bond 7
   \Put@Direct(-70,-20){\hbox to0pt{\hss \@memberb}}%      %atom 7-eq
  \fi\fi}
%    \end{macrocode}
%
% \changes{v1.02}{1998/10/24}{A new command for setting substituents}
%    \begin{macrocode}
% %%%%%%%%%%%%%%%
% % subst. on 8 %
% %%%%%%%%%%%%%%%
\def\@adamaneh{%
  \if\@tmpb a%
     \yl@xdiff=17
     \yl@ydiff=33
   \Put@Line(-300,420)(-4,-3){103}%               %bond 8-ax
   \Put@Direct(-420,310){\hbox to0pt{\hss \@memberb}}%     %atom 8-ax
  \else \if\@tmpb b%
     \yl@xdiff=-26
     \yl@ydiff=-16
   \Put@Line(-300,420)(-1,4){26}%                 %bond 8-eq
   \Put@Direct(-300,540){\hbox to0pt{\hss \@memberb}}%     %atom 8-eq
  \else \ifx\@tmpb\empty%
     \yl@xdiff=17
     \yl@ydiff=33
   \Put@Line(-300,420)(-4,-3){103}%               %bond 8
   \Put@Direct(-420,310){\hbox to0pt{\hss \@memberb}}%     %atom 8
  \else \if\@tmpb D%
     \yl@xdiff=17
     \yl@ydiff=50
   \Put@Line(-300,432)(-5,-3){103}%               %double bond 8
   \Put@Line(-303,408)(-5,-3){103}%               %double bond 8
   \Put@Direct(-420,310){\hbox to0pt{\hss \@memberb}}%     %atom 8
  \fi\fi\fi\fi}
%    \end{macrocode}
%
% \changes{v1.02}{1998/10/24}{A new command for setting substituents}
%    \begin{macrocode}
% %%%%%%%%%%%%%%%
% % subst. on 9 %
% %%%%%%%%%%%%%%%
\def\@adamanei{%
  \if\@tmpb a%
     \yl@xdiff=-43
     \yl@ydiff=93
   \Put@Line(-180,420)(-4,-3){103}%               %bond 9-ax
   \Put@Direct(-240,250){\hbox to0pt{\hss \@memberb}}%     %atom 9-ax
  \else \if\@tmpb b%
     \yl@xdiff=26
     \yl@ydiff=-16
   \Put@Line(-180,420)(1,4){26}%                  %bond 9-eq
   \Put@Direct(-180,540){\hbox to0pt{\@memberb \hss}}%     %atom 9-eq
  \else \ifx\@tmpb\empty%
     \yl@xdiff=17
     \yl@ydiff=93
   \Put@Line(-180,420)(-4,-3){103}%               %bond 9
   \Put@Direct(-300,250){\hbox to0pt{\hss \@memberb}}%     %atom 9
  \else \if\@tmpb D%
     \yl@xdiff=17
     \yl@ydiff=113
   \Put@Line(-183,432)(-5,-3){103}%               %double bond 9
   \Put@Line(-180,408)(-5,-3){103}%               %double bond 9
   \Put@Direct(-300,250){\hbox to0pt{\hss \@memberb}}%     %atom 9
  \fi\fi\fi\fi}
%    \end{macrocode}
%
% \changes{v1.02}{1998/10/24}{A new command for setting substituents}
%    \begin{macrocode}
% %%%%%%%%%%%%%%%%
% % subst. on 10 %
% %%%%%%%%%%%%%%%%
\def\@adamanej{%
  \if\@tmpb a%
     \yl@xdiff=43
     \yl@ydiff=92
  \Put@Line(180,420)(4,-3){103}%                 %bond 10-ax
  \Put@Direct(240,250){\hbox to0pt{\@memberb  \hss}}%     %atom 10-ax
  \else \if\@tmpb b%
     \yl@xdiff=-26
     \yl@ydiff=-16
  \Put@Line(180,420)(-1,4){26}%                  %bond 10-eq
  \Put@Direct(180,540){\hbox to0pt{\hss \@memberb}}%      %atom 10-eq
  \else \ifx\@tmpb\empty%
     \yl@xdiff=43
     \yl@ydiff=92
   \Put@Line(180,420)(4,-3){103}%                %bond 10
   \Put@Direct(240,250){\hbox to0pt{\@memberb \hss}}%     %atom 10
  \else \if\@tmpb D%
     \yl@xdiff=3
     \yl@ydiff=112
   \Put@Line(176,432)(5,-3){103}%                %double bond 10
   \Put@Line(172,408)(5,-3){103}%                %double bond 10
   \Put@Direct(280,250){\hbox to0pt{\@memberb \hss}}%     %atom 10
  \fi\fi\fi\fi}
%    \end{macrocode}
% \end{macro}
% \end{macro}
% \end{macro}
% \end{macro}
% \end{macro}
% \end{macro}
% \end{macro}
% \end{macro}
% \end{macro}
% \end{macro}
%
% The stereo-type skeleton of adamantane is selected 
% to have the following specification.  The |\adamantane| 
% command prints a vertical-type  formula in which two bridge carbons 
% are placed at the top and the bottom. 
%
% \begin{verbatim}
% *************************************************
% * For preparing adamantane derivatives          *
% *   with 4 substituents on bridgehead positions *
% *         (1, 3, 5 and 7)                       *
% *   with 12 substituents on bridge positions    *
% *         (2, 4, 6, 8, 9, 10)                   *
% *************************************************
% \end{verbatim}
%
% The macro |\adamantane| has an argument |SUBSLIST| as well as an optional 
% argument |BONDLIST|.  
%
% \begin{verbatim}
%   \adamantane[BONDLIST]{SUBSLIST}          
% \end{verbatim}
%
% The adamantane skeleton scarcely takes an inner (endcyclic) double bond.
% Hence we have 
% \begin{verbatim}
%     BONDLIST: not effective
% \end{verbatim}
%
% The |SUBSLIST| argument takes the standard format of \XyMTeX{}, in which 
% more substitution descriptors are separated from each other 
% by a semicolon.  
% \begin{verbatim}
%
%     SUBSLIST: list of substituents (max 10 substitution positions)
%
%       for n = 1, 3, 5, and 7 (bridgeheads)
%
%           n or na    :  exocyclic single bond at n-atom
%
%       for n = 2, 4, 6, 8, 9, and 10 (bridges)
%
%           na         :  exocyclic single bond at n-atom (axial)
%           nb         :  exocyclic single bond at n-atom (equatorial)
%           nD         :  exocyclic double bond at n-atom (2 and 6)
%
% \end{verbatim}
% 
% For numbers larger than 9 (two digits), you should designate
% the |SUBSLIST| as, e.g., 
% \begin{verbatim}
%             {{10}a}==Cl; ...
% \end{verbatim}
%
% The definition of |\@adamantane| uses a picture environment, in which 
% both bonds are substituents are put directly. 
% \changes{v1.02}{1998/10/31}{Adding \cs{yladamanposition}, \cs{if@ylsw},
% \cs{yl@shifti}, \cs{@ylii}, \cs{yl@shiftii}, \cs{@ylii}, 
% \cs{yl@xdiff} and \cs{yl@ydiff}}
% \changes{v5.00}{2010/10/01}{For bond coloring}
% \changes{v5.01}{2013/06/24}{adamantane front-to-back crossing}
%
% \begin{macro}{\@adamantane}
% \begin{macro}{\adamantane}
%    \begin{macrocode}
% \changes{v1.02}{1998/10/24}{The macros \cs{@adamanea} to \cs{@adamanej} 
% are separated from the original definition of \cs{adamantane}.}
\def\adamantane{\@ifnextchar[{\@mantane}{\@damantane[Z]}}
\def\@damantane[#1]#2{%
\@reset@ylsw%
\yladamanposition{#2}%
\def\@@ylii{0}\def\@@yli{0}%
\begin{ShiftPicEnvB}(0,0)(-\yl@shiftii,-\yl@shifti)/%
(1100,1300)(-550,-300){adamantane}%
(550,300)%2002/4/30 by S. Fujita
%bonds for an adamantane skeleton
  \Put@Line(0,0)(-1,4){60}%                      %bond 6-7
  \Put@Line(0,780)(2,-1){240}%                   %bond 2-3
  \Put@Line(0,780)(-2,-1){240}%                  %bond 2-1
  \Put@Line(-60,240)(-4,3){240}%                 %bond 7-8
  \Put@Line(-300,420)(1,4){60}%                  %bond 8-1
  \Put@Line(240,660)(-1,-4){60}%                 %bond 3-10
  \Put@Line(-60,240)(4,3){240}%                  %bond 10-7
{\iffrontthicktothin\thinlines\else\thicklines\fi%2013/06/24
  \molfronttrue%added for v4.02 (2004/12/20)
  \Put@Line(300,420)(-1,4){60}%                  %bond 4-3
  \Put@Line(-240,660)(1,-4){60}%                 %bond 1-9
  \Put@Line(0,0)(1,4){60}%                       %bond 6-5
  \Put@Line(60,240)(4,3){240}%                   %bond 5-4
  {\def\thinLineWidth{5pt}\BackGroundColor%      % front-to-back crossing2013/06/24-07/23
  \thinlines%                          %
  \Put@Line(40,255)(-4,3){80}}%        % front-to-back crossing2013/06/24-07/23
  \Put@Line(60,240)(-4,3){240}%                  %bond 5-9
}%
%substituents
\@forsemicol\member:=#2\do{%
\ifx\member\empty\else
\expandafter\@m@mb@r\member;\relax%
\expandafter\threech@r\@membera{}{}\relax%
\ifx\@memberb\@yl\else
\ifcase\@tmpa%0 omit
\or\setBScolor{\@adamanea}% subst. on 1
%\@adamanea% subst. on 1
\or\setBScolor{\@adamaneb}% subst. on 2
%\@adamaneb% subst. on 2
\or\setBScolor{\@adamanec}% subst. on 3
%\@adamanec% subst. on 3
\or\setBScolor{\@adamaned}% subst. on 4
%\@adamaned% subst. on 4
\or\setBScolor{\@adamanee}% subst. on 5
%\@adamanee% subst. on 5
\or\setBScolor{\@adamanef}% subst. on 6
%\@adamanef% subst. on 6
\or\setBScolor{\@adamaneg}% subst. on 7
%\@adamaneg% subst. on 7
\or\setBScolor{\@adamaneh}% subst. on 8
%\@adamaneh% subst. on 8
\or\setBScolor{\@adamanei}% subst. on 9
%\@adamanei% subst. on 9
\or\setBScolor{\@adamanej}% subst. on 10
%\@adamanej% subst. on 10
\fi%the end of ifcase
\fi\fi}%
\end{ShiftPicEnvB}%
}%                          %end of \adamantane macro%
%    \end{macrocode}
% \end{macro}
% \end{macro}
%
% The command |\yladamanposition| is to obtain the shift values 
% |\@ylii| and |\@yli| which are used for shifting the standard 
% point of a substituent. 
% \changes{v1.02}{1998/10/23}{New commands for setting substituents}
%
% \begin{macro}{\yladamanposition}
%    \begin{macrocode}
\def\yladamanposition#1{%
\@@ylswfalse%%%\@reset@ylsw
\@forsemicol\member:=#1\do{%
\if@@ylsw\else
\ifx\member\empty\else
\expandafter\@m@mb@r\member;\relax
\expandafter\threech@r\@membera{}{}\relax
\ifx\@memberb\@yl\relax\@@ylswtrue\else\@@ylswfalse\fi
\if@@ylsw
\ifcase\@tmpa%0 omit
 \or\gdef\@ylii{240}\gdef\@yli{-660}\global\@ylswtrue% subst. on 1
 \or\gdef\@ylii{0}\gdef\@yli{-780}\global\@ylswtrue% subst. on 2
 \or\gdef\@ylii{-240}\gdef\@yli{-660}\global\@ylswtrue% subst. on 3
 \or\gdef\@ylii{-300}\gdef\@yli{-420}\global\@ylswtrue% subst. on 4
 \or\gdef\@ylii{-60}\gdef\@yli{-240}\global\@ylswtrue% subst. on 5
 \or\gdef\@ylii{0}\gdef\@yli{0}\global\@ylswtrue% subst. on 6
 \or\gdef\@ylii{60}\gdef\@yli{-240}\global\@ylswtrue% subst. on 7
 \or\gdef\@ylii{300}\gdef\@yli{-420}\global\@ylswtrue% subst. on 8
 \or\gdef\@ylii{180}\gdef\@yli{-420}\global\@ylswtrue% subst. on 9
 \or\gdef\@ylii{-180}\gdef\@yli{-420}\global\@ylswtrue% subst. on 10
\fi%end of ifcase
\fi\fi\fi}}%
%    \end{macrocode}
% \end{macro}
%
% \subsection{Horizontal drawing}
%
% The stereo-type skeleton of adamantane is selected 
% to have the following specification.  The |\hadamantane| 
% command prints a horizontal-type formula in which one bridge-head carbon 
% is put at the top position and a chair-form cyclohexane moiety is 
% placed at the bottom position. 
% 
% \begin{verbatim}
% ********************************************
% * adamantane derivatives (horizontal type) *
% ********************************************
% The following numbering is adopted in this macro. 
%
%                1
%           h //   `
%           //i      ` a
%          89          `
%         g||            2
%          ||j           | b
%       f  7|   l     k  3
%       *   |   ` 10  *
%     6  *  5        * c
%        e    d`  4
% \end{verbatim}
%
% \begin{verbatim}
% *************************************************
% * For preparing adamantane derivatives          *
% *   with 4 substituents on bridgehead positions *
% *         (1, 3, 5 and 7)                       *
% *   with 12 substituents on bridge positions    *
% *         (2, 4, 6, 8, 9, 10)                   *
% *************************************************
% \end{verbatim}
%
% The macro |\hadamantane| has an argument |SUBSLIST| as well as an optional 
% argument |BONDLIST|.  
%
% \begin{verbatim}
%   \hadamantane[BONDLIST]{SUBSLIST}          
% \end{verbatim}
%
% The adamantane skeleton scarcely takes an inner (endcyclic) double bond.
% However, we can designate |BONDLIST|. (This point is different from the
% specification of the |\adamantane| command.
%
% \begin{verbatim}
%
%     BONDLIST = 
%
%           none       :  adamantane skeleton
%           a          :  1,2-double bond
%           b          :  2,3-double bond
%           c          :  3,4-double bond
%           d          :  4,5-double bond
%           e          :  5,6-double bond
%           f          :  6,7-double bond
%           g          :  7,8-double bond
%           h          :  8,1-double bond
%           i          :  9,1-double bond
%           j          :  5,9-double bond
%           k          :  3,10-double bond
%           l          :  7,10-double bond
%
% \end{verbatim}
%
% The |SUBSLIST| argument takes the standard format of \XyMTeX{}, in which 
% more substitution descriptors are separated from each other 
% by a semicolon.  
% \begin{verbatim}
%
%     SUBSLIST: list of substituents (max 10 substitution positions)
%
%       for n = 1, 3, 5, and 7 (bridgeheads)
%
%           n or na    :  exocyclic single bond at n-atom
%
%       for n = 2, 4, 6, 8, 9, and 10 (bridges)
%
%           na         :  exocyclic single bond at n-atom (axial)
%           nb         :  exocyclic single bond at n-atom (equatorial)
%           nD         :  exocyclic double bond at n-atom (2 and 6)
%
% \end{verbatim}
%
% Moreover, bond modifieer used for chair-form cyclohexanes 
% such as $n$Sa and $n$Se (see above) can be also used in the |SUBSLIST| 
% of the |\hdadamantane| command. 
% 
% For numbers larger than 9 (two digits), you should designate
% the |SUBSLIST| as, e.g., 
% \begin{verbatim}
%             {{10}a}==Cl; ...
% \end{verbatim}
%
% The definition of |\@hadamantane| uses a picture environment, in which 
% bonds are put directly, while subsituents are typset by using 
% the macro |\@chairiI| to |\@chairX| defined below. 
% \changes{v1.02}{1998/10/31}{Adding \cs{ylhadamanposition}, \cs{if@ylsw},
% \cs{yl@shifti}, \cs{@ylii}, \cs{yl@shiftii}, \cs{@ylii}, 
% \cs{yl@xdiff} and \cs{yl@ydiff}}
% \changes{v5.00}{2010/10/01}{For bond coloring}
% \changes{v5.01}{2013/06/24}{hadamantane front-to-back crossing}
%
% \begin{macro}{\@hadamantane}
% \begin{macro}{\hadamantane}
%    \begin{macrocode}
% *************************
% * input of basic macros *
% *************************
\def\hadamantane{\@ifnextchar[{\@hadamantane}{\@hadamantane[H]}}
\def\@hadamantane[#1]#2{%
\@reset@ylsw%
\ylhadamanposition{#2}%
\def\@@ylii{0}\def\@@yli{0}%
\begin{ShiftPicEnvB}(0,0)(-\yl@shiftii,-\yl@shifti)/%
(1600,1400)(-400,-319){hadamantane}%
(400,319)%2002/4/30 by S. Fujita
   \thinlines%
      \Put@Line(0,0)(3,4){170}%          % bond 6 to 7
      \Put@Line(170,226)(3,-1){403}%     %      7 to 10
      \Put@Line(573,91)(3,1){270}%       %      10 to 3
% %%%
      \Put@Line(170,226)(0,1){360}%      %      7 to 8
      \Put@Line(170,586)(3,1){270}%      %      8 to 1
      \Put@Line(843,181)(0,1){360}%      %      3 to 2
      \Put@Line(843,541)(-3,1){403}%     %      2 to 1
   {\iffrontthicktothin\thinlines\else\thicklines\fi%2013/06/24
      \molfronttrue
      \Put@Line(843,181)(-3,-4){170}%    %      3 to 4
      \Put@Line(673,-46)(-3,1){403}%     %      4 to 5
      \Put@Line(0,0)(3,1){270}%          %      6 to 5
% %%%
     {\def\thinLineWidth{5pt}\BackGroundColor% front-to-back crossing2013/06/24-07/23
     \thinlines%                        %
     \Put@Line(270,150)(0,1){80}}%      % front-to-back crossing2013/06/24-07/23
     \Put@Line(270,90)(0,1){360}%       %      5 to 9
     \Put@Line(270,450)(3,4){170}%      %      9 to 1
   }%
   \thinlines%
% inner double bonds
\@tfor\member:=#1\do{%
\if\member r%no endocyclic bonds
\else \if\member a%
      \Put@Line(450,636)(3,-1){373}%     % double bond 1 to 2
\else \if\member b%
      \Put@Line(803,206)(0,1){320}%      %             3 to 2
\else \if\member c%%%a%
       \Put@Line(767,139)(-3,-4){110}%   %             3 to 4
\else \if\member d%%%b%
      \Put@Line(640,-5)(-3,1){343}%      %             4 to 5
\else \if\member e%%%%c%
       \Put@Line(240,111)(-3,-1){190}%   %             5 to 6
\else \if\member f%%%d%
      \Put@Line(63,40)(3,4){110}%        %             6 to 7
\else \if\member g%
      \Put@Line(200,246)(0,1){320}%      %             7 to 8
\else \if\member h%
       \Put@Line(400,626)(-3,-1){190}%   %             8 to 1
\else \if\member i%
      \Put@Line(450,636)(-3,-4){150}%    %             9 to 1
\else \if\member j%
      \Put@Line(300,110)(0,1){320}%      %             5 to 9
\else \if\member k%%%f%
      \Put@Line(768,131)(-3,-1){170}%    %             3 to 10
\else \if\member l%
      \Put@Line(182,187)(3,-1){343}%     %             7 to 10
\fi\fi\fi\fi\fi\fi%
\fi\fi\fi\fi\fi\fi\fi}%
% %
\@forsemicol\member:=#2\do{%
\ifx\member\empty\else
\expandafter\@m@mb@r\member;\relax%
\expandafter\threech@r\@membera{}{}%
\ifx\@memberb\@yl\else
\ifcase\@tmpa%                  %0 omit
 \or\setBScolor{\Put@Direct(440,676){\@chairiI}}%  %subst. on 1%%%9
% \Put@Direct(440,676){\@chairiI}%  %subst. on 1%%%9
 \or\setBScolor{\Put@Direct(843,541){\@chairiII}}% %subst. on 2%%10
% \Put@Direct(843,541){\@chairiII}% %subst. on 2%%10
 \or\setBScolor{\@chairiIII}%               %subst. on 3%%%4
% \@chairiIII%               %subst. on 3%%%4
 \or\setBScolor{\@chairiIV}%                %subst. on 4%%%3
% \@chairiIV%                %subst. on 4%%%3
 \or\setBScolor{\@chairiV}%                 %subst. on 5%%%2
% \@chairiV%                 %subst. on 5%%%2
 \or
 \setBScolor{\@chairiVI}%                %subst. on 6%%%1
% \@chairiVI%                %subst. on 6%%%1
 \or\setBScolor{\@chairiVII}%               %subst. on 7%%%6
% \@chairiVII%               %subst. on 7%%%6
 \or\setBScolor{\Put@Direct(170,586){\@chairiVIII}}%subst. on 8%%%8
% \Put@Direct(170,586){\@chairiVIII}%subst. on 8%%%8
 \or\setBScolor{\Put@Direct(270,450){\@chairiIX}}% %subst. on 9%%%7
% \Put@Direct(270,450){\@chairiIX}% %subst. on 9%%%7
 \or\setBScolor{\@chairiX}%                 %subst. on 10%%5
% \@chairiX%                 %subst. on 10%%5
\fi %end of ifcase
\fi\fi%
}%
\end{ShiftPicEnvB}%
}%               %end of \hadamantane macro
% End of addition 1994/03/05 SF
%    \end{macrocode}
% \end{macro}
% \end{macro}
%
% The command |\ylhadamanposition| is to obtain the shift values 
% |\@ylii| and |\@yli| which are used for shifting the standard 
% point of a substituent. 
% \changes{v1.02}{1998/10/23}{New commands for setting substituents}
%
% \begin{macro}{\ylhadamanposition}
%    \begin{macrocode}
\def\ylhadamanposition#1{%
\@@ylswfalse%%%\@reset@ylsw
\@forsemicol\member:=#1\do{%
\if@@ylsw\else
\ifx\member\empty\else
\expandafter\@m@mb@r\member;\relax
\expandafter\threech@r\@membera{}{}\relax
\ifx\@memberb\@yl\relax\@@ylswtrue\else\@@ylswfalse\fi
\if@@ylsw
\ifcase\@tmpa%0 omit
 \or\gdef\@ylii{-440}\gdef\@yli{-676}\global\@ylswtrue% subst. on 1
 \or\gdef\@ylii{-843}\gdef\@yli{-541}\global\@ylswtrue% subst. on 2
 \or\gdef\@ylii{-843}\gdef\@yli{-181}\global\@ylswtrue% subst. on 3
 \or\gdef\@ylii{-673}\gdef\@yli{46}\global\@ylswtrue% subst. on 4
 \or\gdef\@ylii{-270}\gdef\@yli{-90}\global\@ylswtrue% subst. on 5
 \or\gdef\@ylii{0}\gdef\@yli{0}\global\@ylswtrue% subst. on 6
 \or\gdef\@ylii{-170}\gdef\@yli{-226}\global\@ylswtrue% subst. on 7
 \or\gdef\@ylii{-170}\gdef\@yli{-586}\global\@ylswtrue% subst. on 8
 \or\gdef\@ylii{-270}\gdef\@yli{-450}\global\@ylswtrue% subst. on 9
 \or\gdef\@ylii{-573}\gdef\@yli{-91}\global\@ylswtrue% subst. on 10
\fi%end of ifcase
\fi\fi\fi}}%
%    \end{macrocode}
% \end{macro}
%
% Hereafter, the definitions of the commands |\@chairiI| to |\@chairiX| 
% are described. Each of the commands can treat $n$a-type bond modifiers 
% as well as $n$Sa-type bond modifiers. 
%
% \begin{macro}{\@chairiVI}
% \changes{v1.02}{1998/10/31}{Adding \cs{yl@xdiff} and \cs{yl@ydiff}}
%    \begin{macrocode}
% ********************************************************
% * treatment of the chair form (inverse) of cyclohexane *
% *  added March 05, 1994 by Shinsaku Fujita             *
% ********************************************************
% %%%%%%%%%%%%%%%
% % subst. on 6 %
% %%%%%%%%%%%%%%%
\def\@chairiVI{%
   \if\@tmpb a%single bond
     \yl@xdiff=42
     \yl@ydiff=92
           \Put@Line(0,0)(0,-1){168}% single bond at 6 axial
           \putlratom{-42}{-260}{\@memberb}% left & right type
   \else\if\@tmpb b%single bond
     \yl@xdiff=16
     \yl@ydiff=36
           \Put@Line(0,0)(-5,3){144}% single bond at 6 equatorial
           \putlatom{-160}{50}{\@memberb}% left type
   \else\if\@tmpb S%single bond
    \ifx\@tmpc\empty%
     \yl@xdiff=10
     \yl@ydiff=90
           \Put@Line(0,0)(-1,-1){120}% single bond at 6
           \putlatom{-130}{-210}{\@memberb}% left type
    \else\if\@tmpc a%(a) axial
     \yl@xdiff=42
     \yl@ydiff=92
           \Put@Line(0,0)(0,-1){168}% single bond at 6 axial
           \putlratom{-42}{-260}{\@memberb}% left & right type
    \else\if\@tmpc e%(e) beta
     \yl@xdiff=16
     \yl@ydiff=36
           \Put@Line(0,0)(-5,3){144}% single bond at 6 equatorial
           \putlatom{-160}{50}{\@memberb}% left type
    \fi\fi\fi%
   \else \if\@tmpb D%double bond
     \yl@xdiff=10
     \yl@ydiff=90
           \putlatom{-130}{-210}{\@memberb}% left type
           \Put@Line(-10,10)(-1,-1){120}% double bond at 6
           \Put@Line(10,-10)(-1,-1){120}% double bond at 6
          \else%
     \yl@xdiff=10
     \yl@ydiff=90
           \putlatom{-130}{-210}{\@memberb}% left type
           \Put@Line(0,0)(-1,-1){120}% single bond at 6
   \fi\fi\fi\fi}%
%    \end{macrocode}
% \end{macro}
%
% \begin{macro}{\@chairiVII}
% \changes{v1.02}{1998/10/31}{Adding \cs{yl@xdiff} and \cs{yl@ydiff}}
%    \begin{macrocode}
% %%%%%%%%%%%%%%%
% % subst. on 7 %
% %%%%%%%%%%%%%%%
\def\@chairiVII{%
   \if\@tmpb a%single bond
     \yl@xdiff=26
     \yl@ydiff=46
           \Put@Line(170,226)(-5,-3){144}% single bond at 7 equatorial
           \putlatom{10}{94}{\@memberb}% left type
   \else\ifx\@tmpb\empty%single bond
     \yl@xdiff=26
     \yl@ydiff=46
           \Put@Line(170,226)(-5,-3){144}% single bond at 7 equatorial
           \putlatom{10}{94}{\@memberb}% left type
   \else\if\@tmpb S%single bond
    \ifx\@tmpc\empty%
     \yl@xdiff=10
     \yl@ydiff=30
           \Put@Line(170,226)(-1,1){120}% single bond at 7
           \putratom{40}{316}{\@memberb}% left type
    \else\if\@tmpc a%(a) axial
     \yl@xdiff=32
     \yl@ydiff=12
           \Put@Line(170,226)(0,1){168}% single bond at 7 axial
           \putlratom{138}{406}{\@memberb}% left & right type
    \else\if\@tmpc e%(e) beta
     \yl@xdiff=26
     \yl@ydiff=46
           \Put@Line(170,226)(-5,-3){144}% single bond at 7 equatorial
           \putlatom{10}{94}{\@memberb}% left type
    \fi\fi\fi%
   \else \if\@tmpb D%double bond
     \yl@xdiff=10
     \yl@ydiff=30
           \putlatom{40}{316}{\@memberb}% left type
           \Put@Line(160,216)(-1,1){120}% double bond at 7
           \Put@Line(180,236)(-1,1){120}% double bond at 7
          \else%
     \yl@xdiff=10
     \yl@ydiff=30
           \putlatom{40}{316}{\@memberb}% left type
           \Put@Line(170,226)(-1,1){120}% single bond at 7
   \fi\fi\fi\fi}%
%    \end{macrocode}
% \end{macro}
%
% \begin{macro}{\@chairiX}
% \changes{v1.02}{1998/10/31}{Adding \cs{yl@xdiff} and \cs{yl@ydiff}}
%    \begin{macrocode}
% %%%%%%%%%%%%%%%%
% % subst. on 10 %
% %%%%%%%%%%%%%%%%
\def\@chairiX{%
   \if\@tmpb a%single bond
     \yl@xdiff=40
     \yl@ydiff=104
           \Put@Line(573,91)(0,-1){168}% single bond at 5 axial
           \putlratom{533}{-181}{\@memberb}% left type
   \else\if\@tmpb b%single bond
     \yl@xdiff=-36
     \yl@ydiff=3
           \Put@Line(573,91)(5,3){144}% single bond at 5 equatorial
           \putlatom{753}{180}{\@memberb}% left type
   \else\if\@tmpb S%single bond
    \ifx\@tmpc\empty%
     \yl@xdiff=-10
     \yl@ydiff=56
           \Put@Line(573,91)(5,-4){170}% single bond at 5
           \putratom{753}{-101}{\@memberb}% right type
    \else\if\@tmpc a%(a) axial
     \yl@xdiff=40
     \yl@ydiff=104
           \Put@Line(573,91)(0,-1){168}% single bond at 5 axial
           \putlratom{533}{-181}{\@memberb}% left type
    \else\if\@tmpc e%(e) beta
     \yl@xdiff=-36
     \yl@ydiff=3
           \Put@Line(573,91)(5,3){144}% single bond at 5 equatorial
           \putlatom{753}{180}{\@memberb}% left type
    \fi\fi\fi%
   \else \if\@tmpb D%double bond
     \yl@xdiff=10
     \yl@ydiff=86
           \putratom{733}{-141}{\@memberb}% right type
           \Put@Line(563,83)(5,-4){170}% double bond at 5
           \Put@Line(583,99)(5,-4){170}% double bond at 5
          \else%
     \yl@xdiff=-10
     \yl@ydiff=76
           \Put@Line(573,91)(5,-4){170}% single bond at 5
           \putratom{753}{-121}{\@memberb}% right type
   \fi\fi\fi\fi}%
%    \end{macrocode}
% \end{macro}
%
% \begin{macro}{\@chairiIII}
% \changes{v1.02}{1998/10/31}{Adding \cs{yl@xdiff} and \cs{yl@ydiff}}
%    \begin{macrocode}
% %%%%%%%%%%%%%%%
% % subst. on 3 %
% %%%%%%%%%%%%%%%
\def\@chairiIII{%
   \if\@tmpb a%single bond
     \yl@xdiff=-16
     \yl@ydiff=64
           \Put@Line(843,181)(5,-3){144}% single bond at 3 equatorial
           \putratom{1003}{31}{\@memberb}% right type
   \else\ifx\@tmpb\empty%single bond
     \yl@xdiff=-16
     \yl@ydiff=64
           \Put@Line(843,181)(5,-3){144}% single bond at 3 equatorial
           \putratom{1003}{31}{\@memberb}% right type
   \else\if\@tmpb S%single bond
    \ifx\@tmpc\empty%
     \yl@xdiff=10
     \yl@ydiff=30
           \Put@Line(843,181)(1,1){120}% single bond at 3
           \putratom{953}{271}{\@memberb}% right type
    \else\if\@tmpc a%(a) axial
     \yl@xdiff=42
     \yl@ydiff=11
           \Put@Line(843,181)(0,1){168}% single bond at 3 axial
           \putlratom{801}{360}{\@memberb}% left & right type
    \else\if\@tmpc e%(e) beta
     \yl@xdiff=-16
     \yl@ydiff=64
           \Put@Line(843,181)(5,-3){144}% single bond at 3 equatorial
           \putratom{1003}{31}{\@memberb}% right type
    \fi\fi\fi%
   \else \if\@tmpb D%double bond
     \yl@xdiff=0
     \yl@ydiff=30
           \putratom{953}{271}{\@memberb}% right type
           \Put@Line(833,191)(1,1){120}% double bond at 3
           \Put@Line(853,171)(1,1){120}% double bond at 3
          \else%
     \yl@xdiff=10
     \yl@ydiff=30
           \Put@Line(843,181)(1,1){120}% single bond at 3
           \putratom{953}{271}{\@memberb}% right type
   \fi\fi\fi\fi}%
%    \end{macrocode}
% \end{macro}
%
% \begin{macro}{\@chairiIV}
% \changes{v1.02}{1998/10/31}{Adding \cs{yl@xdiff} and \cs{yl@ydiff}}
%    \begin{macrocode}
% %%%%%%%%%%%%%%%
% % subst. on 4 %
% %%%%%%%%%%%%%%%
\def\@chairiIV{%
   \if\@tmpb a%single bond
     \yl@xdiff=40
     \yl@ydiff=104
           \Put@Line(673,-46)(0,-1){168}% single bond at 4 axial
           \putlratom{633}{-318}{\@memberb}% left & right type
   \else\if\@tmpb b%single bond
     \yl@xdiff=-6
     \yl@ydiff=17
           \Put@Line(673,-46)(5,3){144}% single bond at 4 equatorial
           \putratom{823}{23}{\@memberb}% right type
   \else\if\@tmpb S%single bond
    \ifx\@tmpc\empty%
     \yl@xdiff=-10
     \yl@ydiff=92
           \Put@Line(673,-46)(1,-1){120}% single bond at 4
           \putratom{803}{-258}{\@memberb}% right type
    \else\if\@tmpc a%(a) axial
     \yl@xdiff=40
     \yl@ydiff=104
           \Put@Line(673,-46)(0,-1){168}% single bond at 4 axial
           \putlratom{633}{-318}{\@memberb}% left & right type
    \else\if\@tmpc e%(e) beta
     \yl@xdiff=-6
     \yl@ydiff=17
           \Put@Line(673,-46)(5,3){144}% single bond at 4 equatorial
           \putratom{823}{23}{\@memberb}% right type
    \fi\fi\fi%
   \else \if\@tmpb D%double bond
     \yl@xdiff=-10
     \yl@ydiff=92
           \putratom{803}{-258}{\@memberb}%  right type
           \Put@Line(663,-53)(1,-1){120}% double bond at 4
           \Put@Line(683,-38)(1,-1){120}% double bond at 4
          \else%
     \yl@xdiff=-10
     \yl@ydiff=76
           \Put@Line(673,-46)(5,-4){170}% single bond at 4
           \putratom{853}{-258}{\@memberb}% right type
   \fi\fi\fi\fi}%
%    \end{macrocode}
% \end{macro}
%
% \begin{macro}{\@chairiV}
% \changes{v1.02}{1998/10/31}{Adding \cs{yl@xdiff} and \cs{yl@ydiff}}
%    \begin{macrocode}
% %%%%%%%%%%%%%%%
% % subst. on 5 %
% %%%%%%%%%%%%%%%
\def\@chairiV{%
   \if\@tmpb a%single bond
     \yl@xdiff=26
     \yl@ydiff=102
           \Put@Line(270,90)(-5,-3){144}% single bond at 5 equatorial
           \putratom{100}{-98}{\@memberb}% left type
   \else\ifx\@tmpb\empty%single bond
     \yl@xdiff=26
     \yl@ydiff=102
           \Put@Line(270,90)(-5,-3){144}% single bond at 5 equatorial
           \putratom{100}{-98}{\@memberb}% left type
   \else\if\@tmpb S%single bond
    \ifx\@tmpc\empty%
     \yl@xdiff=0
     \yl@ydiff=46
           \Put@Line(270,90)(-5,4){170}% single bond at 5
           \putlatom{100}{180}{\@memberb}% left type
    \else\if\@tmpc a%(a) axial
     \yl@xdiff=32
     \yl@ydiff=12
           \Put@Line(270,90)(0,1){168}% single bond at 5 axial
           \putlratom{238}{270}{\@memberb}% left type
    \else\if\@tmpc e%(e) beta
     \yl@xdiff=36
     \yl@ydiff=102
           \Put@Line(270,90)(-5,-3){144}% single bond at 5 equatorial
           \putratom{100}{-98}{\@memberb}% left type
    \fi\fi\fi%
   \else \if\@tmpb D%double bond
     \yl@xdiff=0
     \yl@ydiff=36
           \putlatom{100}{200}{\@memberb}% left or right type
           \Put@Line(260,80)(-5,4){170}% double bond at 5
           \Put@Line(280,100)(-5,4){170}% double bond at 5
          \else%
     \yl@xdiff=0
     \yl@ydiff=26
           \putlatom{100}{200}{\@memberb}% left type
           \Put@Line(270,90)(-5,4){170}% single bond at 5
   \fi\fi\fi\fi}%
%    \end{macrocode}
% \end{macro}
%
%
% \begin{macro}{\@chairiI}
% \changes{v1.02}{1998/10/31}{Adding \cs{yl@xdiff} and \cs{yl@ydiff}}
%    \begin{macrocode}
% %%%%%%%%%%%%%%%
% % subst. on 1 %
% %%%%%%%%%%%%%%%
\def\@chairiI{%
   \if\@tmpb a%single bond
     \yl@xdiff=42
     \yl@ydiff=-10
           \Put@Line(0,0)(0,1){168}% single bond at 1 axial
           \putlratom{-42}{178}{\@memberb}% left & right type
   \else\ifx\@tmpb\empty%
     \yl@xdiff=42
     \yl@ydiff=-10
           \Put@Line(0,0)(0,1){168}% single bond at 1 axial
           \putlratom{-42}{178}{\@memberb}% left & right type
   \else\if\@tmpb S%single bond
    \ifx\@tmpc\empty%
     \yl@xdiff=42
     \yl@ydiff=-10
           \Put@Line(0,0)(0,1){168}% single bond at 1 axial
           \putlratom{-42}{178}{\@memberb}% left & right type
    \else\if\@tmpc a%(a) axial
     \yl@xdiff=42
     \yl@ydiff=-10
           \Put@Line(0,0)(0,1){168}% single bond at 1 axial
           \putlratom{-42}{178}{\@memberb}% left & right type
    \else\if\@tmpc e%(e) beta
     \yl@xdiff=42
     \yl@ydiff=-10
           \Put@Line(0,0)(0,1){168}% single bond at 1 axial
           \putlratom{-42}{178}{\@memberb}% left & right type
    \fi\fi\fi%
  \else \if\@tmpb D%double bond
     \yl@xdiff=42
     \yl@ydiff=-10
           \Put@Line(0,0)(0,1){168}% single bond at 1 axial
           \putlratom{-42}{178}{\@memberb}% left & right type
          \else%
     \yl@xdiff=42
     \yl@ydiff=-10
           \Put@Line(0,0)(0,1){168}% single bond at 1 axial
           \putlratom{-42}{178}{\@memberb}% left & right type
   \fi\fi\fi\fi}%
%    \end{macrocode}
% \end{macro}
%
% \begin{macro}{\@chairiII}
% \changes{v1.02}{1998/10/31}{Adding \cs{yl@xdiff} and \cs{yl@ydiff}}
%    \begin{macrocode}
% %%%%%%%%%%%%%%%%
% % subst. on 2 %
% %%%%%%%%%%%%%%%%
\def\@chairiII{%
   \if\@tmpb a%single bond
     \yl@xdiff=-10
     \yl@ydiff=13
           \Put@Line(0,0)(3,1){190}% single bond at 6 equatorial
           \putratom{200}{50}{\@memberb}% right type
   \else\if\@tmpb b%single bond
     \yl@xdiff=-10
     \yl@ydiff=0
            \Put@Line(0,0)(3,4){120}%          % bond 1 to 6
            \putratom{130}{160}{\@memberb}% left type
   \else\if\@tmpb S%single bond
     \ifx\@tmpc\empty%
     \yl@xdiff=-10
     \yl@ydiff=-10
           \Put@Line(0,0)(1,1){120}% single bond at 1
           \putratom{130}{130}{\@memberb}% left type
      \else\if\@tmpc a%(a) axial
     \yl@xdiff=-10
     \yl@ydiff=0
            \Put@Line(0,0)(3,4){120}%          % bond 1 to 6
            \putratom{130}{160}{\@memberb}% left type
     \else\if\@tmpc e%(e) beta
     \yl@xdiff=-10
     \yl@ydiff=13
           \Put@Line(0,0)(3,1){190}% single bond at 6 equatorial
           \putratom{200}{50}{\@memberb}% right type
    \fi\fi\fi%
   \else \if\@tmpb D%double bond
     \yl@xdiff=-10
     \yl@ydiff=-10
           \putratom{130}{130}{\@memberb}% left type
           \Put@Line(-10,10)(1,1){120}% double bond at 1
           \Put@Line(10,-10)(1,1){120}% double bond at 1
          \else%
     \yl@xdiff=-10
     \yl@ydiff=-10
           \putratom{130}{130}{\@memberb}% left type
           \Put@Line(0,0)(1,1){120}% single bond at 1
   \fi\fi\fi\fi}%
%    \end{macrocode}
% \end{macro}
%
% \begin{macro}{\@chairigVIII}
% \changes{v1.02}{1998/10/31}{Adding \cs{yl@xdiff} and \cs{yl@ydiff}}
%    \begin{macrocode}
% %%%%%%%%%%%%%%%
% % subst. on 8 %
% %%%%%%%%%%%%%%%
\def\@chairiVIII{%
   \if\@tmpb a%single bond
     \yl@xdiff=16
     \yl@ydiff=36
           \Put@Line(0,0)(-5,3){144}% single bond at 1 equatorial
           \putlatom{-160}{50}{\@memberb}% left type
   \else\if\@tmpb b%single bond
     \yl@xdiff=-10
     \yl@ydiff=0
            \Put@Line(0,0)(3,4){120}%          % bond 1 to 6
            \putratom{130}{160}{\@memberb}% left type
   \else\if\@tmpb S%single bond
    \ifx\@tmpc\empty%
     \yl@xdiff=4
     \yl@ydiff=36
           \Put@Line(0,0)(-5,3){144}% single bond at 1 equatorial
           \putlatom{-140}{50}{\@memberb}% left type
    \else\if\@tmpc e% right-hand
     \yl@xdiff=-10
     \yl@ydiff=0
            \Put@Line(0,0)(3,4){120}%          % bond 1 to 6
            \putratom{130}{160}{\@memberb}% left type
    \else\if\@tmpc a% left-hand
     \yl@xdiff=16
     \yl@ydiff=36
           \Put@Line(0,0)(-5,3){144}% single bond at 1 equatorial
           \putlatom{-160}{50}{\@memberb}% left type
    \fi\fi\fi%
   \else \if\@tmpb D%double bond
     \yl@xdiff=4
     \yl@ydiff=26
            \putlatom{-140}{60}{\@memberb}% left type
           \Put@Line(10,10)(-5,3){144}% single bond at 1 equatorial
           \Put@Line(0,-10)(-5,3){144}% single bond at 1 equatorial
          \else%
     \yl@xdiff=4
     \yl@ydiff=36
           \Put@Line(0,0)(-5,3){144}% single bond at 1 equatorial
           \putlatom{-140}{50}{\@memberb}% left type
   \fi\fi\fi\fi}%
%    \end{macrocode}
% \end{macro}
%
% \begin{macro}{\@chairiIX}
% \changes{v1.02}{1998/10/31}{Adding \cs{yl@xdiff} and \cs{yl@ydiff}}
%    \begin{macrocode}
% %%%%%%%%%%%%%%%
% % subst. on 9 %
% %%%%%%%%%%%%%%%
\def\@chairiIX{%
   \if\@tmpb a%single bond
     \yl@xdiff=16
     \yl@ydiff=36
           \Put@Line(0,0)(-5,3){144}% single bond at 1 equatorial
           \putlatom{-160}{50}{\@memberb}% left type
   \else\if\@tmpb b%single bond
     \yl@xdiff=-16
     \yl@ydiff=36
           \Put@Line(0,0)(5,3){144}% single bond at 6 equatorial
           \putratom{160}{50}{\@memberb}% left type
   \else\if\@tmpb S%single bond
    \ifx\@tmpc\empty%
     \yl@xdiff=4
     \yl@ydiff=36
           \Put@Line(0,0)(-5,3){144}% single bond at 1 equatorial
           \putlatom{-140}{50}{\@memberb}% left type
    \else\if\@tmpc e% right-hand
     \yl@xdiff=-16
     \yl@ydiff=36
           \Put@Line(0,0)(5,3){144}% single bond at 6 equatorial
           \putratom{160}{50}{\@memberb}% left type
    \else\if\@tmpc a% left-hand
     \yl@xdiff=16
     \yl@ydiff=36
           \Put@Line(0,0)(-5,3){144}% single bond at 1 equatorial
           \putlatom{-160}{50}{\@memberb}% left type
    \fi\fi\fi%
   \else \if\@tmpb D%double bond
     \yl@xdiff=4
     \yl@ydiff=36
           \putlatom{-140}{50}{\@memberb}% left type
           \Put@Line(10,10)(-5,3){144}% single bond at 1 equatorial
           \Put@Line(0,-10)(-5,3){144}% single bond at 1 equatorial
          \else%
     \yl@xdiff=4
     \yl@ydiff=36
           \Put@Line(0,0)(-5,3){144}% single bond at 1 equatorial
           \putlatom{-140}{50}{\@memberb}% left type
   \fi\fi\fi\fi}%
%</ccycle>
%    \end{macrocode}
% \end{macro}
%
% \Finale
%
\endinput
