main banner
A Guide to Writing Your Thesis Using LATEX
Go to Step 4

Step 3: Generating the Thesis

Now that you have LATEX, an appropriate editor, and the template files, we will now verify that you have a functioning setup, and that the process for generating the thesis is understood. The way we will verify the setup is to have you generate the thesis from the example files included in the template files. If the document generated using the unmodified template files looks like this this, you are done. Check the following list to make sure your generated thesis is correct.

  • The document should contain exactly six pages.
    • There should be no numbers on the first three pages
    • The fourth page should be numbered iii
    • The fifth and sixth pages should be numbered 1 and 2 respectively
  • The list of references should appear at the end of Chapter 1, and contain two entries.
  • The bibliography should be the last page of the thesis and contain three entries. It should also be listed in the table of contents as being page 2.

Generating the Thesis on Linux

Generating from kile (for kile 2.0)

Start kile by either selecting it from the Office menu, or typing kile at the command prompt.

Add the ability to easily update the Bibliography and List of References by creating a new action, then adding it to the toolbar.

  • Select Settings → Configure Kile... from the menu
  • Select Tools → Build on the left of the dialog box
  • Click New Tool... button
  • For the name enter ThesisBib then click Next
  • For the behavior select BibTeX then click Finish
  • In the Command: box enter sh
  • In the Options: box enter genbib.bat
  • Click on the Menu tab
  • Click on the Icon: button
  • In the Search: box type bibtex
  • Click on the bibtex icon, which should look like bibtex
  • Click OK
  • Select Settings → Configure Toolbars ... from the menu
  • Under the Toolbar: dropdown select Tools
  • Under the Available actions: select ThesisBib and drag it into the Current actions:
  • Click OK

In kile, click the Open File tab, then open the file thesis.tex.

Under the Settings menu select Define Current Document as 'Master Document'. This will allow you to click on the different build icons on the toolbar no matter which file you are editing.

The steps to generate the thesis are:

  • Press the PDFLaTeX icon pdflatex
  • Press the ThesisBib icon bibtex
  • Press the PDFLaTeX icon pdflatex
  • Press the PDFLaTeX icon pdflatex
  • Press the ViewPDF icon viewpdf

and you should see this document.

Generating the Thesis on Windows

Start TeXnicCenter.

Add the ability to easily update the Bibliography and List of References by creating a output profile called Thesis.

  • Select Build → Define Output Profiles... from the menu
  • Select LaTeX => PS on the left of the dialog box
  • Click Copy button
  • For the profile name enter Thesis then click OK
  • In the Path to BibTeX executable: box enter genbib.bat without any path
  • Click OK
  • Select Build → Select Output Profile... from the menu
  • Select Thesis then click OK

Now create a project.

  • Open the file thesis.tex
  • Select Project → Create with active file as main file from the menu
  • Check the Uses BibTeX checkbox
  • Click OK

The steps to generate the thesis are:

  • Press the Build Output icon buildoutput
  • Press the Build Output icon buildoutput
  • Press the Build and View Output icon buildview

and you should see this document.

Generating the Thesis on MacOS X

Generating the Thesis Manually

Although the thesis is usually generated by clicking on a button in the editor, it can always be generated manually. The steps used for manual generation are equivalent to what the editor runs when it generates the thesis (assuming you are generating it using pdflatex).

The thesis is generated by the following sequence of commands. At a command prompt, such as in a terminal program like xterm or the command window in Microsoft Windows, go to the directory that contains the extracted template files. At the prompt type the following commands:

  pdflatex thesis.tex
  sh genbib.bat        (leave out the sh on Windows)
  pdflatex thesis.tex
  pdflatex thesis.tex

The first time you run pdflatex, it generates .aux files which contain the information needed to create the bibliography and lists of references, as well as information needed to create the table of contents, list of figures, and list of tables. It also creates the script genbib.bat, which runs BibTeX on all of the necessary .aux files to create .bbl files, which are the actual bibliography and lists of references. Finally, pdflatex is run two more times, the first time includes the bibliography and lists of references, and the second time resolves bibliographic citations to their entry in the list of references. You should now have a file called thesis.pdf which should look like this.