% ACSarticle.sty 22-May-91
% for chapter according to formattinng instructions of 
% Advances in Control Systems
%
% use with \title{} \author{} \address{} \maketitle

\typeout{Document Style `ACSarticle` <22 June 91>.}

\def\title#1{\gdef\@title{\raggedleft  #1}}
\def\author#1{\gdef\@author{\raggedleft  #1}}
\def\address#1{\gdef\@address{\raggedleft  #1}}
\input article.sty\relax
\mark{{}{}}

\def\maketitle{
\par
 \begingroup
 \def\thefootnote{\fnsymbol{footnote}}
 \def\@makefnmark{\hbox 
 to 0pt{$^{\@thefnmark}$\hss}} 
 \if@twocolumn 
 \twocolumn[\@maketitle] 
 \else \newpage
 \global\@topnum\z@ \@maketitle \fi\thispagestyle{plain}\@thanks
 \endgroup
 \setcounter{footnote}{0}
 \let\maketitle\relax
 \let\@maketitle\relax
 \gdef\@thanks{}\gdef\@author{}\gdef\@address{}\gdef\@title{}\let\thanks\relax}
\def\@maketitle{\newpage
 \null
 \vskip 5em 
 {\Large\bf \@title \par} \vskip 2.5em { \lineskip .5em
 \large\bf \@author 
\par} 
 \vskip 3em \@address
 \par
 \vskip 2.5em} 



% Fix the look of the references to match the sample
\def\thebibliography#1{\section{REFERENCES\@mkboth
 {REFERENCES}{REFERENCES}}\list
 {\arabic{enumi}.\hfill}{\settowidth\labelwidth{[22.]}
\labelsep 0mm
\itemindent 0mm
\advance\leftmargin -2mm
%\leftmargin\labelwidth
% \advance\leftmargin\labelsep
 \usecounter{enumi}}
 \def\newblock{\hskip .11em plus .33em minus .07em}
 \sloppy\clubpenalty4000\widowpenalty4000
 \sfcode`\.=1000\relax}
\let\endthebibliography=\endlist

\long\def\@makecaption#1#2#3{
\ifx\figurestring#3 
      \vskip 10pt 
      \setbox\@tempboxa\hbox{{\bf #1.} #2}
      \ifdim \wd\@tempboxa >\hsize 
      \setbox\@tempboxa\hbox{\bf #1.~ }
      \parbox{\hsize}{\raggedright\hangindent \wd\@tempboxa \hangafter=1% 
      \unhbox\@tempboxa#2}
      \else \hbox to\hsize{\hfil\box\@tempboxa\hfil} 
      \fi
\else
       \setbox\@tempboxa\hbox{{\bf #1.} #2}
       \ifdim \wd\@tempboxa >\hsize 
      \setbox\@tempboxa\hbox{\bf #1.~ }
      \parbox{\hsize}{\raggedright\hangindent \wd\@tempboxa \hangafter=1% 
      \unhbox\@tempboxa#2}
       \else \hbox to\hsize{\hfil\box\@tempboxa\hfil} 
       \fi
       \vskip 10pt 
\fi
}
\def\@cite#1#2{[{#1\if@tempswa , #2\fi}]}
\def\@biblabel#1{#1.\hfill}
\def\fnum@table{Table~\thetable}
\def\fnum@figure{{\bf Fig.}~\thefigure}
\def\thetable{\@Roman\c@table}

%Format size
\setlength\topmargin{20mm}
\setlength\oddsidemargin{20mm}
\setlength\evensidemargin{20mm}
\setlength\textheight{7.125in}
\setlength\textwidth{4.5in}
\renewcommand{\baselinestretch}{1.2}

% Enumerate sections as I. A. 1. a.
\def\thepart{\Roman{part}} 
\def\thesection {\Roman{section}}
\def\thesubsection {\Alph{subsection}}
\def\thesubsubsection {\arabic{subsubsection}}
\def\theparagraph {\alph{paragraph}}

\def\section{\@startsection {section}{1}{\z@}{-3.5ex plus -1ex minus 
 -.2ex}{2.3ex plus .2ex}{\large\bf}}
\def\subsection{\@startsection{subsection}{2}{\z@}{-3.25ex plus -1ex minus 
 -.2ex}{1.5ex plus .2ex}{\large\bf}}
\def\subsubsection{\@startsection{subsubsection}{3}{\z@}{-3.25ex plus 
-1ex minus -.2ex}{1.5ex plus .2ex}{\normalsize\bf}}
\def\paragraph{\@startsection{paragraph}{3}{\z@}{3.25ex plus 1ex
minus .2ex}{1.5ex plus .2ex}{\normalsize\bf}}


\def\@sect#1#2#3#4#5#6[#7]#8{\ifnum #2>\c@secnumdepth
     \def\@svsec{}\else 
     \refstepcounter{#1}\edef\@svsec{\csname the#1\endcsname.\hskip 1em }\fi
     \@tempskipa #5\relax
      \ifdim \@tempskipa>\z@ 
        \begingroup #6\relax
          \@hangfrom{\hskip #3\relax\@svsec}{\interlinepenalty \@M #8\par}%
        \endgroup
       \csname #1mark\endcsname{#7}\addcontentsline
         {toc}{#1}{\ifnum #2>\c@secnumdepth \else
                      \protect\numberline{\csname the#1\endcsname}\fi
                    #7}\else
        \def\@svsechd{#6\hskip #3\@svsec #8\csname #1mark\endcsname
                      {#7}\addcontentsline
                           {toc}{#1}{\ifnum #2>\c@secnumdepth \else
                             \protect\numberline{\csname the#1\endcsname}\fi
                       #7}}\fi
     \@xsect{#5}}


%Modify Table of Contents to include paragraphs

\def\tableofcontents{\section*{}
 \@starttoc{toc}}
\def\l@part#1#2{\addpenalty{\@secpenalty}
 \addvspace{2.25em plus 1pt} \begingroup
 \@tempdima 3em \parindent \z@ \rightskip \@pnumwidth \parfillskip
-\@pnumwidth 
 {\large \bf \leavevmode #1\hfil \hbox to\@pnumwidth{\hss #2}}\par
 \nobreak \endgroup}
\def\l@section#1#2{\addpenalty{\@secpenalty} \addvspace{1.0em plus 1pt}
\@tempdima 2em \begingroup
 \parindent \z@ \rightskip \@pnumwidth 
 \parfillskip -\@pnumwidth 
 \bf \leavevmode \advance\leftskip\@tempdima \hskip -\leftskip #1\nobreak\hfil
\nobreak\hbox to\@pnumwidth{\hss #2}\par
 \endgroup}
 
\def\l@subsection{\@dottedtocline{2}{2em}{1.8em}}
\def\l@subsubsection{\@dottedtocline{3}{3.8em}{1.8em}}
\def\l@paragraph{\@dottedtocline{3}{7.0em}{1.8em}}
\def\l@subparagraph{\@dottedtocline{5}{10em}{5em}}
