首页 > 编程知识 正文

6 LaTeX 参考文献的排版与引用,参考文献的排版格式

时间:2023-05-05 08:29:06 阅读:278711 作者:2228

LaTeX 参考文献的排版与引用

​ 在论文写作的过程中,为了体现论文的科学性、严谨性和规范性,我们常常需要引用大量的参考文献来引证自己的观点。参考文献(Reference)往往都是放在论文的最后,记录了所引用论文的标题、作者、期刊或会议、出版时间等信息,文中还需要明确有顺序的进行引用标注。

​ 本篇将介绍 LaTeX 常用的参考文献排版与引用方式,所用到的宏包都要写在 documentclass 命令之后和 begin{docuemnt}之前,在本文中,我们会用的宏包文件有:

usepackage{cite}usepackage[number, sort&compress]{natbib} 1. 直接插入参考文献

先在文章的最后写好需要插入的参考文献,逐一列举出来。例如:

begin{thebibliography}{100}bibitem{ref1}Lv Y, Duan Y, Kang W, et al. Traffic flow prediction with big data: a deep learning approach[J]. IEEE Transactions on Intelligent Transportation Systems, 2014, 16(2): 865-873.bibitem{ref2}Wu Y, Tan H, Qin L, et al. A hybrid deep learning based traffic flow prediction method and its understanding[J]. Transportation Research Part C: Emerging Technologies, 2018, 90: 166-180.bibitem{ref3}Polson N G, Sokolov V O. Deep learning for short-term traffic flow prediction[J]. Transportation Research Part C: Emerging Technologies, 2017, 79: 1-17.bibitem{ref4}Yin H, Wong S C, Xu J, et al. Urban traffic flow prediction using a fuzzy-neural approach[J]. Transportation Research Part C: Emerging Technologies, 2002, 10(2): 85-98.bibitem{ref5}Fu R, Zhang Z, Li L. Using LSTM and GRU neural network methods for traffic flow prediction[C]//2016 31st Youth Academic Annual Conference of Chinese Association of Automation (YAC). IEEE, 2016: 324-328.end{thebibliography}

上面列举了5个参考文献 {thebibliography}[100] 的选项100表示参考文献的最大数量为100。bibitem{label} 表示一条参考文献,其中的 label 则表示的是文献的标注,即在正文的引用中会被用到。

效果如下:

那么我们如何在文中对其进行引用呢?参考文献的引用需要用到 usepackage{cite},参考文献的引用要用到命令 cite,例如我们要引用上面的参考文献,可以这样引用:

section{REFERENCES}subsection{An overview of references}We want to cite the paper cite{ref1} parWe want to cite the paper cite{ref1,ref2,ref5} parWe want to cite the paper cite{ref1,ref2,ref3}

1、单篇参考文献引用:

We want to cite the paper cite{ref1}

2、多篇参考文献一起引用:

需要用到的一个宏包:usepackage[numbers,sort&compress]{natbib},它可以将连续的数字引用进行合并,即:[1, 2, 3] 合并成 [1-3],这样显得更美观更得体。而对于间断的数字引用则直接用逗号分开即可。

We want to cite the paper cite{ref1,ref2,ref5}We want to cite the paper cite{ref1,ref2,ref3}

直接将参考文献写在 tex 文件中,基本上符合“所见即所得”。

2. BibTex 引用格式

BibTeX 是一种格式和一个程序,用于协调LaTeX的参考文献处理. BibTeX 使用数据库的的方式来管理参考文献. BibTeX 文件的后缀名为 .bib .

我们在当前 tex 文件所在的文件目录下,创建一个以 .bib 为后缀的格式文件,命名为 lookup.bib

bib 文件中的内容一般都是用论文查找网站生成的,最常用的是谷歌学术或百度学术。比如:想要查找某一篇文献的 bib 格式,可以按照如下的方法:

然后我们就能得到如下内容:

@article{2015Traffic, title={Traffic Flow Prediction With Big Data: A Deep Learning Approach}, author={ Lv, Y. and Duan, Y. and Kang, W. and Li, Z. and Wang, F. Y. }, journal={IEEE Transactions on Intelligent Transportation Systems}, volume={16}, number={2}, pages={865-873}, year={2015},}

下面我们将详细讲解每一部分:

1、标签

大括号紧随其后的就是标签:

@article{2015Traffic,}

这个标签是可以改动的,只要和本论文中其他的参考文献不重复就行。

2、文献参数

title:论文题目,author:论文作者,journal:论文发布期刊、会议或者所属,有些论文用booktitle,volume:卷,number:号,pages:页码,year:年份

有些论文生成可能没有这么全,就需要我们去找到相关的信息,自己补进来了。

创建的 ref.bib 格式文件如下:

@article{2015Traffic, title={Traffic Flow Prediction With Big Data: A Deep Learning Approach}, author={ Lv, Y. and Duan, Y. and Kang, W. and Li, Z. and Wang, F. Y. }, journal={IEEE Transactions on Intelligent Transportation Systems}, volume={16}, number={2}, pages={865-873}, year={2015},}@inproceedings{2017Traffic, title={Traffic Flow Prediction with Big Data: A Deep Learning based Time Series Model}, author={ Chen, Y. and Lei, S. and Lei, W. }, booktitle={IEEE INFOCOM 2017 -IEEE Conference on Computer Communications Workshops (INFOCOM WKSHPS)}, year={2017},}@article{2019Big, title={Big data‐driven machine learning‐enabled traffic flow prediction}, author={ Fanhui, Kong and Jian, Li and 清秀的钢笔, Jiang and Tianyuan, Zhang and Houbing, Song }, journal={Transactions on Emerging Telecommunications Technologies}, volume={30}, pages={e3482-}, year={2019},}@article{2019Deep, title={Deep Transfer Learning for Intelligent Cellular Traffic Prediction Based on Cross-Domain Big Data}, author={ Zhang, C. and Zhang, H. and Qiao, J. and Yuan, D. and Zhang, M. }, journal={IEEE Journal on Selected Areas in Communications}, pages={1-1}, year={2019},}@article{Hong2014Deep, title={Deep Architecture for Traffic Flow Prediction: Deep Belief Networks With Multitask Learning}, author={Hong and H. and Xie and K. and Huang and W. and Song and G.}, journal={IEEE transactions on intelligent transportation systems}, volume={15}, number={5}, pages={2191-2201}, year={2014},}

如何在正文中引用呢?引用格式与上面大致相同。

section{REFERENCES}subsection{An overview of references}We want to cite the paper cite{2015Traffic}, parWe want to cite the paper cite{2017Traffic, 2019Big, 2019Deep}, parWe want to cite the paper cite{2017Traffic, Hong2014Deep}, parbibliographystyle{ieeetr}bibliography{ref} %% 在论文最末,end{document}之前

bibliographystyle{...} 是插入参考文献的样式,不同的杂志期刊的样式不一样。常见的预设样式的可选项有8种,分别是:

plain:按字母的顺序排列,比较次序为作者、年度和标题;unsrt:样式同plain,只是按照引用的先后排序;abbrv:类似plain,将月份全拼改为缩写,更显紧凑;ieeetr:国际电气电子工程师协会期刊样式;acm:美国计算机学会期刊样式;siam:美国工业和应用数学学会期刊样式;

bibliography{ref} 的作用是插入ref.bib 文件

3. BibTeX 引用网页

网页的参考文献最终样式是:

[1] 作者. 网页名称. (时间). [Online]. Available: 网页链接(网址)

使用bib文件就要使用下面这种格式:

@article{bitcoin, title={Bitcoin: A peer-to-peer electronic cash system}, author={Nakamoto, Satoshi}, journal={Decentralized Business Review}, pages={21260}, year={2008, Jun 12}}

论文我们可以使用一些浏览论文的网站生成(如谷歌学术和百度学术),但是网页没有怎么办呢?

网页引用需要涉及到五个部分:标签、作者、标题、链接以及时间。其中标签、标题和链接是必不可少的

@online{标签, author="作者名称", title="{网页名称}", url="网页链接", note="(年, 月 日)",}

online表示的是该文献是网页,其中最重要的格式是时间(2021, Jun 1):

要用阿拉伯数字,且年后要加逗号;

要用英文前三个字母,且首字母大写。

要用阿拉伯数字,要和月有一个空格。

我们举个例子,例如我们的论文中使用到了某一个库——PBC库,我们需要去PBC库的官网获取相关的信息:

@online{PBClibrary, author="Ben Lynn", title="{The Pairing-Based Cryptography (PBC) library}", url="https://crypto.stanford.edu/pbc/", note="(2013, Jun 14)",}

此处用到了 bibliographystyle{IEEEtran} 这种排版格式。

记录一个小问题:tex 的 bib 引用时出现 empty ’thebibliography’ environment on input line …

如果一个文章中没有cite 命令,BibTex 就不知道哪一个bibliography是需要插入的。所以必须在你文章引用的地方加入cite.

飞艇如何买前5后5gent Cellular Traffic Prediction Based on Cross-Domain Big Data}, author={ Zhang, C. and Zhang, H. and Qiao, J. and Yuan, D. and Zhang, M. }, journal={IEEE Journal on Selected Areas in Communications}, pages={1-1}, year={2019},}@article{Hong2014Deep, title={Deep Architecture for Traffic Flow Prediction: Deep Belief Networks With Multitask Learning}, author={Hong and H. and Xie and K. and Huang and W. and Song and G.}, journal={IEEE transactions on intelligent transportation systems}, volume={15}, number={5}, pages={2191-2201}, year={2014},}

如何在正文中引用呢?引用格式与上面大致相同。

section{REFERENCES}subsection{An overview of references}We want to cite the paper cite{2015Traffic}, parWe want to cite the paper cite{2017Traffic, 2019Big, 2019Deep}, parWe want to cite the paper cite{2017Traffic, Hong2014Deep}, parbibliographystyle{ieeetr}bibliography{ref} %% 在论文最末,end{document}之前

bibliographystyle{...} 是插入参考文献的样式,不同的杂志期刊的样式不一样。常见的预设样式的可选项有8种,分别是:

plain:按字母的顺序排列,比较次序为作者、年度和标题;unsrt:样式同plain,只是按照引用的先后排序;abbrv:类似plain,将月份全拼改为缩写,更显紧凑;ieeetr:国际电气电子工程师协会期刊样式;acm:美国计算机学会期刊样式;siam:美国工业和应用数学学会期刊样式;

bibliography{ref} 的作用是插入ref.bib 文件

3. BibTeX 引用网页

网页的参考文献最终样式是:

[1] 作者. 网页名称. (时间). [Online]. Available: 网页链接(网址)

使用bib文件就要使用下面这种格式:

@article{bitcoin, title={Bitcoin: A peer-to-peer electronic cash system}, author={Nakamoto, Satoshi}, journal={Decentralized Business Review}, pages={21260}, year={2008, Jun 12}}

论文我们可以使用一些浏览论文的网站生成(如谷歌学术和百度学术),但是网页没有怎么办呢?

网页引用需要涉及到五个部分:标签、作者、标题、链接以及时间。其中标签、标题和链接是必不可少的

@online{标签, author="作者名称", title="{网页名称}", url="网页链接", note="(年, 月 日)",}

online表示的是该文献是网页,其中最重要的格式是时间(2021, Jun 1):

要用阿拉伯数字,且年后要加逗号;

要用英文前三个字母,且首字母大写。

要用阿拉伯数字,要和月有一个空格。

我们举个例子,例如我们的论文中使用到了某一个库——PBC库,我们需要去PBC库的官网获取相关的信息:

@online{PBClibrary, author="Ben Lynn", title="{The Pairing-Based Cryptography (PBC) library}", url="https://crypto.stanford.edu/pbc/", note="(2013, Jun 14)",}

此处用到了 bibliographystyle{IEEEtran} 这种排版格式。

记录一个小问题:tex 的 bib 引用时出现 empty ’thebibliography’ environment on input line …

如果一个文章中没有cite 命令,BibTex 就不知道哪一个bibliography是需要插入的。所以必须在你文章引用的地方加入cite.

版权声明:该文观点仅代表作者本人。处理文章:请发送邮件至 三1五14八八95#扣扣.com 举报,一经查实,本站将立刻删除。