# Elsevier, sort bibliographic entries alphabetically by surnames of authors

References should be arranged first alphabetically and then further sorted chronologically if necessary.

I have been asked to sort the references. Despite I have followed the solution here, it did not work for me.

The result is not ordered by surname of the author(s).

Please consider that I cannot change the documentclass.

\documentclass[3p,times,twocolumn,authoryear]{elsarticle}
\usepackage{ecrc}
\volume{00}
\firstpage{1}
\journal{Expert Systems with Applications}
\runauth{Me et al.}
\jid{eswa}
\jnltitlelogo{Expert Systems with Applications}
\usepackage{amssymb}
\usepackage[figuresright]{rotating}
\usepackage{lipsum}
\usepackage{etoolbox}
\AtBeginDocument{%
% \patchcmd{<cmd>}{<search>}{<replace>}{<success>}{<failure>}
\patchcmd{\MaketitleBox}{\vspace*{-20pt}\fi}{\fi}{}{}%
}

\begin{document}

\begin{frontmatter}
\title{title  title title}
\author{}
\begin{abstract}
Text of abstract
\end{abstract}
\begin{keyword}
k1, k2, k3
\end{keyword}
\end{frontmatter}

\section{first section}

\citep{Feynman1963118,Dirac1953888}

%\bibliographystyle{apsrev}
%\bibliographystyle{plainnat}
%\bibliographystyle{natbib}
\bibliographystyle{elsarticle-num-names}
\bibliography{mybibfile}

\end{document}


mybibfile.bib

@article{Feynman1963118,
title   = "The theory of a general quantum system interacting with a linear dissipative system",
journal = "Annals of Physics ",
volume  = "24",
pages   = "118--173",
year    = "1963",
doi     = "10.1016/0003-4916(63)90068-X",
author  = "R.P Feynman and F.L {Vernon Jr.}"
}

@article{Dirac1953888,
title   = "The lorentz transformation and absolute time",
journal = "Physica ",
volume  = "19",
number  = "1-–12",
pages   = "888--896",
year    = "1953",
doi     = "10.1016/S0031-8914(53)80099-6",
author  = "P.A.M. Dirac"
}


According to the final link you provided in the comments, the bibliographic entries must not only be sorted alphabetically by authors' surnames, but they must also be formatted according to APA-6 guidelines. Moreover, the citation call-outs must use authoryear style rather than, say, some numeric style.

The Elsevier template you've linked to provides eight [8!] candidate bibliography styles, but only three of them do not contain num in their filenames. This leaves three candidate bibliography styles: model2-names, model4-names, and model5-names. (Annoyingly, Elsevier doesn't seem to provide a list of what the various bib style files do.) Testing them one after the other reveals that you should be using model5-names.

Aside: I couldn't help but notice that both of the sample bib entries contain syntax and content errors. I realize you copied these entries from a template file, so it's moderately disturbing that Elsevier would distribute such faulty sample bib entries. E.g., there is a non-ASCII character in the number field of the "Dirac" entry, Lorentz should be encased in curly braces to keep it from being lower-cased, and spaces should be inserted between first and middle name initials of all authors. (Otherwise, only the first initial is printed; that's probably not what's called for.) Also, it's a really bad idea to combine the surname and "junior" components of an author's full name. In the code below, I've tried to fix some of these errors.

\RequirePackage{filecontents}
\begin{filecontents}{mybibfile.bib}
@article{Feynman1963118,
title   = "The theory of a general quantum system
interacting with a linear dissipative system",
journal = "Annals of Physics",
volume  = "24",
pages   = "118--173",
year    = "1963",
doi     = "10.1016/0003-4916(63)90068-X",
author  = "R. P. Feynman and Vernon, Jr., F. L.",
}
@article{Dirac1953888,
title   = "The {Lorentz} transformation and absolute
time",
journal = "Physica",
volume  = "19",
number  = "1--12",
pages   = "888--896",
year    = "1953",
doi     = "10.1016/S0031-8914(53)80099-6",
author  = "P. A. M. Dirac",
}
\end{filecontents}

\documentclass[3p,times,twocolumn,authoryear]{elsarticle}
\bibliographystyle{model5-names}
\usepackage{ecrc} % required by journal
\usepackage[spaces,hyphens,obeyspaces]{url}

• apacite has conflict with elsarticle resulting into error Jul 9, 2016 at 14:13