1
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
3
%% This is a customised version of the report
4
%% style for my thesis. Tim Sutton 2003.
6
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
8
%% This is file `timthesis.cls',
9
%% generated with the docstrip utility.
11
%% The original source files were:
13
%% classes.dtx (with options: `timthesis')
15
%% This is a generated file.
17
%% Copyright 1993 1994 1995 1996 1997 1998 1999 2000 2001
18
%% The LaTeX3 Project and any individual authors listed elsewhere
21
%% This file was generated from file(s) of the LaTeX base system.
22
%% --------------------------------------------------------------
24
%% It may be distributed and/or modified under the
25
%% conditions of the LaTeX Project Public License, either version 1.2
26
%% of this license or (at your option) any later version.
27
%% The latest version of this license is in
28
%% http://www.latex-project.org/lppl.txt
29
%% and version 1.2 or later is part of all distributions of LaTeX
30
%% version 1999/12/01 or later.
32
%% This file may only be distributed together with a copy of the LaTeX
33
%% base system. You may however distribute the LaTeX base system without
34
%% such generated files.
36
%% The list of all files belonging to the LaTeX base distribution is
37
%% given in the file `manifest.txt'. See also `legal.txt' for additional
41
%% {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
42
%% 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
43
%% Digits \0\1\2\3\4\5\6\7\8\9
44
%% Exclamation \! Double quote \" Hash (number) \#
45
%% Dollar \$ Percent \% Ampersand \&
46
%% Acute accent \' Left paren \( Right paren \)
47
%% Asterisk \* Plus \+ Comma \,
48
%% Minus \- Point \. Solidus \/
49
%% Colon \: Semicolon \; Less than \<
50
%% Equals \= Greater than \> Question mark \?
51
%% Commercial at \@ Left bracket \[ Backslash \\
52
%% Right bracket \] Circumflex \^ Underscore \_
53
%% Grave accent \` Left brace \{ Vertical bar \|
54
%% Right brace \} Tilde \~}
55
\NeedsTeXFormat{LaTeX2e}[1995/12/01]
56
\ProvidesClass{timthesis}
58
Standard LaTeX document class]
64
\if@compatibility\else
65
\DeclareOption{a4paper}
66
{\setlength\paperheight {297mm}%
67
\setlength\paperwidth {210mm}}
68
\DeclareOption{a5paper}
69
{\setlength\paperheight {210mm}%
70
\setlength\paperwidth {148mm}}
71
\DeclareOption{b5paper}
72
{\setlength\paperheight {250mm}%
73
\setlength\paperwidth {176mm}}
74
\DeclareOption{letterpaper}
75
{\setlength\paperheight {11in}%
76
\setlength\paperwidth {8.5in}}
77
\DeclareOption{legalpaper}
78
{\setlength\paperheight {14in}%
79
\setlength\paperwidth {8.5in}}
80
\DeclareOption{executivepaper}
81
{\setlength\paperheight {10.5in}%
82
\setlength\paperwidth {7.25in}}
83
\DeclareOption{landscape}
84
{\setlength\@tempdima {\paperheight}%
85
\setlength\paperheight {\paperwidth}%
86
\setlength\paperwidth {\@tempdima}}
89
\renewcommand\@ptsize{0}
91
\DeclareOption{10pt}{\renewcommand\@ptsize{0}}
93
\DeclareOption{11pt}{\renewcommand\@ptsize{1}}
94
\DeclareOption{12pt}{\renewcommand\@ptsize{2}}
95
\if@compatibility\else
96
\DeclareOption{oneside}{\@twosidefalse \@mparswitchfalse}
98
\DeclareOption{twoside}{\@twosidetrue \@mparswitchtrue}
99
\DeclareOption{draft}{\setlength\overfullrule{5pt}}
100
\if@compatibility\else
101
\DeclareOption{final}{\setlength\overfullrule{0pt}}
103
\DeclareOption{titlepage}{\@titlepagetrue}
104
\if@compatibility\else
105
\DeclareOption{notitlepage}{\@titlepagefalse}
109
\DeclareOption{openright}{\@openrighttrue}
110
\DeclareOption{openany}{\@openrightfalse}
112
\if@compatibility\else
113
\DeclareOption{onecolumn}{\@twocolumnfalse}
115
\DeclareOption{twocolumn}{\@twocolumntrue}
116
\DeclareOption{leqno}{\input{leqno.clo}}
117
\DeclareOption{fleqn}{\input{fleqn.clo}}
118
\DeclareOption{openbib}{%
120
\renewcommand\@openbib@code{%
121
\advance\leftmargin\bibindent
122
\itemindent -\bibindent
123
\listparindent \itemindent
126
\renewcommand\newblock{\par}}%
128
\ExecuteOptions{letterpaper,10pt,oneside,onecolumn,final,openany}
130
\input{size1\@ptsize.clo}
131
\setlength\lineskip{1\p@}
132
\setlength\normallineskip{1\p@}
133
\renewcommand\baselinestretch{}
134
\setlength\parskip{0\p@ \@plus \p@}
138
\setcounter{topnumber}{2}
139
\renewcommand\topfraction{.7}
140
\setcounter{bottomnumber}{1}
141
\renewcommand\bottomfraction{.3}
142
\setcounter{totalnumber}{3}
143
\renewcommand\textfraction{.2}
144
\renewcommand\floatpagefraction{.5}
145
\setcounter{dbltopnumber}{2}
146
\renewcommand\dbltopfraction{.7}
147
\renewcommand\dblfloatpagefraction{.5}
150
\let\@oddfoot\@empty\let\@evenfoot\@empty
151
\def\@evenhead{\thepage\hfil\slshape\leftmark}%
152
\def\@oddhead{{\slshape\rightmark}\hfil\thepage}%
153
\let\@mkboth\markboth
154
\def\chaptermark##1{%
155
\markboth {\MakeUppercase{%
156
\ifnum \c@secnumdepth >\m@ne
157
\@chapapp\ \thechapter. \ %
160
\def\sectionmark##1{%
161
\markright {\MakeUppercase{%
162
\ifnum \c@secnumdepth >\z@
169
\def\@oddhead{{\slshape\rightmark}\hfil\thepage}%
170
\let\@mkboth\markboth
171
\def\chaptermark##1{%
172
\markright {\MakeUppercase{%
173
\ifnum \c@secnumdepth >\m@ne
174
\@chapapp\ \thechapter. \ %
179
\let\@oddfoot\@empty\let\@evenfoot\@empty
180
\def\@evenhead{\thepage\hfil\slshape\leftmark}%
181
\def\@oddhead{{\slshape\rightmark}\hfil\thepage}%
182
\let\@mkboth\@gobbletwo
183
\let\chaptermark\@gobble
184
\let\sectionmark\@gobble
187
\newcommand\maketitle{\begin{titlepage}%
188
\let\footnotesize\small
189
\let\footnoterule\relax
190
\let \footnote \thanks
194
{\LARGE \@title \par}%
198
\begin{tabular}[t]{c}%
202
{\large \@date \par}% % Set date in \large size.
207
\setcounter{footnote}{0}%
208
\global\let\thanks\relax
209
\global\let\maketitle\relax
210
\global\let\@thanks\@empty
211
\global\let\@author\@empty
212
\global\let\@date\@empty
213
\global\let\@title\@empty
214
\global\let\title\relax
215
\global\let\author\relax
216
\global\let\date\relax
217
\global\let\and\relax
220
\newcommand\maketitle{\par
222
\renewcommand\thefootnote{\@fnsymbol\c@footnote}%
223
\def\@makefnmark{\rlap{\@textsuperscript{\normalfont\@thefnmark}}}%
224
\long\def\@makefntext##1{\parindent 1em\noindent
226
\hss\@textsuperscript{\normalfont\@thefnmark}}##1}%
228
\ifnum \col@number=\@ne
231
\twocolumn[\@maketitle]%
235
\global\@topnum\z@ % Prevents figures from going at top of page.
238
\thispagestyle{plain}\@thanks
240
\setcounter{footnote}{0}%
241
\global\let\thanks\relax
242
\global\let\maketitle\relax
243
\global\let\@maketitle\relax
244
\global\let\@thanks\@empty
245
\global\let\@author\@empty
246
\global\let\@date\@empty
247
\global\let\@title\@empty
248
\global\let\title\relax
249
\global\let\author\relax
250
\global\let\date\relax
251
\global\let\and\relax
258
\let \footnote \thanks
259
{\LARGE \@title \par}%
263
\begin{tabular}[t]{c}%
272
\newcommand*\chaptermark[1]{}
273
\setcounter{secnumdepth}{2}
275
\newcounter {chapter}
276
\newcounter {section}[chapter]
277
\newcounter {subsection}[section]
278
\newcounter {subsubsection}[subsection]
279
\newcounter {paragraph}[subsubsection]
280
\newcounter {subparagraph}[paragraph]
281
\renewcommand \thepart {\@Roman\c@part}
282
\renewcommand \thechapter {\@arabic\c@chapter}
283
\renewcommand \thesection {\thechapter.\@arabic\c@section}
284
\renewcommand\thesubsection {\thesection.\@arabic\c@subsection}
285
\renewcommand\thesubsubsection{\thesubsection .\@arabic\c@subsubsection}
286
\renewcommand\theparagraph {\thesubsubsection.\@arabic\c@paragraph}
287
\renewcommand\thesubparagraph {\theparagraph.\@arabic\c@subparagraph}
288
\newcommand\@chapapp{\chaptername}
295
\thispagestyle{plain}%
303
\secdef\@part\@spart}
306
\ifnum \c@secnumdepth >-2\relax
307
\refstepcounter{part}%
308
\addcontentsline{toc}{part}{\thepart\hspace{1em}#1}%
310
\addcontentsline{toc}{part}{#1}%
314
\interlinepenalty \@M
316
\ifnum \c@secnumdepth >-2\relax
317
\huge\bfseries \partname\nobreakspace\thepart
321
\Huge \bfseries #2\par}%
325
\interlinepenalty \@M
327
\Huge \bfseries #1\par}%
329
\def\@endpart{\vfil\newpage
333
\thispagestyle{empty}%
340
\newcommand\chapter{\if@openright\cleardoublepage\else\clearpage\fi
341
\thispagestyle{plain}%
344
\secdef\@chapter\@schapter}
345
\def\@chapter[#1]#2{\ifnum \c@secnumdepth >\m@ne
346
\refstepcounter{chapter}%
347
\typeout{\@chapapp\space\thechapter.}%
348
\addcontentsline{toc}{chapter}%
349
{\protect\numberline{\thechapter}#1}%
351
\addcontentsline{toc}{chapter}{#1}%
354
\addtocontents{lof}{\protect\addvspace{10\p@}}%
355
\addtocontents{lot}{\protect\addvspace{10\p@}}%
357
\@topnewpage[\@makechapterhead{#2}]%
359
\@makechapterhead{#2}%
362
\def\@makechapterhead#1{%
364
{\parindent \z@ \raggedright \normalfont
365
% Added centering, changed font to Large (14pt) and stripped out newline
366
% beween chapter label and chapter name and use a colon : rather
368
\ifnum \c@secnumdepth >\m@ne
369
\Large\bfseries \@chapapp\space \thechapter
373
\Large \bfseries #1\par\nobreak
376
% end of changes by Tim
378
\def\@schapter#1{\if@twocolumn
379
\@topnewpage[\@makeschapterhead{#1}]%
381
\@makeschapterhead{#1}%
384
\def\@makeschapterhead#1{%
386
{\parindent \z@ \raggedright
389
\Huge \bfseries #1\par\nobreak
392
\newcommand\section{\@startsection {section}{1}{\z@}%
393
{-3.5ex \@plus -1ex \@minus -.2ex}%
395
{\normalfont\large\bfseries}}
396
\newcommand\subsection{\@startsection{subsection}{2}{\z@}%
397
{-3.25ex\@plus -1ex \@minus -.2ex}%
399
{\normalfont\large\bfseries}}
400
\newcommand\subsubsection{\@startsection{subsubsection}{3}{\z@}%
401
{-3.25ex\@plus -1ex \@minus -.2ex}%
403
{\normalfont\large\bfseries}}
404
\newcommand\paragraph{\@startsection{paragraph}{4}{\z@}%
405
{3.25ex \@plus1ex \@minus.2ex}%
407
{\normalfont\normalsize\bfseries}}
408
\newcommand\subparagraph{\@startsection{subparagraph}{5}{\parindent}%
409
{3.25ex \@plus1ex \@minus .2ex}%
411
{\normalfont\normalsize\bfseries}}
413
\setlength\leftmargini {2em}
415
\setlength\leftmargini {2.5em}
417
\leftmargin \leftmargini
418
\setlength\leftmarginii {2.2em}
419
\setlength\leftmarginiii {1.87em}
420
\setlength\leftmarginiv {1.7em}
422
\setlength\leftmarginv {.5em}
423
\setlength\leftmarginvi {.5em}
425
\setlength\leftmarginv {1em}
426
\setlength\leftmarginvi {1em}
428
\setlength \labelsep {.5em}
429
\setlength \labelwidth{\leftmargini}
430
\addtolength\labelwidth{-\labelsep}
431
\@beginparpenalty -\@lowpenalty
432
\@endparpenalty -\@lowpenalty
433
\@itempenalty -\@lowpenalty
434
\renewcommand\theenumi{\@arabic\c@enumi}
435
\renewcommand\theenumii{\@alph\c@enumii}
436
\renewcommand\theenumiii{\@roman\c@enumiii}
437
\renewcommand\theenumiv{\@Alph\c@enumiv}
438
\newcommand\labelenumi{\theenumi.}
439
\newcommand\labelenumii{(\theenumii)}
440
\newcommand\labelenumiii{\theenumiii.}
441
\newcommand\labelenumiv{\theenumiv.}
442
\renewcommand\p@enumii{\theenumi}
443
\renewcommand\p@enumiii{\theenumi(\theenumii)}
444
\renewcommand\p@enumiv{\p@enumiii\theenumiii}
445
\newcommand\labelitemi{\textbullet}
446
\newcommand\labelitemii{\normalfont\bfseries \textendash}
447
\newcommand\labelitemiii{\textasteriskcentered}
448
\newcommand\labelitemiv{\textperiodcentered}
449
\newenvironment{description}
450
{\list{}{\labelwidth\z@ \itemindent-\leftmargin
451
\let\makelabel\descriptionlabel}}
453
\newcommand*\descriptionlabel[1]{\hspace\labelsep
454
\normalfont\bfseries #1}
456
\newenvironment{abstract}{%
459
\@beginparpenalty\@lowpenalty
461
\bfseries \abstractname
464
{\par\vfil\null\endtitlepage}
466
\newenvironment{abstract}{%
468
\section*{\abstractname}%
472
{\bfseries \abstractname\vspace{-.5em}\vspace{\z@}}%
476
{\if@twocolumn\else\endquotation\fi}
478
\newenvironment{verse}
482
\listparindent\itemindent
483
\rightmargin \leftmargin
484
\advance\leftmargin 1.5em}%
487
\newenvironment{quotation}
488
{\list{}{\listparindent 1.5em%
489
\itemindent \listparindent
490
\rightmargin \leftmargin
491
\parsep \z@ \@plus\p@}%
494
\newenvironment{quote}
495
{\list{}{\rightmargin\leftmargin}%
499
\newenvironment{titlepage}
502
\@restonecoltrue\onecolumn
504
\@restonecolfalse\newpage
506
\thispagestyle{empty}%
509
{\if@restonecol\twocolumn \else \newpage \fi
512
\newenvironment{titlepage}
515
\@restonecoltrue\onecolumn
517
\@restonecolfalse\newpage
519
\thispagestyle{empty}%
520
\setcounter{page}\@ne
522
{\if@restonecol\twocolumn \else \newpage \fi
524
\setcounter{page}\@ne
528
\newcommand\appendix{\par
529
\setcounter{chapter}{0}%
530
\setcounter{section}{0}%
531
\gdef\@chapapp{\appendixname}%
532
\gdef\thechapter{\@Alph\c@chapter}}
533
\setlength\arraycolsep{5\p@}
534
\setlength\tabcolsep{6\p@}
535
\setlength\arrayrulewidth{.4\p@}
536
\setlength\doublerulesep{2\p@}
537
\setlength\tabbingsep{\labelsep}
538
\skip\@mpfootins = \skip\footins
539
\setlength\fboxsep{3\p@}
540
\setlength\fboxrule{.4\p@}
541
\@addtoreset {equation}{chapter}
542
\renewcommand\theequation
543
{\ifnum \c@chapter>\z@ \thechapter.\fi \@arabic\c@equation}
544
\newcounter{figure}[chapter]
545
\renewcommand \thefigure
546
{\ifnum \c@chapter>\z@ \thechapter.\fi \@arabic\c@figure}
550
\def\fnum@figure{\figurename\nobreakspace\thefigure}
551
\newenvironment{figure}
554
\newenvironment{figure*}
557
\newcounter{table}[chapter]
558
\renewcommand \thetable
559
{\ifnum \c@chapter>\z@ \thechapter.\fi \@arabic\c@table}
563
\def\fnum@table{\tablename\nobreakspace\thetable}
564
\newenvironment{table}
567
\newenvironment{table*}
570
\newlength\abovecaptionskip
571
\newlength\belowcaptionskip
572
\setlength\abovecaptionskip{10\p@}
573
\setlength\belowcaptionskip{0\p@}
574
\long\def\@makecaption#1#2{%
575
\vskip\abovecaptionskip
576
\sbox\@tempboxa{#1: #2}%
577
\ifdim \wd\@tempboxa >\hsize
580
\global \@minipagefalse
581
\hb@xt@\hsize{\hfil\box\@tempboxa\hfil}%
583
\vskip\belowcaptionskip}
584
\DeclareOldFontCommand{\rm}{\normalfont\rmfamily}{\mathrm}
585
\DeclareOldFontCommand{\sf}{\normalfont\sffamily}{\mathsf}
586
\DeclareOldFontCommand{\tt}{\normalfont\ttfamily}{\mathtt}
587
\DeclareOldFontCommand{\bf}{\normalfont\bfseries}{\mathbf}
588
\DeclareOldFontCommand{\it}{\normalfont\itshape}{\mathit}
589
\DeclareOldFontCommand{\sl}{\normalfont\slshape}{\@nomath\sl}
590
\DeclareOldFontCommand{\sc}{\normalfont\scshape}{\@nomath\sc}
591
\DeclareRobustCommand*\cal{\@fontswitch\relax\mathcal}
592
\DeclareRobustCommand*\mit{\@fontswitch\relax\mathnormal}
593
\newcommand\@pnumwidth{1.55em}
594
\newcommand\@tocrmarg{2.55em}
595
\newcommand\@dotsep{4.5}
596
\setcounter{tocdepth}{2}
597
\newcommand\tableofcontents{%
599
\@restonecoltrue\onecolumn
604
\begin{center} % Added by Tim to center contents heading
606
\end{center} % Added by Tim to center contents heading
608
\MakeUppercase\contentsname}{\MakeUppercase\contentsname}}%
610
\if@restonecol\twocolumn\fi
612
\newcommand*\l@part[2]{%
613
\ifnum \c@tocdepth >-2\relax
614
\addpenalty{-\@highpenalty}%
615
\addvspace{2.25em \@plus\p@}%
616
\setlength\@tempdima{3em}%
618
\parindent \z@ \rightskip \@pnumwidth
619
\parfillskip -\@pnumwidth
621
\large \bfseries #1\hfil \hb@xt@\@pnumwidth{\hss #2}}\par
624
\everypar{\global\@nobreakfalse\everypar{}}%
627
\newcommand*\l@chapter[2]{%
628
\ifnum \c@tocdepth >\m@ne
629
\addpenalty{-\@highpenalty}%
630
\vskip 1.0em \@plus\p@
631
\setlength\@tempdima{1.5em}%
633
\parindent \z@ \rightskip \@pnumwidth
634
\parfillskip -\@pnumwidth
635
\leavevmode \bfseries
636
\advance\leftskip\@tempdima
638
#1\nobreak\hfil \nobreak\hb@xt@\@pnumwidth{\hss #2}\par
639
\penalty\@highpenalty
642
\newcommand*\l@section{\@dottedtocline{1}{1.5em}{2.3em}}
643
\newcommand*\l@subsection{\@dottedtocline{2}{3.8em}{3.2em}}
644
\newcommand*\l@subsubsection{\@dottedtocline{3}{7.0em}{4.1em}}
645
\newcommand*\l@paragraph{\@dottedtocline{4}{10em}{5em}}
646
\newcommand*\l@subparagraph{\@dottedtocline{5}{12em}{6em}}
647
\newcommand\listoffigures{%
649
\@restonecoltrue\onecolumn
653
\chapter*{\listfigurename}%
654
\@mkboth{\MakeUppercase\listfigurename}%
655
{\MakeUppercase\listfigurename}%
657
\if@restonecol\twocolumn\fi
659
\newcommand*\l@figure{\@dottedtocline{1}{1.5em}{2.3em}}
660
\newcommand\listoftables{%
662
\@restonecoltrue\onecolumn
666
\chapter*{\listtablename}%
668
\MakeUppercase\listtablename}%
669
{\MakeUppercase\listtablename}%
671
\if@restonecol\twocolumn\fi
673
\let\l@table\l@figure
675
\setlength\bibindent{1.5em}
676
\newenvironment{thebibliography}[1]
677
{\chapter*{\bibname}%
678
\@mkboth{\MakeUppercase\bibname}{\MakeUppercase\bibname}%
679
\list{\@biblabel{\@arabic\c@enumiv}}%
680
{\settowidth\labelwidth{\@biblabel{#1}}%
681
\leftmargin\labelwidth
682
\advance\leftmargin\labelsep
686
\renewcommand\theenumiv{\@arabic\c@enumiv}}%
689
\@clubpenalty \clubpenalty
693
{\@latex@warning{Empty `thebibliography' environment}}%
695
\newcommand\newblock{\hskip .11em\@plus.33em\@minus.07em}
696
\let\@openbib@code\@empty
697
\newenvironment{theindex}
705
\twocolumn[\@makeschapterhead{\indexname}]%
706
\@mkboth{\MakeUppercase\indexname}%
707
{\MakeUppercase\indexname}%
708
\thispagestyle{plain}\parindent\z@
709
\parskip\z@ \@plus .3\p@\relax
711
{\if@restonecol\onecolumn\else\clearpage\fi}
712
\newcommand\@idxitem{\par\hangindent 40\p@}
713
\newcommand\subitem{\@idxitem \hspace*{20\p@}}
714
\newcommand\subsubitem{\@idxitem \hspace*{30\p@}}
715
\newcommand\indexspace{\par \vskip 10\p@ \@plus5\p@ \@minus3\p@\relax}
716
\renewcommand\footnoterule{%
718
\hrule\@width.4\columnwidth
720
\@addtoreset{footnote}{chapter}
721
\newcommand\@makefntext[1]{%
724
\hb@xt@1.8em{\hss\@makefnmark}#1}
725
\newcommand\contentsname{CONTENTS}
726
\newcommand\listfigurename{FIGURES}
727
\newcommand\listtablename{TABLES}
728
\newcommand\bibname{REFERENCES}
729
\newcommand\indexname{INDEX}
730
\newcommand\figurename{Figure}
731
\newcommand\tablename{Table}
732
\newcommand\partname{PART}
733
\newcommand\chaptername{CHAPTER}
734
\newcommand\appendixname{APPENDIX}
735
\newcommand\abstractname{ABSTRACT}
736
\def\today{\ifcase\month\or
737
January\or February\or March\or April\or May\or June\or
738
July\or August\or September\or October\or November\or December\fi
739
\space\number\day, \number\year}
740
\setlength\columnsep{10\p@}
741
\setlength\columnseprule{0\p@}
743
\pagenumbering{arabic}
757
%% %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
758
%% FOLLOWING ADDED BY TIM AND NOT PART OF STANDARD REPORT CLASS
759
%% %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
764
%% End of file `timthesis.cls'.