TeX - LaTeX Stack Exchange is a question and answer site for users of TeX, LaTeX, ConTeXt, and related typesetting systems. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

In my kile documents, I want to add multiple citations. For this I use the command


The names in this command give numeric references, which is what I wanted, but not in the way I want it. It gives [1,2,3,4,5,6,7] instead of [1,2,4-8]. Is there any other way to manage this? My bibliography style is elsarticle-num, and I use bibtex for the bibliography.

I use this preamble in my document:

share|improve this question
Welcome to TeX.sx! Your comment to Mico's answer would probably be added by a minimal working example (MWE): could you edit one into the question? You don't have to sign with your name since it automatically appears in the lower right corner of your post: I'll edit it out. – Joseph Wright Nov 11 '12 at 13:13
up vote 11 down vote accepted

(Answer modified after the OP provided additional, crucial information about the document's setup.)

Since you're using the elsarticle document class, which loads the natbib citation management package, just issue the command


in the preamble. This instructs natbib to sort and compress numeric-style citations. (Note that there seems to be a typo in the documentation of the elsarticle document class: The option should be spelled numbers rather than number.)

share|improve this answer
Thanks for the reply Mico. I checked that cite package already is installed under texlive. However, I got this error when multiple citations are given with the cite command: paragraph ended befor \@citex was complete ? – Rıza Bayoğlu Nov 11 '12 at 13:03
@RızaBayoğlu - please augment your question with some code that demonstrates what exactly you're doing. Without such information, it's going to be virtually impossible to come up with a solution. Thanks. – Mico Nov 11 '12 at 13:30
\documentclass[review,preprint,twocolumn,3p]{elsarticle} \usepackage{graphicx} \usepackage{color} \usepackage{url} \usepackage{ctable} \usepackage{booktabs} % \usepackage{cite} \usepackage{tabularx} \usepackage{array} \usepackage{soul} \usepackage{multirow} \usepackage{lineno} \usepackage{subfigure} \usepackage{amssymb,amsmath} \newcommand{\tab}{\hspace{5mm}} – Rıza Bayoğlu Nov 11 '12 at 13:38
I use the command in introduction part of my document in kile: \cite{cristo,taylor,polgar,phillips,speirs,simoes,roberto}. But the names in this command gives numeric refecences which is what I wanted, but not in the way I mentioned in my question. I mean it gives [1,2,3,4,5,6,7]. I hope that information is adequate. @Micho – Rıza Bayoğlu Nov 11 '12 at 13:44
@RızaBayoğlu - Hmm, there seems to be a typo in the documentation for the elsarticle document class: the option should be spelled numbers and not number! I'm updating my answer accordingly. – Mico Nov 11 '12 at 16:15

put the command sort&compress in the documentclass options: \documentclass[3p,sort&compress]{elsarticle}

share|improve this answer
Welcome to TeX.SX! You can have a look on our starter guide to familiarize yourself further with our format. Your "answer" would be better as a comment on Mico's answer. All you are saying is that option can be passed to the class rather using the \biboptions command. – Andrew Swann Jun 4 '13 at 10:00

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

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