Tenho um artigo no qual estou usando o natbib com sort&compress
opção, mas parece não funcionar
\documentclass[11pt,english]{article}
\usepackage[T1]{fontenc}
\usepackage[latin1]{inputenc}
\usepackage[a4paper]{geometry}
\geometry{verbose,tmargin=3cm,bmargin=3cm,lmargin=2cm,rmargin=2cm}
\usepackage{mathrsfs}
\usepackage{amsmath}
\usepackage{amssymb}
\usepackage[sort&compress,numbers]{natbib}
\usepackage{babel}
\begin{document}
\title{Title}
\maketitle
\begin{abstract}
Abstract text
\end{abstract}
\section{Introduction}
Introduction text \citet{J2009,J2013,J2016}.
\bibliographystyle{unsrtnat}
\bibliography{references}
\end{document}
e este é o arquivo de referências
% filename references.bib
@Article{J2016,
author = {Jappo, P.M.},
title = {Title1},
journal = {Mech. Res. Commun.},
year = {2016},
volume = {X},
pages = {1--2},
}
@Article{J2013,
author = {Jappo, P.M.},
title = {Title2},
journal = {Phys. Lett. A},
year = {2013},
volume = {X},
pages = {1--2},
}
@Article{J2009,
author = {Jappo, P.M.},
title = {Title3},
journal = {Math. Comput. Simul},
year = {2009},
volume = {X},
pages = {1--2},
}
Responder1
natbib
não é capaz de classificar \citet
citações, porque classifica e compacta apenas sequências numéricas. Ele não testa se os nomes são iguais ou não, antes de compactar as sequências numéricas. Portanto, apenas \cite
ou \citep
pode ser compactado.
\documentclass[11pt,english]{article}
\usepackage[T1]{fontenc}
\usepackage[utf8]{inputenc}
\usepackage[sort&compress,numbers]{natbib}
\usepackage{babel}
\begin{document}
\title{Title}
\maketitle
\begin{abstract}
Abstract text
\end{abstract}
\section{Introduction}
Introduction text \cite{J2009,J2013,J2016}.
\bibliographystyle{unsrtnat}
\bibliography{\jobname}
\end{document}
A documentação de natbib
fato é de alguma forma enganosa.
Se você sabe que os autores são iguais, você pode usar
Introduction text \citeauthor{J2009} \cite{J2009,J2013,J2016}.
obter
mas eu chamaria isso apenas de uma solução alternativa, não de uma solução.
Uma verdadeira solução seria mudar parabiblatex
combiber
. Você pode usar a opção natbib
, se não quiser alterar tudo \citet
no seu documento existente:
\begin{filecontents*}{\jobname.bib}
% filename references.bib
@Article{J2016,
author = {Jappo, P.M.},
title = {Title1},
journal = {Mech. Res. Commun.},
year = {2016},
volume = {X},
pages = {1--2},
}
@Article{J2013,
author = {Jappo, P.M.},
title = {Title2},
journal = {Phys. Lett. A},
year = {2013},
volume = {X},
pages = {1--2},
}
@Article{J2009,
author = {Jappo, P.M.},
title = {Title3},
journal = {Math. Comput. Simul},
year = {2009},
volume = {X},
pages = {1--2},
}
\end{filecontents*}
\documentclass[11pt,english]{article}
\usepackage[T1]{fontenc}
\usepackage[utf8]{inputenc}
\usepackage[style=numeric-comp,sortcites,natbib]{biblatex}
\usepackage{babel}
\addbibresource{\jobname.bib}
\begin{document}
\title{Title}
\maketitle
\begin{abstract}
Abstract text
\end{abstract}
\section{Introduction}
Introduction text \citet{J2009,J2013,J2016}.
\printbibliography
\end{document}
Isto resulta em: