For those of you who know LaTeX and would like to make formatting your paper that much easier, read through this documentation before downloading all the files, because there are a few packages that are a little bit quirky (but not quirky enough to do your whole paper from scratch). For those of you who don't know LaTeX but would like to learn, the following is a list of documents to get you started:
Alright, so first things first: download the pertinent files into one directory. Read through the list below to see which ones you need. The first three files are necessary, but the rest are only if you need them.
endfloat
package for moving all your floats (tables and figures) to the end of your document (keep reading for a few important notes on this package)sidewaysfigure
or sidewaystable
environment. This lets endfloat
see that your sideways figures are floats that should be moved to the end of the document. See the package documentation for more details on the endfloat
package.Once you have all the files you need, update the fields at the top of template.tex to reflect your and your mentor's contact information. These fields will be used to fill in the information on the title page and also to make that header line for the abstract. The fields are currently populated with sample information as an example.
Add the text of your paper in all the right places in the template file, write your bibliography file and cite your sources from there. If you're using floats (figures or tables), you can put them whereever they would be normally in the text, and they will automatically be output at the end of the document. However, there are a few things that need some careful attention for your figures to come out the right way:
\begin{figure}
and \end{figure}
(or \begin{table}
and \end{table}
) tags for your figures are each on a separate line with no indenting or spaces before the text, like this:
\begin{figure}
...
\end{figure}
^ -- no indent!
[htbp]
), except the first figure and all tables in your document, for which you should use [h]
, like this:
\begin{figure}[h]
...
\end{figure}
Otherwise, the figures get pushed around kind of strangly. The endfloat package which puts all your figures at the end of the document has a few bugs (i didnt write it), which is why you need to do these few little extras.\begin{sidewaysfigure}
or \begin{sidewaystable}
tags instead of the usual figure and table tags. Make sure you have the rotating
package included at the top of template.tex (\usepackage{rotating}
), and also make sure you've downloaded the endfloat.cfg file above so that endfloat can grab your figures properly.Once you've done all of the above, build the template file. If you're using Linux, use the following commands:
latex template
bibtex template
latex template
latex template
dvips -t letter -o template.ps template.dvi
ps2pdf template.ps template.pdf
Alternatively, you could create an alias in your .cshrc file so that you have a shortcut for all of these commands. Just add the following all on one line to your .cshrc file (a hidden file that you can open for editing by typing emacs ~/.cshrc
):
alias buildtex 'latex \!*; bibtex \!*; latex \!*; latex \!*; dvips -t letter -o \!*.ps \!*.dvi; ps2pdf \!*.ps \!*.pdf;'
Once you've saved and closed the .cshrc file, type source ~/.cshrc
so that you can use your new alias. From this point on, whenever you want to build your paper, just type buildtex template
to create your template.pdf file. NB: this will work on SLAC's system. If your Linux machine uses a different shell, then the alias command will be slightly different, and you'll have to look elsewhere for how to get that working properly. Calling the above alias (or typing in each of the commands) will create a dvi, ps and pdf file of your document. Click here to see what the template file looks like when built. Obviously, if you change the name of the .tex file, you should change the above commands to reflect that. If you get any missing file errors that obviously aren't any of the above files, go to http://www.ctan.org to download them.
If you're using Windows or Mac, make sure you build your project using latex, not pdflatex. If you want to deal with installing GUI latex editors on your personal computer, TeXnicCenter or WinEdt for Windows, TeXShop for Mac, and Kile for Linux are what's in these days.
So that's about it. If you have comments or suggestions, please let us -- sanya17[at]mit[dot]edu or axs[at]mit[dot]edu -- know!