How to use BibTex

Author: Jānis Lazovskis
Disclaimer: The approach below works well for me. It may not for you, and you may need to tweak some options or steps, or you may have a better way altogether of doing it.


BibTeX: a LaTeX package to manage references
BibLaTeX: just like BibTeX, but you can control more things via LaTeX commands

Necessary parts

External file: In the same directory as your main .tex file, make a new file, call it biblio.bib.
Find the sources you need on MathSciNet (direct link here and proxy through UIC here, which also works off campus).
Once you've found it: Select alternative format -> BibTeX -> Copy all the code into your biblio.bib file.
You can change the MR number to something nicer - for example from MR1645678 to erdos.
Header: Place the following code in your .tex file header (before \begin{document}):
I have included the options for biblatex that I like and that work for me. See more at the documentation here.
Main text: To cite a source, use \cite{erdos} or whatever you've called the source in biblio.bib.
Bottom of text: Place the folllowing code in your text where you want the bibliography to appear:
The first line adds the bibliography to the table of contents (otherwise it won't appear there). Delete this line if you don't want it to appear.
The second line makes the title of the bibliography be "Bibliography". The default is "References", and you can change it to whatever you want.
The third line tells LaTeX to print all the sources in your biblio.bib file, even if you haven't called them in the text.
The fourth line tells LaTeX to print the bibliography.

Once you have all the necessary parts, compile it with BibTeX (or BibLaTeX, whichever works), then with LaTeX. You may have to repeat one then the other a few times for everything to appear correctly.

Relevant links

- MathSciNet, get all your official BibTeX code here
- Proxy through UIC to MathSciNet, if you're off campus
- BibLaTeX, documentation and package repository
- The TeX Stack Exchange, your place for all (well-formed, polite) questions

This page was last updated 2016-09-20