10

I'm creating a manual bibliography, but it needs to be divided into sections. The solutions I thought might be applicable:

  • Add \textbx{"Literary works"}, \textbx{"Web references"}, etc. between \bibitem{} items. This does not work, since an error is reported.

  • Insert separate bibliographies and label them accordingly (which I don't know how to do).

Any help / other suggestions appreciated.

lockstep
  • 250,273
marw
  • 235

2 Answers2

18
  • Create several separate thebibliography environments;

  • Redefine the \bibname macro (for the book and report class) or the \refname macro (for the article class) before every environment as desired;

  • To achieve unambiguous numbering of your bibitems, define a new counter (say, firstbib), use this counter to save the value of enumiv at the end of every thebibliography environment and reset enumiv to the value of firstbib at the start of the next environment.

  • (Note, however, that if you're using natbib, then the counter is NAT@ctr instead of enumiv.)

Because the redefinitions of \bibname/\refname take place after \begin{document}, this solution also works if one uses the babel package.

\documentclass{article}

\newcounter{firstbib}

\begin{document}

\section{foo}

Some text \cite{A01,B02,C03}.

\renewcommand{\refname}{Literary works}

\begin{thebibliography}{9}

\bibitem{A01} A. Author. \emph{Alpha}. 2001.

\bibitem{B02} B. Buthor. \emph{Bravo}. 2002.

\setcounter{firstbib}{\value{enumiv}}

\end{thebibliography}

\renewcommand{\refname}{Web references}

\begin{thebibliography}{9}

\setcounter{enumiv}{\value{firstbib}}

\bibitem{C03} C. Cuthor. \emph{Charlie}. 2003.

\end{thebibliography}

\end{document}

enter image description here

E.P.
  • 1,415
lockstep
  • 250,273
  • @GonzaloMedina: Excellent suggestion -- I changed my example accordingly. (And yes, I know this in principle, but totally forgot it at the moment.) – lockstep Dec 08 '11 at 22:41
  • ...and I updated it in my document! :) Thank you, both of you. Works like charm. – marw Dec 08 '11 at 22:47
  • 3
    Just a note that if you use natbib, then the counter is NAT@ctr not enumiv. – mforbes Oct 24 '13 at 08:25
3

A much easier solution is using the biblatex package and defining a refsection environment in the body of the chapter.

\chapter{Blah}
\begin{refsection}% 3rd `refsection`

\end{refsection}

To print the bibliography you use:

\printbibliography[section=3,title={Blah Bibliography}]

The only difference is that you have to run bibtex for each *-blx.aux file.

Creating bibliographies that depend on criteria is also possible.