5

I have the following problem: I correctly obtain a numbered bibliography at the end but along the text the cite_key appear instead of a number. How to fix this problem?

\documentclass[11pt]{book} 
\usepackage[]{biblatex}
\begin{document}
%some text 
... \cite{ABKM2015}...
%some text 
\begin{thebibliography}{99}
\bibitem{ABKM2015}
Arroja, F. and Bartolo, N. and Karmakar P. and Matarrese, S. (2015).
\newblock The Two Faces of Mimetic Horndeski Gravity            
\newblock {\em ArXiV}, 1506.08575 (2015).
\end{thebibliography}
\end{document}

After compiling I get ... [ABKM2015] ... while I want for example [1].

8
  • 3
    You seem to be mixing 'classical' bibliography generation (hard-coded \bibitem data) with biblatex: that won't work. Can you detail a little more what you hope to achieve?
    – Joseph Wright
    Nov 10, 2015 at 9:16
  • See also Problem with biblatex. biblatex does not work with the manual thebibliography. You will have to start using biblatex properly, see my comments on your other question for starters.
    – moewe
    Nov 10, 2015 at 16:14
  • I don't want to use biblatex but instead to use the embedded thebibliography environment. How to get numbers instead of the cite_key? It seems an easy request to me..
    – yngabl
    Nov 10, 2015 at 16:28
  • If you don't want to use biblatex why do you load it then?
    – moewe
    Nov 10, 2015 at 16:29
  • Because if I don't load it, I get an error and compilation won't proceed
    – yngabl
    Nov 10, 2015 at 16:31

2 Answers 2

5

You cannot use biblatex together with a manual thebibliography environment. While BibTeX is compatible with thebibliography, biblatex completely re-implements all citation and bibliography commands and cannot be used with classical BibTeX nor with the manual thebibliography.


If you want to use thebibliography you need to get rid of biblatex.

\documentclass[11pt]{article}
\usepackage{csquotes}
\usepackage{url}
\ifundef\doi
  {\DeclareUrlCommand\doi{}}
  {}
\begin{document}
Lorem \cite{ABKM2015} ipsum.

\begin{thebibliography}{99}
\bibitem{ABKM2015}
Arroja, F. and Bartolo, N. and Karmakar P. and Matarrese, S. (2015).
\newblock The two faces of mimetic Horndeski gravity:
  disformal transformations and Lagrange multiplier
\newblock \emph{Journal of Cosmology and Astroparticle Physics}
 15/09 (2015), 051
\newblock DOI: \doi{10.1088/1475-7516/2015/09/051}
\newblock arXiv:\texttt{1506.08575 [gr-qc]}
\end{thebibliography}
\end{document}

works just fine.

Arroja, F. and Bartolo, N. and Karmakar P. and Matarrese, S. (2015). The two faces of mimetic Horndeski gravity: disformal transformations and Lagrange multiplier Journal of Cosmology and Astroparticle Physics 15/09 (2015), 051 DOI: 10.1088/1475-7516/2015/09/051 arXiv:1506.08575 [gr-qc]


Conversely, if you want to use biblatex you can't have thebibliography and must instead provide the data for your entries in a .bib file.

mybibfile.bib would contain

@article{ABKM2015,
  author      = {Frederico Arroja and Nicola Bartolo
                 and Purnendu Karmakar and Sabino Matarrese},
  title       = {The two faces of mimetic {Horndeski} gravity:
                 disformal transformations and {Lagrange} multiplier},
  journal     = {Journal of Cosmology and Astroparticle Physics},
  volume      = {2015},
  number      = {9},
  eid         = {051},
  doi         = {10.1088/1475-7516/2015/09/051},
  date        = {2015-09},
  eprinttype  = {arxiv},
  eprint      = {1506.08575},
  eprintclass = {gr-qc},
}

and would be used as follows

\documentclass[british]{article}
\usepackage[T1]{fontenc}
\usepackage[utf8]{inputenc}
\usepackage{babel}
\usepackage{csquotes}

\usepackage[style=numeric, maxbibnames=999, backend=biber]{biblatex}

\addbibresource{mybibfile.bib}

\begin{document}
Lorem \cite{ABKM2015} ipsum.
\printbibliography
\end{document}

Frederico Arroja, Nicola Bartolo, Purnendu Karmakar and Sabino Matarrese. ‘The two faces of mimetic Horndeski gravity: disformal transformations and Lagrange multiplier’. In: Journal of Cosmology and Astroparticle Physics 2015.9, 051 (Sept. 2015). doi: 10.1088/1475-7516/2015/09/051. arXiv: 1506.08575 [gr-qc].


It is a good idea to delete all temporary auxiliary files (.aux, .bbl, .bcf, ...) after changes to the bibliography set-up to make sure that there are no errors due to now undefined or redefined macro calls in the auxiliary files.

0
0

When you are putting your bibliography manually with bibitem, just change \usepackage[]{biblatex} to \usepackage{cite} and your citation will appear in number.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .