Browse Source

Add AISTATS style

arxiv-v1
Markus Kaiser 7 months ago
parent
commit
52e71cf176
4 changed files with 887 additions and 27 deletions
  1. 391
    0
      aistats2019.sty
  2. 10
    26
      dynamic_dirichlet_deep_gp.tex
  3. 485
    0
      fancyhdr.sty
  4. 1
    1
      preamble/packages.tex

+ 391
- 0
aistats2019.sty View File

@@ -0,0 +1,391 @@
1
+% File:  aistats2019.sty
2
+
3
+% Modified Atsushi Miyauchi, Mirai Tanaka and Akiko Takeda, 2018: changed venue,
4
+% year, volume number, and heading for the references, and removed tiny bugs.
5
+% 
6
+% Modified Fernando Perez-Cruz, 2017: changed venue, year, and volume number.
7
+%
8
+% Modified Scott Alfeld, 2016: changed venue, year, and volume number.
9
+%
10
+% Modified Zoltan Szabo, 2015: change venue, year, volume number.
11
+%
12
+% Modified Antti Honkela, 2013: change venue, year
13
+%
14
+% Modified Miro Dudik, 2011, 2012: change venue, year and volume number
15
+%
16
+% Modified Geoff Gordon, 2010: change to 2011
17
+%
18
+% Modified Mauricio Alvarez, 2009. Headings for the manuscript when
19
+% being under review and additional changes so that the headings are
20
+% automatically obtained from the title and author fields from the tex
21
+% file. Also changes to the year 2009 for 2010 where it appeared.
22
+%
23
+% Modified Mauricio Alvarez, 2009. Copyright Notice and commands for headings
24
+%
25
+%
26
+% Originally this file contains the LaTeX formatting parameters for the Morgan
27
+% Kaufmann two column, 8 1/2 by 11 inch proceedings format.
28
+
29
+
30
+\NeedsTeXFormat{LaTeX2e}
31
+
32
+\ProvidesPackage{aistats2019}
33
+
34
+\RequirePackage{amsmath}
35
+
36
+\DeclareOption{accepted}{\renewcommand{\statePaper}{\acceptedPaper}%
37
+                         \renewcommand{\Notice@String}{\AISTATS@appearing}}
38
+
39
+\newcommand{\statePaper}{0}
40
+\newcommand{\acceptedPaper}{1}
41
+\newcommand{\Notice@String}{Preliminary work.  Under review by AISTATS 2019.  Do not distribute.}
42
+\newcommand{\AISTATS@appearing}{Proceedings of the 22\textsuperscript{nd} International Conference on Artificial
43
+  Intelligence and Statistics (AISTATS) 2019, Naha, Okinawa, Japan\@. PMLR: Volume 89. Copyright
44
+  2019 by the author(s).}
45
+
46
+\ProcessOptions\relax
47
+
48
+\evensidemargin .05in \oddsidemargin .05in
49
+\setlength\topmargin{-25pt} \setlength\textheight{9.25in}
50
+\setlength\textwidth{6.75in} \setlength\columnsep{0.25in}
51
+\newlength\titlebox \setlength\titlebox{2.375in}
52
+\setlength\headheight{10pt} \setlength\headsep{15pt}
53
+
54
+
55
+%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
56
+%%%% To include the copyright legend at the end of
57
+%%%% the first column of the first page. Adapted from ICML09.sty
58
+%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
59
+\def\ftype@copyrightbox{8}
60
+\def\@copyrightspace{
61
+% Create a float object positioned at the bottom of the column.  Note
62
+% that because of the mystical nature of floats, this has to be called
63
+% before the first column is populated with text (e.g., from the title
64
+% or abstract blocks).  Otherwise, the text will force the float to
65
+% the next column.  -- TDRL.
66
+\@float{copyrightbox}[b]
67
+\begin{center}
68
+\setlength{\unitlength}{1pc}
69
+\begin{picture}(20,2.5)
70
+% Create a line separating the main text from the note block.
71
+% 4.818pc==0.8in.
72
+\put(0,3.5){\line(1,0){4.818}}
73
+% Insert the text string itself.  Note that the string has to be
74
+% enclosed in a parbox -- the \put call needs a box object to
75
+% position.  Without the parbox, the text gets splattered across the
76
+% bottom of the page semi-randomly.  The 19.75pc distance seems to be
77
+% the width of the column, though I can't find an appropriate distance
78
+% variable to substitute here.  -- TDRL.
79
+\put(0,0){\parbox[b]{19.75pc}{\small \Notice@String}}
80
+\end{picture}
81
+\end{center}
82
+\end@float}
83
+%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
84
+%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
85
+
86
+\setlength\footskip{0pt}
87
+\thispagestyle{empty}     \pagestyle{empty}
88
+\flushbottom \twocolumn \sloppy
89
+
90
+\def\addcontentsline#1#2#3{}
91
+
92
+
93
+%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
94
+%%%%%%     Definition of maketitle (includes title and author)
95
+%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
96
+
97
+\RequirePackage{fancyhdr}
98
+
99
+% box to check the size of the running head
100
+\newbox\titrun
101
+\newbox\autrun
102
+
103
+% general page style
104
+\pagestyle{fancy}
105
+\renewcommand{\headrulewidth}{0pt}
106
+
107
+\fancyhead{}
108
+\fancyfoot{}
109
+
110
+% definition to set running head title and running head author
111
+\def\runningtitle#1{\gdef\@runningtitle{#1}}
112
+\def\runningauthor#1{\gdef\@runningauthor{#1}}
113
+
114
+\long\def\aistatstitle#1{
115
+
116
+   %\renewcommand{\headrulewidth}{0.5pt}
117
+
118
+   \gdef\@runningheadingerrortitle{0}
119
+
120
+   % If paper is under review print this as headings
121
+
122
+   \ifnum\statePaper=0
123
+    {
124
+     \gdef\@runningtitle{Manuscript under review by AISTATS 2019}
125
+    }
126
+   \fi
127
+
128
+   % If the paper is accepted, print the title or the running title as heading.
129
+
130
+   \ifnum\statePaper=1
131
+   {
132
+   \ifx\undefined\@runningtitle
133
+    {
134
+    \gdef\@runningtitle{#1}
135
+    }
136
+   \fi
137
+   }
138
+   \fi
139
+
140
+   \ifnum\@runningheadingerrortitle=0
141
+         {
142
+         \global\setbox\titrun=\vbox{\small\bfseries\@runningtitle}%
143
+         \ifdim\wd\titrun>\textwidth%
144
+            {\gdef\@runningheadingerrortitle{2}
145
+             \gdef\@messagetitle{Running heading title too long}
146
+            }%
147
+         \else\ifdim\ht\titrun>10pt
148
+              {\gdef\@runningheadingerrortitle{3}
149
+              \gdef\@messagetitle{Running heading title breaks the line}
150
+              }%
151
+              \fi
152
+          \fi
153
+         }
154
+    \fi
155
+
156
+   \ifnum\@runningheadingerrortitle>0
157
+     {
158
+        \fancyhead[CE]{\small\bfseries\@messagetitle}
159
+        \ifnum\@runningheadingerrortitle>1
160
+           \typeout{}%
161
+           \typeout{}%
162
+           \typeout{*******************************************************}%
163
+           \typeout{Running heading title exceeds size limitations for running head.}%
164
+           \typeout{Please supply a shorter form for the running head}
165
+           \typeout{with \string\runningtitle{...}\space just after \string\begin{document}}%
166
+           \typeout{*******************************************************}%
167
+           \typeout{}%
168
+           \typeout{}%
169
+        \fi
170
+     }
171
+  \else
172
+     {
173
+          \fancyhead[CE]{\small\bfseries\@runningtitle}
174
+     }
175
+  \fi
176
+
177
+  \hsize\textwidth
178
+  \linewidth\hsize \toptitlebar {\centering
179
+  {\Large\bfseries #1 \par}}
180
+ \bottomtitlebar \vskip 0.2in plus 1fil minus 0.1in
181
+}
182
+
183
+\long\def\aistatsauthor#1{
184
+
185
+   \gdef\@runningheadingerrorauthor{0}
186
+
187
+   % If the paper is under review, print this message as heading.
188
+
189
+   \ifnum\statePaper=0
190
+    {
191
+     \gdef\@runningauthor{Manuscript under review by AISTATS 2019}
192
+    }
193
+   \fi
194
+
195
+   % If the paper is accepted, print the author names or runningauthor as heading.
196
+
197
+   \ifnum\statePaper=1
198
+   {
199
+   \ifx\undefined\@runningauthor%
200
+    {
201
+   \gdef\@runningauthor{\def\and{\unskip{,}\enspace}\def\And{\unskip{,}\enspace}\def\AND{\unskip{,}\enspace}
202
+   #1}
203
+    }
204
+   \fi
205
+    }
206
+   \fi
207
+
208
+  \ifnum\@runningheadingerrorauthor=0
209
+      {
210
+      \global\setbox\autrun=\vbox{\small\bfseries\@runningauthor}
211
+      \ifdim\wd\autrun>\textwidth%
212
+            {\gdef\@runningheadingerrorauthor{2}
213
+             \gdef\@messageauthor{Running heading author too long}
214
+            }%
215
+         \else\ifdim\ht\autrun>10pt
216
+              {\gdef\@runningheadingerrorauthor{3}
217
+              \gdef\@messageauthor{Running heading author breaks the line}
218
+              }%
219
+              \fi
220
+          \fi
221
+      }
222
+  \fi
223
+
224
+  \ifnum\@runningheadingerrorauthor>0
225
+     {
226
+       \fancyhead[CO]{\small\bfseries\@messageauthor}
227
+       \ifnum\@runningheadingerrorauthor>1
228
+           \typeout{}%
229
+           \typeout{}%
230
+           \typeout{*******************************************************}%
231
+           \typeout{Running heading author exceeds size limitations for running head.}%
232
+           \typeout{Please supply a shorter form for the running head}
233
+           \typeout{with \string\runningauthor{...}\space just after \string\begin{document}}%
234
+           \typeout{*******************************************************}%
235
+           \typeout{}%
236
+           \typeout{}%
237
+      \fi
238
+     }
239
+  \else
240
+     {
241
+     \fancyhead[CO]{\small\bfseries\@runningauthor}
242
+     }
243
+  \fi
244
+
245
+
246
+{\def\and{\unskip\enspace{\rm and}\enspace}%
247
+  \def\And{\end{tabular}\hss \egroup \hskip 1in plus 2fil
248
+           \hbox to 0pt\bgroup\hss \begin{tabular}[t]{c}\bfseries}%
249
+  \def\AND{\end{tabular}\hss\egroup \hfil\hfil\egroup
250
+         \vskip 0.25in plus 1fil minus 0.125in
251
+          \hbox to \linewidth\bgroup \hfil\hfil
252
+            \hbox to 0pt\bgroup\hss \begin{tabular}[t]{c}\bfseries}
253
+  \def\ANDD{\end{tabular}\hss\egroup \hfil\hfil\egroup
254
+         \vskip 0.25in plus 1fil minus 0.125in
255
+          \hbox to \linewidth\bgroup \hfil\hfil
256
+            \hbox to 0pt\bgroup\hss \begin{tabular}[t]{c}\bfseries}
257
+     \hbox to \linewidth\bgroup \hfil\hfil
258
+     \hbox to 0pt\bgroup\hss \begin{tabular}[t]{c}\bfseries #1
259
+                         \end{tabular}
260
+       \hss\egroup
261
+    \hfil\hfil\egroup}
262
+}
263
+
264
+\long\def\aistatsaddress#1{
265
+{\def\and{\unskip\enspace{\rm and}\enspace}%
266
+  \def\And{\end{tabular}\hss \egroup \hskip 1in plus 2fil
267
+           \hbox to 0pt\bgroup\hss \begin{tabular}[t]{c} }%
268
+  \def\AND{\end{tabular}\hss\egroup \hfil\hfil\egroup
269
+         \vskip 0.25in plus 1fil minus 0.125in
270
+          \hbox to \linewidth\bgroup \hfil\hfil
271
+            \hbox to 0pt  \bgroup \hss \begin{tabular}[t]{c}}
272
+   \def\ANDD{\end{tabular}\hss\egroup \hfil\hfil\egroup
273
+         \vskip 0.25in plus 1fil minus 0.125in
274
+          \hbox to \linewidth \bgroup \hfil\hfil
275
+            \hbox to 0pt  \bgroup \hss\begin{tabular}[t]{c}\bfseries}
276
+     \hbox to \linewidth\bgroup \hfil\hfil
277
+     \hbox to 0pt\bgroup\hss \begin{tabular}[t]{c} #1
278
+                         \end{tabular}
279
+       \hss\egroup
280
+    \hfil\hfil\egroup}
281
+  \vskip 0.3in plus 2fil minus 0.1in
282
+}
283
+
284
+\renewcommand{\headrulewidth}{0.5pt}
285
+
286
+%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
287
+%%%  Definition of abstract environment
288
+%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
289
+
290
+\renewenvironment{abstract}
291
+{\@copyrightspace\centerline{\large\bfseries
292
+Abstract}\vspace{0.5ex}\begin{quote}}{\par\end{quote}\vskip 1ex}
293
+
294
+% sections with less space
295
+\def\section{\@startsection {section}{1}{\z@}{-2.0ex plus
296
+    -0.5ex minus -.2ex}{1.5ex plus 0.3ex minus .2ex}{\large\bfseries\raggedright}}
297
+\def\subsection{\@startsection{subsection}{2}{\z@}{-1.8ex plus
298
+    -0.5ex minus -.2ex}{0.8ex plus .2ex}{\normalsize\bfseries\raggedright}}
299
+\def\subsubsection{\@startsection{subsubsection}{3}{\z@}{-1.5ex plus
300
+   -0.5ex minus -.2ex}{0.5ex plus .2ex}{\normalsize\bfseries\raggedright}}
301
+\def\paragraph{\@startsection{paragraph}{4}{\z@}{1.5ex plus
302
+   0.5ex minus .2ex}{-1em}{\normalsize\bfseries}}
303
+\def\subparagraph{\@startsection{subparagraph}{5}{\z@}{1.5ex plus
304
+   0.5ex minus .2ex}{-1em}{\normalsize\bfseries}}
305
+\def\subsubsubsection{\vskip 5pt{\noindent\normalsize\rm\raggedright}}
306
+
307
+
308
+% Footnotes
309
+\footnotesep 6.65pt %
310
+\skip\footins 9pt plus 4pt minus 2pt
311
+\def\footnoterule{\kern-3pt \hrule width 5pc \kern 2.6pt }
312
+\setcounter{footnote}{0}
313
+
314
+% Lists and paragraphs
315
+\parindent 0pt
316
+\topsep 4pt plus 1pt minus 2pt
317
+\partopsep 1pt plus 0.5pt minus 0.5pt
318
+\itemsep 2pt plus 1pt minus 0.5pt
319
+\parsep 2pt plus 1pt minus 0.5pt
320
+\parskip .5pc
321
+
322
+
323
+\leftmargin 2em \leftmargini\leftmargin \leftmarginii 2em
324
+\leftmarginiii 1.5em \leftmarginiv 1.0em \leftmarginv .5em
325
+\leftmarginvi .5em
326
+\labelwidth\leftmargini\advance\labelwidth-\labelsep \labelsep 5pt
327
+
328
+\def\@listi{\leftmargin\leftmargini}
329
+\def\@listii{\leftmargin\leftmarginii
330
+   \labelwidth\leftmarginii\advance\labelwidth-\labelsep
331
+   \topsep 2pt plus 1pt minus 0.5pt
332
+   \parsep 1pt plus 0.5pt minus 0.5pt
333
+   \itemsep \parsep}
334
+\def\@listiii{\leftmargin\leftmarginiii
335
+    \labelwidth\leftmarginiii\advance\labelwidth-\labelsep
336
+    \topsep 1pt plus 0.5pt minus 0.5pt
337
+    \parsep \z@ \partopsep 0.5pt plus 0pt minus 0.5pt
338
+    \itemsep \topsep}
339
+\def\@listiv{\leftmargin\leftmarginiv
340
+     \labelwidth\leftmarginiv\advance\labelwidth-\labelsep}
341
+\def\@listv{\leftmargin\leftmarginv
342
+     \labelwidth\leftmarginv\advance\labelwidth-\labelsep}
343
+\def\@listvi{\leftmargin\leftmarginvi
344
+     \labelwidth\leftmarginvi\advance\labelwidth-\labelsep}
345
+
346
+\abovedisplayskip 7pt plus2pt minus5pt%
347
+\belowdisplayskip \abovedisplayskip
348
+\abovedisplayshortskip  0pt plus3pt%
349
+\belowdisplayshortskip  4pt plus3pt minus3pt%
350
+
351
+% Less leading in most fonts (due to the narrow columns)
352
+% The choices were between 1-pt and 1.5-pt leading
353
+\def\@normalsize{\@setsize\normalsize{11pt}\xpt\@xpt}
354
+\def\small{\@setsize\small{10pt}\ixpt\@ixpt}
355
+\def\footnotesize{\@setsize\footnotesize{10pt}\ixpt\@ixpt}
356
+\def\scriptsize{\@setsize\scriptsize{8pt}\viipt\@viipt}
357
+\def\tiny{\@setsize\tiny{7pt}\vipt\@vipt}
358
+\def\large{\@setsize\large{14pt}\xiipt\@xiipt}
359
+\def\Large{\@setsize\Large{16pt}\xivpt\@xivpt}
360
+\def\LARGE{\@setsize\LARGE{20pt}\xviipt\@xviipt}
361
+\def\huge{\@setsize\huge{23pt}\xxpt\@xxpt}
362
+\def\Huge{\@setsize\Huge{28pt}\xxvpt\@xxvpt}
363
+
364
+\def\toptitlebar{
365
+\hrule height4pt
366
+\vskip .25in}
367
+
368
+\def\bottomtitlebar{
369
+\vskip .25in
370
+\hrule height1pt
371
+\vskip .25in}
372
+
373
+\renewenvironment{thebibliography}[1]
374
+     {\subsubsection*{\refname}%
375
+      \@mkboth{\MakeUppercase\refname}{\MakeUppercase\refname}%
376
+      \list{\@biblabel{\@arabic\c@enumiv}}%
377
+           {\settowidth\labelwidth{\@biblabel{#1}}%
378
+            \leftmargin\labelwidth
379
+            \advance\leftmargin\labelsep
380
+            \@openbib@code
381
+            \usecounter{enumiv}%
382
+            \let\p@enumiv\@empty
383
+            \renewcommand\theenumiv{\@arabic\c@enumiv}}%
384
+      \sloppy
385
+      \clubpenalty4000
386
+      \@clubpenalty \clubpenalty
387
+      \widowpenalty4000%
388
+      \sfcode`\.\@m}
389
+     {\def\@noitemerr
390
+       {\@latex@warning{Empty `thebibliography' environment}}%
391
+      \endlist}

+ 10
- 26
dynamic_dirichlet_deep_gp.tex View File

@@ -15,33 +15,17 @@
15 15
 \addbibresource{zotero_export.bib}
16 16
 
17 17
 % We set this for hyperref
18
-\title{Dynamic Dirichlet Deep GP}
18
+\title{Dynamic Multi-Modal Deep Gaussian Processes}
19 19
 \author{\href{mailto:markus.kaiser@siemens.com}{Markus Kaiser}}
20 20
 
21
-\author{
22
-    % Markus Kaiser\\
23
-    % Siemens AG\\
24
-    % Technical University of Munich\\
25
-    % \texttt{markus.kaiser@siemens.com}\\
26
-    % \And
27
-    % Clemens Otte\\
28
-    % Siemens AG\\
29
-    % \texttt{clemens.otte@siemens.com}\\
30
-    % \And
31
-    % Thomas Runkler\\
32
-    % Siemens AG\\
33
-    % Technical University of Munich\\
34
-    % \texttt{thomas.runkler@siemens.com}\\
35
-    % \And
36
-    % Carl Henrik Ek\\
37
-    % University of Bristol\\
38
-    % \texttt{carlhenrik.ek@bristol.ac.uk}\\
39
-    % NOTE: Fix metadata.
40
-    Anonymous\\
41
-}
42
-
43 21
 \begin{document}
44
-\maketitle
22
+\twocolumn[
23
+
24
+\aistatstitle{Dynamic Multi-Modal Deep Gaussian Processes}
25
+
26
+\aistatsauthor{ Author 1 \And Author 2 \And  Author 3 }
27
+
28
+\aistatsaddress{ Institution 1 \And  Institution 2 \And Institution 3 } ]
45 29
 
46 30
 \begin{abstract}
47 31
     We propose a novel Bayesian approach to modelling nonlinear alignments of time series based on latent shared information.
@@ -60,10 +44,10 @@ Take wind power production, which is one of the major providers for renewable en
60 44
 To optimize the efficiency of a wind turbine the speed and pitch have to be controlled according to the local wind conditions (speed and direction).
61 45
 In a wind farm turbines are typically equipped with sensors for wind speed and direction.
62 46
 The goal is to use these sensor data to produce accurate estimates and forecasts of the wind conditions at every turbine in the farm.
63
-For the ideal case of a homogeneous and very slowly changing wind field, the wind conditions at each geometrical position in a wind farm can be estimated using the propagation times (time warps) computed from geometry, wind speed, and direction \parencite{soleimanzadeh_controller_2011,bitar_coordinated_2013,schepers_improved_2007}.
47
+For the ideal case of a homogeneous and very slowly changing wind field, the wind conditions at each geometrical position in a wind farm can be estimated using the propagation times (time warps) computed from geometry, wind speed, and direction .
64 48
 In the real world, however, wind fields are not homogeneous, exhibit global and local turbulences, and interfere with the turbines and the terrain inside and outside the farm and further, breaking sensors can lead to data loss.
65 49
 This makes it extremely difficult to construct accurate analytical models of wind propagation in a farm.
66
-Also, standard approaches for extracting such information from data, e.g.\ generalized time warping  \parencite{zhou_generalized_2012}, fail at this task because they rely on a high signal to noise ratio.
50
+Also, standard approaches for extracting such information from data, e.g.\ generalized time warping  , fail at this task because they rely on a high signal to noise ratio.
67 51
 Instead, we want to construct Bayesian nonlinear dynamic data based models for wind conditions and warpings which handle the stochastic nature of the system in a principled manner.
68 52
 
69 53
 \printbibliography

+ 485
- 0
fancyhdr.sty View File

@@ -0,0 +1,485 @@
1
+% fancyhdr.sty version 3.2
2
+% Fancy headers and footers for LaTeX.
3
+% Piet van Oostrum, 
4
+% Dept of Computer and Information Sciences, University of Utrecht,
5
+% Padualaan 14, P.O. Box 80.089, 3508 TB Utrecht, The Netherlands
6
+% Telephone: +31 30 2532180. Email: piet@cs.uu.nl
7
+% ========================================================================
8
+% LICENCE:
9
+% This file may be distributed under the terms of the LaTeX Project Public
10
+% License, as described in lppl.txt in the base LaTeX distribution.
11
+% Either version 1 or, at your option, any later version.
12
+% ========================================================================
13
+% MODIFICATION HISTORY:
14
+% Sep 16, 1994
15
+% version 1.4: Correction for use with \reversemargin
16
+% Sep 29, 1994:
17
+% version 1.5: Added the \iftopfloat, \ifbotfloat and \iffloatpage commands
18
+% Oct 4, 1994:
19
+% version 1.6: Reset single spacing in headers/footers for use with
20
+% setspace.sty or doublespace.sty
21
+% Oct 4, 1994:
22
+% version 1.7: changed \let\@mkboth\markboth to
23
+% \def\@mkboth{\protect\markboth} to make it more robust
24
+% Dec 5, 1994:
25
+% version 1.8: corrections for amsbook/amsart: define \@chapapp and (more
26
+% importantly) use the \chapter/sectionmark definitions from ps@headings if
27
+% they exist (which should be true for all standard classes).
28
+% May 31, 1995:
29
+% version 1.9: The proposed \renewcommand{\headrulewidth}{\iffloatpage...
30
+% construction in the doc did not work properly with the fancyplain style. 
31
+% June 1, 1995:
32
+% version 1.91: The definition of \@mkboth wasn't restored on subsequent
33
+% \pagestyle{fancy}'s.
34
+% June 1, 1995:
35
+% version 1.92: The sequence \pagestyle{fancyplain} \pagestyle{plain}
36
+% \pagestyle{fancy} would erroneously select the plain version.
37
+% June 1, 1995:
38
+% version 1.93: \fancypagestyle command added.
39
+% Dec 11, 1995:
40
+% version 1.94: suggested by Conrad Hughes <chughes@maths.tcd.ie>
41
+% CJCH, Dec 11, 1995: added \footruleskip to allow control over footrule
42
+% position (old hardcoded value of .3\normalbaselineskip is far too high
43
+% when used with very small footer fonts).
44
+% Jan 31, 1996:
45
+% version 1.95: call \@normalsize in the reset code if that is defined,
46
+% otherwise \normalsize.
47
+% this is to solve a problem with ucthesis.cls, as this doesn't
48
+% define \@currsize. Unfortunately for latex209 calling \normalsize doesn't
49
+% work as this is optimized to do very little, so there \@normalsize should
50
+% be called. Hopefully this code works for all versions of LaTeX known to
51
+% mankind.  
52
+% April 25, 1996:
53
+% version 1.96: initialize \headwidth to a magic (negative) value to catch
54
+% most common cases that people change it before calling \pagestyle{fancy}.
55
+% Note it can't be initialized when reading in this file, because
56
+% \textwidth could be changed afterwards. This is quite probable.
57
+% We also switch to \MakeUppercase rather than \uppercase and introduce a
58
+% \nouppercase command for use in headers. and footers.
59
+% May 3, 1996:
60
+% version 1.97: Two changes:
61
+% 1. Undo the change in version 1.8 (using the pagestyle{headings} defaults
62
+% for the chapter and section marks. The current version of amsbook and
63
+% amsart classes don't seem to need them anymore. Moreover the standard
64
+% latex classes don't use \markboth if twoside isn't selected, and this is
65
+% confusing as \leftmark doesn't work as expected.
66
+% 2. include a call to \ps@empty in ps@@fancy. This is to solve a problem
67
+% in the amsbook and amsart classes, that make global changes to \topskip,
68
+% which are reset in \ps@empty. Hopefully this doesn't break other things.
69
+% May 7, 1996:
70
+% version 1.98:
71
+% Added % after the line  \def\nouppercase
72
+% May 7, 1996:
73
+% version 1.99: This is the alpha version of fancyhdr 2.0
74
+% Introduced the new commands \fancyhead, \fancyfoot, and \fancyhf.
75
+% Changed \headrulewidth, \footrulewidth, \footruleskip to
76
+% macros rather than length parameters, In this way they can be
77
+% conditionalized and they don't consume length registers. There is no need
78
+% to have them as length registers unless you want to do calculations with
79
+% them, which is unlikely. Note that this may make some uses of them
80
+% incompatible (i.e. if you have a file that uses \setlength or \xxxx=)
81
+% May 10, 1996:
82
+% version 1.99a:
83
+% Added a few more % signs
84
+% May 10, 1996:
85
+% version 1.99b:
86
+% Changed the syntax of \f@nfor to be resistent to catcode changes of :=
87
+% Removed the [1] from the defs of \lhead etc. because the parameter is
88
+% consumed by the \@[xy]lhead etc. macros.
89
+% June 24, 1997:
90
+% version 1.99c:
91
+% corrected \nouppercase to also include the protected form of \MakeUppercase
92
+% \global added to manipulation of \headwidth.
93
+% \iffootnote command added.
94
+% Some comments added about \@fancyhead and \@fancyfoot.
95
+% Aug 24, 1998
96
+% version 1.99d
97
+% Changed the default \ps@empty to \ps@@empty in order to allow
98
+% \fancypagestyle{empty} redefinition.
99
+% Oct 11, 2000
100
+% version 2.0
101
+% Added LPPL license clause.
102
+%
103
+% A check for \headheight is added. An errormessage is given (once) if the
104
+% header is too large. Empty headers don't generate the error even if
105
+% \headheight is very small or even 0pt. 
106
+% Warning added for the use of 'E' option when twoside option is not used.
107
+% In this case the 'E' fields will never be used.
108
+%
109
+% Mar 10, 2002
110
+% version 2.1beta
111
+% New command: \fancyhfoffset[place]{length}
112
+% defines offsets to be applied to the header/footer to let it stick into
113
+% the margins (if length > 0).
114
+% place is like in fancyhead, except that only E,O,L,R can be used.
115
+% This replaces the old calculation based on \headwidth and the marginpar
116
+% area.
117
+% \headwidth will be dynamically calculated in the headers/footers when
118
+% this is used.
119
+%
120
+% Mar 26, 2002
121
+% version 2.1beta2
122
+% \fancyhfoffset now also takes h,f as possible letters in the argument to
123
+% allow the header and footer widths to be different.
124
+% New commands \fancyheadoffset and \fancyfootoffset added comparable to
125
+% \fancyhead and \fancyfoot.
126
+% Errormessages and warnings have been made more informative.
127
+%
128
+% Dec 9, 2002
129
+% version 2.1
130
+% The defaults for \footrulewidth, \plainheadrulewidth and
131
+% \plainfootrulewidth are changed from \z@skip to 0pt. In this way when
132
+% someone inadvertantly uses \setlength to change any of these, the value
133
+% of \z@skip will not be changed, rather an errormessage will be given.
134
+
135
+% March 3, 2004
136
+% Release of version 3.0
137
+
138
+% Oct 7, 2004
139
+% version 3.1
140
+% Added '\endlinechar=13' to \fancy@reset to prevent problems with
141
+% includegraphics in header when verbatiminput is active.
142
+
143
+% March 22, 2005
144
+% version 3.2
145
+% reset \everypar (the real one) in \fancy@reset because spanish.ldf does
146
+% strange things with \everypar between << and >>.
147
+
148
+\def\ifancy@mpty#1{\def\temp@a{#1}\ifx\temp@a\@empty}
149
+
150
+\def\fancy@def#1#2{\ifancy@mpty{#2}\fancy@gbl\def#1{\leavevmode}\else
151
+                                   \fancy@gbl\def#1{#2\strut}\fi}
152
+
153
+\let\fancy@gbl\global
154
+
155
+\def\@fancyerrmsg#1{%
156
+        \ifx\PackageError\undefined
157
+        \errmessage{#1}\else
158
+        \PackageError{Fancyhdr}{#1}{}\fi}
159
+\def\@fancywarning#1{%
160
+        \ifx\PackageWarning\undefined
161
+        \errmessage{#1}\else
162
+        \PackageWarning{Fancyhdr}{#1}{}\fi}
163
+
164
+% Usage: \@forc \var{charstring}{command to be executed for each char}
165
+% This is similar to LaTeX's \@tfor, but expands the charstring.
166
+
167
+\def\@forc#1#2#3{\expandafter\f@rc\expandafter#1\expandafter{#2}{#3}}
168
+\def\f@rc#1#2#3{\def\temp@ty{#2}\ifx\@empty\temp@ty\else
169
+                                    \f@@rc#1#2\f@@rc{#3}\fi}
170
+\def\f@@rc#1#2#3\f@@rc#4{\def#1{#2}#4\f@rc#1{#3}{#4}}
171
+
172
+% Usage: \f@nfor\name:=list\do{body}
173
+% Like LaTeX's \@for but an empty list is treated as a list with an empty
174
+% element
175
+
176
+\newcommand{\f@nfor}[3]{\edef\@fortmp{#2}%
177
+    \expandafter\@forloop#2,\@nil,\@nil\@@#1{#3}}
178
+
179
+% Usage: \def@ult \cs{defaults}{argument}
180
+% sets \cs to the characters from defaults appearing in argument
181
+% or defaults if it would be empty. All characters are lowercased.
182
+
183
+\newcommand\def@ult[3]{%
184
+    \edef\temp@a{\lowercase{\edef\noexpand\temp@a{#3}}}\temp@a
185
+    \def#1{}%
186
+    \@forc\tmpf@ra{#2}%
187
+        {\expandafter\if@in\tmpf@ra\temp@a{\edef#1{#1\tmpf@ra}}{}}%
188
+    \ifx\@empty#1\def#1{#2}\fi}
189
+% 
190
+% \if@in <char><set><truecase><falsecase>
191
+%
192
+\newcommand{\if@in}[4]{%
193
+    \edef\temp@a{#2}\def\temp@b##1#1##2\temp@b{\def\temp@b{##1}}%
194
+    \expandafter\temp@b#2#1\temp@b\ifx\temp@a\temp@b #4\else #3\fi}
195
+
196
+\newcommand{\fancyhead}{\@ifnextchar[{\f@ncyhf\fancyhead h}%
197
+                                     {\f@ncyhf\fancyhead h[]}}
198
+\newcommand{\fancyfoot}{\@ifnextchar[{\f@ncyhf\fancyfoot f}%
199
+                                     {\f@ncyhf\fancyfoot f[]}}
200
+\newcommand{\fancyhf}{\@ifnextchar[{\f@ncyhf\fancyhf{}}%
201
+                                   {\f@ncyhf\fancyhf{}[]}}
202
+
203
+% New commands for offsets added
204
+
205
+\newcommand{\fancyheadoffset}{\@ifnextchar[{\f@ncyhfoffs\fancyheadoffset h}%
206
+                                           {\f@ncyhfoffs\fancyheadoffset h[]}}
207
+\newcommand{\fancyfootoffset}{\@ifnextchar[{\f@ncyhfoffs\fancyfootoffset f}%
208
+                                           {\f@ncyhfoffs\fancyfootoffset f[]}}
209
+\newcommand{\fancyhfoffset}{\@ifnextchar[{\f@ncyhfoffs\fancyhfoffset{}}%
210
+                                         {\f@ncyhfoffs\fancyhfoffset{}[]}}
211
+
212
+% The header and footer fields are stored in command sequences with
213
+% names of the form: \f@ncy<x><y><z> with <x> for [eo], <y> from [lcr]
214
+% and <z> from [hf].
215
+
216
+\def\f@ncyhf#1#2[#3]#4{%
217
+    \def\temp@c{}%
218
+    \@forc\tmpf@ra{#3}%
219
+        {\expandafter\if@in\tmpf@ra{eolcrhf,EOLCRHF}%
220
+            {}{\edef\temp@c{\temp@c\tmpf@ra}}}%
221
+    \ifx\@empty\temp@c\else
222
+        \@fancyerrmsg{Illegal char `\temp@c' in \string#1 argument:
223
+          [#3]}%
224
+    \fi
225
+    \f@nfor\temp@c{#3}%
226
+        {\def@ult\f@@@eo{eo}\temp@c
227
+         \if@twoside\else
228
+           \if\f@@@eo e\@fancywarning
229
+             {\string#1's `E' option without twoside option is useless}\fi\fi
230
+         \def@ult\f@@@lcr{lcr}\temp@c
231
+         \def@ult\f@@@hf{hf}{#2\temp@c}%
232
+         \@forc\f@@eo\f@@@eo
233
+             {\@forc\f@@lcr\f@@@lcr
234
+                 {\@forc\f@@hf\f@@@hf
235
+                     {\expandafter\fancy@def\csname
236
+                      f@ncy\f@@eo\f@@lcr\f@@hf\endcsname
237
+                      {#4}}}}}}
238
+
239
+\def\f@ncyhfoffs#1#2[#3]#4{%
240
+    \def\temp@c{}%
241
+    \@forc\tmpf@ra{#3}%
242
+        {\expandafter\if@in\tmpf@ra{eolrhf,EOLRHF}%
243
+            {}{\edef\temp@c{\temp@c\tmpf@ra}}}%
244
+    \ifx\@empty\temp@c\else
245
+        \@fancyerrmsg{Illegal char `\temp@c' in \string#1 argument:
246
+          [#3]}%
247
+    \fi
248
+    \f@nfor\temp@c{#3}%
249
+        {\def@ult\f@@@eo{eo}\temp@c
250
+         \if@twoside\else
251
+           \if\f@@@eo e\@fancywarning
252
+             {\string#1's `E' option without twoside option is useless}\fi\fi
253
+         \def@ult\f@@@lcr{lr}\temp@c
254
+         \def@ult\f@@@hf{hf}{#2\temp@c}%
255
+         \@forc\f@@eo\f@@@eo
256
+             {\@forc\f@@lcr\f@@@lcr
257
+                 {\@forc\f@@hf\f@@@hf
258
+                     {\expandafter\setlength\csname
259
+                      f@ncyO@\f@@eo\f@@lcr\f@@hf\endcsname
260
+                      {#4}}}}}%
261
+     \fancy@setoffs}
262
+
263
+% Fancyheadings version 1 commands. These are more or less deprecated,
264
+% but they continue to work.
265
+
266
+\newcommand{\lhead}{\@ifnextchar[{\@xlhead}{\@ylhead}}
267
+\def\@xlhead[#1]#2{\fancy@def\f@ncyelh{#1}\fancy@def\f@ncyolh{#2}}
268
+\def\@ylhead#1{\fancy@def\f@ncyelh{#1}\fancy@def\f@ncyolh{#1}}
269
+
270
+\newcommand{\chead}{\@ifnextchar[{\@xchead}{\@ychead}}
271
+\def\@xchead[#1]#2{\fancy@def\f@ncyech{#1}\fancy@def\f@ncyoch{#2}}
272
+\def\@ychead#1{\fancy@def\f@ncyech{#1}\fancy@def\f@ncyoch{#1}}
273
+
274
+\newcommand{\rhead}{\@ifnextchar[{\@xrhead}{\@yrhead}}
275
+\def\@xrhead[#1]#2{\fancy@def\f@ncyerh{#1}\fancy@def\f@ncyorh{#2}}
276
+\def\@yrhead#1{\fancy@def\f@ncyerh{#1}\fancy@def\f@ncyorh{#1}}
277
+
278
+\newcommand{\lfoot}{\@ifnextchar[{\@xlfoot}{\@ylfoot}}
279
+\def\@xlfoot[#1]#2{\fancy@def\f@ncyelf{#1}\fancy@def\f@ncyolf{#2}}
280
+\def\@ylfoot#1{\fancy@def\f@ncyelf{#1}\fancy@def\f@ncyolf{#1}}
281
+
282
+\newcommand{\cfoot}{\@ifnextchar[{\@xcfoot}{\@ycfoot}}
283
+\def\@xcfoot[#1]#2{\fancy@def\f@ncyecf{#1}\fancy@def\f@ncyocf{#2}}
284
+\def\@ycfoot#1{\fancy@def\f@ncyecf{#1}\fancy@def\f@ncyocf{#1}}
285
+
286
+\newcommand{\rfoot}{\@ifnextchar[{\@xrfoot}{\@yrfoot}}
287
+\def\@xrfoot[#1]#2{\fancy@def\f@ncyerf{#1}\fancy@def\f@ncyorf{#2}}
288
+\def\@yrfoot#1{\fancy@def\f@ncyerf{#1}\fancy@def\f@ncyorf{#1}}
289
+
290
+\newlength{\fancy@headwidth}
291
+\let\headwidth\fancy@headwidth
292
+\newlength{\f@ncyO@elh}
293
+\newlength{\f@ncyO@erh}
294
+\newlength{\f@ncyO@olh}
295
+\newlength{\f@ncyO@orh}
296
+\newlength{\f@ncyO@elf}
297
+\newlength{\f@ncyO@erf}
298
+\newlength{\f@ncyO@olf}
299
+\newlength{\f@ncyO@orf}
300
+\newcommand{\headrulewidth}{0.4pt}
301
+\newcommand{\footrulewidth}{0pt}
302
+\newcommand{\footruleskip}{.3\normalbaselineskip}
303
+
304
+% Fancyplain stuff shouldn't be used anymore (rather
305
+% \fancypagestyle{plain} should be used), but it must be present for
306
+% compatibility reasons.
307
+
308
+\newcommand{\plainheadrulewidth}{0pt}
309
+\newcommand{\plainfootrulewidth}{0pt}
310
+\newif\if@fancyplain \@fancyplainfalse
311
+\def\fancyplain#1#2{\if@fancyplain#1\else#2\fi}
312
+
313
+\headwidth=-123456789sp %magic constant
314
+
315
+% Command to reset various things in the headers:
316
+% a.o.  single spacing (taken from setspace.sty)
317
+% and the catcode of ^^M (so that epsf files in the header work if a
318
+% verbatim crosses a page boundary)
319
+% It also defines a \nouppercase command that disables \uppercase and
320
+% \Makeuppercase. It can only be used in the headers and footers.
321
+\let\fnch@everypar\everypar% save real \everypar because of spanish.ldf
322
+\def\fancy@reset{\fnch@everypar{}\restorecr\endlinechar=13
323
+ \def\baselinestretch{1}%
324
+ \def\nouppercase##1{{\let\uppercase\relax\let\MakeUppercase\relax
325
+     \expandafter\let\csname MakeUppercase \endcsname\relax##1}}%
326
+ \ifx\undefined\@newbaseline% NFSS not present; 2.09 or 2e
327
+   \ifx\@normalsize\undefined \normalsize % for ucthesis.cls
328
+   \else \@normalsize \fi
329
+ \else% NFSS (2.09) present
330
+  \@newbaseline%
331
+ \fi}
332
+
333
+% Initialization of the head and foot text.
334
+
335
+% The default values still contain \fancyplain for compatibility.
336
+\fancyhf{} % clear all
337
+% lefthead empty on ``plain'' pages, \rightmark on even, \leftmark on odd pages
338
+% evenhead empty on ``plain'' pages, \leftmark on even, \rightmark on odd pages
339
+\if@twoside
340
+  \fancyhead[el,or]{\fancyplain{}{\sl\rightmark}}
341
+  \fancyhead[er,ol]{\fancyplain{}{\sl\leftmark}}
342
+\else
343
+  \fancyhead[l]{\fancyplain{}{\sl\rightmark}}
344
+  \fancyhead[r]{\fancyplain{}{\sl\leftmark}}
345
+\fi
346
+\fancyfoot[c]{\rm\thepage} % page number
347
+
348
+% Use box 0 as a temp box and dimen 0 as temp dimen. 
349
+% This can be done, because this code will always
350
+% be used inside another box, and therefore the changes are local.
351
+
352
+\def\@fancyvbox#1#2{\setbox0\vbox{#2}\ifdim\ht0>#1\@fancywarning
353
+  {\string#1 is too small (\the#1): ^^J Make it at least \the\ht0.^^J
354
+    We now make it that large for the rest of the document.^^J
355
+    This may cause the page layout to be inconsistent, however\@gobble}%
356
+  \dimen0=#1\global\setlength{#1}{\ht0}\ht0=\dimen0\fi
357
+  \box0}
358
+
359
+% Put together a header or footer given the left, center and
360
+% right text, fillers at left and right and a rule.
361
+% The \lap commands put the text into an hbox of zero size,
362
+% so overlapping text does not generate an errormessage.
363
+% These macros have 5 parameters:
364
+% 1. LEFTSIDE BEARING % This determines at which side the header will stick
365
+%    out. When \fancyhfoffset is used this calculates \headwidth, otherwise
366
+%    it is \hss or \relax (after expansion).
367
+% 2. \f@ncyolh, \f@ncyelh, \f@ncyolf or \f@ncyelf. This is the left component.
368
+% 3. \f@ncyoch, \f@ncyech, \f@ncyocf or \f@ncyecf. This is the middle comp.
369
+% 4. \f@ncyorh, \f@ncyerh, \f@ncyorf or \f@ncyerf. This is the right component.
370
+% 5. RIGHTSIDE BEARING. This is always \relax or \hss (after expansion).
371
+
372
+\def\@fancyhead#1#2#3#4#5{#1\hbox to\headwidth{\fancy@reset
373
+  \@fancyvbox\headheight{\hbox
374
+    {\rlap{\parbox[b]{\headwidth}{\raggedright#2}}\hfill
375
+      \parbox[b]{\headwidth}{\centering#3}\hfill
376
+      \llap{\parbox[b]{\headwidth}{\raggedleft#4}}}\headrule}}#5}
377
+
378
+\def\@fancyfoot#1#2#3#4#5{#1\hbox to\headwidth{\fancy@reset
379
+    \@fancyvbox\footskip{\footrule
380
+      \hbox{\rlap{\parbox[t]{\headwidth}{\raggedright#2}}\hfill
381
+        \parbox[t]{\headwidth}{\centering#3}\hfill
382
+        \llap{\parbox[t]{\headwidth}{\raggedleft#4}}}}}#5}
383
+
384
+\def\headrule{{\if@fancyplain\let\headrulewidth\plainheadrulewidth\fi
385
+    \hrule\@height\headrulewidth\@width\headwidth \vskip-\headrulewidth}}
386
+
387
+\def\footrule{{\if@fancyplain\let\footrulewidth\plainfootrulewidth\fi
388
+    \vskip-\footruleskip\vskip-\footrulewidth
389
+    \hrule\@width\headwidth\@height\footrulewidth\vskip\footruleskip}}
390
+
391
+\def\ps@fancy{%
392
+\@ifundefined{@chapapp}{\let\@chapapp\chaptername}{}%for amsbook
393
+%
394
+% Define \MakeUppercase for old LaTeXen.
395
+% Note: we used \def rather than \let, so that \let\uppercase\relax (from
396
+% the version 1 documentation) will still work.
397
+%
398
+\@ifundefined{MakeUppercase}{\def\MakeUppercase{\uppercase}}{}%
399
+\@ifundefined{chapter}{\def\sectionmark##1{\markboth
400
+{\MakeUppercase{\ifnum \c@secnumdepth>\z@
401
+ \thesection\hskip 1em\relax \fi ##1}}{}}%
402
+\def\subsectionmark##1{\markright {\ifnum \c@secnumdepth >\@ne
403
+ \thesubsection\hskip 1em\relax \fi ##1}}}%
404
+{\def\chaptermark##1{\markboth {\MakeUppercase{\ifnum \c@secnumdepth>\m@ne
405
+ \@chapapp\ \thechapter. \ \fi ##1}}{}}%
406
+\def\sectionmark##1{\markright{\MakeUppercase{\ifnum \c@secnumdepth >\z@
407
+ \thesection. \ \fi ##1}}}}%
408
+%\csname ps@headings\endcsname % use \ps@headings defaults if they exist
409
+\ps@@fancy
410
+\gdef\ps@fancy{\@fancyplainfalse\ps@@fancy}%
411
+% Initialize \headwidth if the user didn't
412
+%
413
+\ifdim\headwidth<0sp
414
+%
415
+% This catches the case that \headwidth hasn't been initialized and the
416
+% case that the user added something to \headwidth in the expectation that
417
+% it was initialized to \textwidth. We compensate this now. This loses if
418
+% the user intended to multiply it by a factor. But that case is more
419
+% likely done by saying something like \headwidth=1.2\textwidth. 
420
+% The doc says you have to change \headwidth after the first call to
421
+% \pagestyle{fancy}. This code is just to catch the most common cases were
422
+% that requirement is violated.
423
+%
424
+    \global\advance\headwidth123456789sp\global\advance\headwidth\textwidth
425
+\fi}
426
+\def\ps@fancyplain{\ps@fancy \let\ps@plain\ps@plain@fancy}
427
+\def\ps@plain@fancy{\@fancyplaintrue\ps@@fancy}
428
+\let\ps@@empty\ps@empty
429
+\def\ps@@fancy{%
430
+\ps@@empty % This is for amsbook/amsart, which do strange things with \topskip
431
+\def\@mkboth{\protect\markboth}%
432
+\def\@oddhead{\@fancyhead\fancy@Oolh\f@ncyolh\f@ncyoch\f@ncyorh\fancy@Oorh}%
433
+\def\@oddfoot{\@fancyfoot\fancy@Oolf\f@ncyolf\f@ncyocf\f@ncyorf\fancy@Oorf}%
434
+\def\@evenhead{\@fancyhead\fancy@Oelh\f@ncyelh\f@ncyech\f@ncyerh\fancy@Oerh}%
435
+\def\@evenfoot{\@fancyfoot\fancy@Oelf\f@ncyelf\f@ncyecf\f@ncyerf\fancy@Oerf}%
436
+}
437
+% Default definitions for compatibility mode:
438
+% These cause the header/footer to take the defined \headwidth as width
439
+% And to shift in the direction of the marginpar area
440
+
441
+\def\fancy@Oolh{\if@reversemargin\hss\else\relax\fi}
442
+\def\fancy@Oorh{\if@reversemargin\relax\else\hss\fi}
443
+\let\fancy@Oelh\fancy@Oorh
444
+\let\fancy@Oerh\fancy@Oolh
445
+
446
+\let\fancy@Oolf\fancy@Oolh
447
+\let\fancy@Oorf\fancy@Oorh
448
+\let\fancy@Oelf\fancy@Oelh
449
+\let\fancy@Oerf\fancy@Oerh
450
+
451
+% New definitions for the use of \fancyhfoffset
452
+% These calculate the \headwidth from \textwidth and the specified offsets.
453
+
454
+\def\fancy@offsolh{\headwidth=\textwidth\advance\headwidth\f@ncyO@olh
455
+                   \advance\headwidth\f@ncyO@orh\hskip-\f@ncyO@olh}
456
+\def\fancy@offselh{\headwidth=\textwidth\advance\headwidth\f@ncyO@elh
457
+                   \advance\headwidth\f@ncyO@erh\hskip-\f@ncyO@elh}
458
+
459
+\def\fancy@offsolf{\headwidth=\textwidth\advance\headwidth\f@ncyO@olf
460
+                   \advance\headwidth\f@ncyO@orf\hskip-\f@ncyO@olf}
461
+\def\fancy@offself{\headwidth=\textwidth\advance\headwidth\f@ncyO@elf
462
+                   \advance\headwidth\f@ncyO@erf\hskip-\f@ncyO@elf}
463
+
464
+\def\fancy@setoffs{%
465
+% Just in case \let\headwidth\textwidth was used
466
+  \fancy@gbl\let\headwidth\fancy@headwidth
467
+  \fancy@gbl\let\fancy@Oolh\fancy@offsolh
468
+  \fancy@gbl\let\fancy@Oelh\fancy@offselh
469
+  \fancy@gbl\let\fancy@Oorh\hss
470
+  \fancy@gbl\let\fancy@Oerh\hss
471
+  \fancy@gbl\let\fancy@Oolf\fancy@offsolf
472
+  \fancy@gbl\let\fancy@Oelf\fancy@offself
473
+  \fancy@gbl\let\fancy@Oorf\hss
474
+  \fancy@gbl\let\fancy@Oerf\hss}
475
+
476
+\newif\iffootnote
477
+\let\latex@makecol\@makecol
478
+\def\@makecol{\ifvoid\footins\footnotetrue\else\footnotefalse\fi
479
+\let\topfloat\@toplist\let\botfloat\@botlist\latex@makecol}
480
+\def\iftopfloat#1#2{\ifx\topfloat\empty #2\else #1\fi}
481
+\def\ifbotfloat#1#2{\ifx\botfloat\empty #2\else #1\fi}
482
+\def\iffloatpage#1#2{\if@fcolmade #1\else #2\fi}
483
+
484
+\newcommand{\fancypagestyle}[2]{%
485
+  \@namedef{ps@#1}{\let\fancy@gbl\relax#2\relax\ps@fancy}}

+ 1
- 1
preamble/packages.tex View File

@@ -14,7 +14,7 @@
14 14
 
15 15
 % Style
16 16
 \usepackage[hypertexnames=false, unicode, pdfusetitle]{hyperref}
17
-\usepackage[nonatbib]{nips_2018}
17
+\usepackage[]{aistats2019}
18 18
 
19 19
 % Fonts
20 20
 % \usepackage{lmodern} # :(

Loading…
Cancel
Save