0

I am very new to latex as well as using all its integrations such as Zotero. I have most basics down at this point but am running into as issue with my referencing. When adding a new reference in the text using \cite, that reference is now designated as [1] in the bibliography - even when it is in fact the third reference in the text. More citations increases this, so now my first citation in text is [5] and the last in text is [1]. Obviously this should be the reverse, but I have no clue how to fix it. As I understand it the order in the .bib file should not matter (though I may of course be wrong). I have a reference in a figure, but removing that entirely did not fix my issues so I do not suspect that to be the culprit. I am genuinely at a loss after hours of googling.

\documentclass[11pt]{article}
\usepackage[english]{babel}
\usepackage{amsmath}
\usepackage{graphicx}
\usepackage[
backend=biber,
]{biblatex}
\addbibresource{Astrochemistry - HCN.bib}
\usepackage[colorinlistoftodos]{todonotes}
\usepackage{enumitem}
\usepackage{listings}
\usepackage{verbatim}
\usepackage{eurosym}
\usepackage[export]{adjustbox}
\usepackage[version=4]{mhchem}
\usepackage{geometry}
 \geometry{
 a4paper,
 total={170mm,257mm},
 left=20mm,
 top=20mm,
 }

\begin{document}

\section{The Basics}

\subsection{Basic Structure}

this should be number one, but it is not.\cite{pubchem_hydrogen_nodate}

\subsection{Spectral Properties and Observable Transitions}

test test test. \cite{keedy_rotational-vibrational_1992}

test test, this should be citation 3, but it is 1 instead!\cite{hernandez_vera_rotational_2017}

\newpage \printbibliography

\end{document}

I excluded things like my title page, but have all packages since I assume those are the most important.

Oh and my .bib file currently looks like this, though Zotero updates that as I go of course:

@article{hernandez_vera_rotational_2017,
    title = {The rotational excitation of the {HCN} and {HNC} molecules by {H2} revisited},
    volume = {468},
    issn = {0035-8711},
    doi = {10.1093/mnras/stx422},
    abstract = {HCN and HNC are two fundamental molecules in the dense interstellar medium. The HNC/HCN abundance ratio depends on the kinetic temperature and can be used to explore the physical and chemical conditions of star-forming regions. Modelling of HCN and HNC emissions from interstellar clouds requires to model their collisional and radiative excitations. We report the calculation of the HCN and HNC excitation rate coefficients among the first 26 rotational levels due to H2 collisions, for temperatures ranging from 5 to 500 K, using the exact close coupling and the approximate coupled states methods. We found a propensity for even Δj transitions in the case of HCN–para-H2 collisions, whereas a propensity for odd Δj transitions is observed in the case of HNC–para-H2 collisions. For collisions with ortho-H2, both molecules show a propensity rule favouring transitions with odd Δj. The rate coefficients for HCN and HNC differ significantly, showing clearly that the collisional excitation of the two isomers is different, especially for para-H2. We also evaluate the impact of these new data on the astrophysical modelling through radiative transfer calculations. It is shown that specific calculations have to be performed for the two isomers and that the HNC/HCN abundance ratio in cold molecular clouds cannot be estimated from line intensity ratio. Finally, observations of the two isotopologues H13CN and HN13C towards a sample of prestellar cores are presented, and the larger excitation temperature of HN13C is well reproduced by our excitation model.},
    number = {1},
    urldate = {2022-06-06},
    journal = {Monthly Notices of the Royal Astronomical Society},
    author = {Hernández Vera, M. and Lique, F. and Dumouchel, F. and Hily-Blant, P. and Faure, A.},
    month = jun,
    year = {2017},
    pages = {1084--1091},
}

@misc{pubchem_hydrogen_nodate, title = {Hydrogen cyanide}, url = {https://pubchem.ncbi.nlm.nih.gov/compound/768}, abstract = {Hydrogen cyanide {\textbar} HCN or CHN {\textbar} CID 768 - structure, chemical names, physical and chemical properties, classification, patents, literature, biological activities, safety/hazards/toxicity information, supplier lists, and more.}, urldate = {2022-06-06}, author = {PubChem}, }

@article{keedy_rotational-vibrational_1992, title = {The rotational-vibrational spectra of {HCN} and {DCN}: {A} physical chemistry experiment}, volume = {69}, issn = {0021-9584, 1938-1328}, shorttitle = {The rotational-vibrational spectra of {HCN} and {DCN}}, doi = {10.1021/ed069pA296}, number = {11}, journal = {Journal of Chemical Education}, author = {Keedy, Curtis R.}, month = nov, year = {1992}, pages = {A296}, }

MS-SPO
  • 11,519
Kirsten
  • 11
  • First of all, this has nothing to do with Zotero: how you create your .bib file is up to you, Zotero is just one such way. What I suspect is happening here, is that the references are sorted alphabetically in the bibliography. Try the sorting=none option for {biblatex}. – Ingmar Jun 06 '22 at 17:18
  • See this thread for more info: https://tex.stackexchange.com/questions/51434/biblatex-citation-order – Ingmar Jun 06 '22 at 17:25
  • 1
    @Ingmar You are amazing thank you so much!! Since I didn't know what the issue was I didn't know where to look, and the answer was so damn simple! Thank you really! – Kirsten Jun 06 '22 at 17:28

1 Answers1

1

This is the answer given in the comments above for completeness' sake:

First of all, this has nothing to do with Zotero: how you create your .bib file is up to you, Zotero is just one such way. What I suspect is happening here, is that the references are sorted alphabetically in the bibliography. Try the sorting=none option for biblatex. See this thread for more info: tex.stackexchange.com/questions/51434/biblatex-citation-order

This is exactly what solved the issue, I simply did not know exactly where to look or how to find it.

Kirsten
  • 11