2

I am trying to write my page of references, and would like to include it in my contents page, where it would be Chapter 10

However, I have included the \section{References} command, but also the \begin{thebibliography}{99} command so as to allow my references to be numbered, however this results in me having 'References' labelled twice.

Is there any way to suppress the second 'References' that is generated by \begin{thebibliography}{99}?

My code is this:

\documentclass[11pt,a4paper]{article}
\usepackage{amsfonts,amssymb,amsmath,amsthm,graphicx}
\usepackage[top=2cm, bottom=2cm, left=2cm, right=2cm]{geometry}

\newtheorem{thm}{Theorem}[section]
\newtheorem{cor}[thm]{Corollary}
\newtheorem{lem}[thm]{Lemma}
\theoremstyle{definition}
\newtheorem{defn}[thm]{Definition}
\theoremstyle{remark}
\newtheorem{rem}[thm]{Remark}
\numberwithin{equation}{section}

\newcommand{\R}{\mathbb R}
\newcommand{\C}{\mathbb C}
\newcommand{\eps}{\varepsilon}
\renewcommand{\baselinestretch}{1.5}

\makeatletter
\setlength{\@fptop}{0pt}
\makeatother

\begin{document}

\section{References:}
\begin{thebibliography}{99}

\bibitem{1}
    {\sc Gerald \& Wheatley},
    {\it Applied Numerical Analysis.}
    Page 165. Pearson, 2003

    \bibitem{2}
    {\sc Gerald \& Wheatley},
    {\it Applied Numerical Analysis.}
    Page 274. Pearson, 2003.

    \bibitem{3}
    {\sc Gerald \& Wheatley},
    {\it Applied Numerical Analysis.}
    Page 280. Pearson, 2003.


    \bibitem{4}
    {\sc Hoffman \& Frankel},
    {\it Numerical Methods for Engineers and Scientists.}
    Page 294. CRC Press, 2001.

    \bibitem{5}
    {\sc Hoffman \& Frankel},
    {\it Numerical Methods for Engineers and Scientists.}
    Page 296. CRC Press, 2001.

    \bibitem{6}
    {\sc Larson \& Edwards},
    {\it Calculus.}
    Page 983. Houghton Mifflin, 2009.

    \bibitem{7}
    {\sc Larson \& Edwards},
    {\it Calculus.}
    Page 983. Houghton Mifflin, 2009.


\end{thebibliography}

\end{document}
  • Could you complete your code so we can compile it? – cfr Mar 17 '15 at 1:07
  • Apologies, I have added in the extras now – user136650 Mar 17 '15 at 1:10
  • Thanks. The key bit here is your class since different classes define thebibliography in different ways. (I should have asked for a minimal working example (MWE) as it would be better to only include the necessary code. However, I'm afraid I forgot.) – cfr Mar 17 '15 at 1:28
2

Since you are using article.cls, you could use this in your preamble to patch the thebibliography environment:

\usepackage{etoolbox}
\patchcmd{\thebibliography}{\section*{\refname}}{}{\typeout{goodie!}}{\typeout{oh dear!}}

Patched environment

Note that it would be preferable in your code to say:

\section{\refname}

To ensure a match with the marks (used e.g. in headers) set by thebibliography environment. Then if you need to change it, you can just say \renewcommend*\refname{whatever} in one place.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.