我必须使用期刊的 Latex 模板,该模板指定 \documentclass{book}。该模板假定我将以他们想要的格式手动输入参考文献。但是,我想使用 bibtex 输入参考文献。当我这样做时,它会强制参考书目从奇数页开始。我希望参考文献在文章结束后直接开始。我尝试将 documentclass 更改为“article”,但这会导致错误,因为模板使用 chapter 格式。有没有办法恢复到书籍 documentclass 中的文章样式参考文献?
\documentclass[10pt]{book}
\begin{document}
Document contents here with use of \cite.
\renewcommand{\bibname}{References} % to change "Bibliography" to "References"
\bibliography{refs} % starts references on next odd-numbered page
\bibliographystyle{plainnat}
\end{document}
答案1
如果你是不是加载natbib
,你可以\thebibliography
使用它\section*
来代替\chapter*
:
\documentclass[10pt]{book}
\usepackage{etoolbox}
\patchcmd{\thebibliography}
{\chapter*}
{\section*}
{}
{}
\renewcommand{\bibname}{References}
% this is just for the example
\usepackage{filecontents}
\begin{filecontents*}{refs.bib}
@article{testa,
author = {The A Author},
year = {2014},
title = {The title A},
journal = {The journal A},
pages = {1--5},
}
\end{filecontents*}
% this is just for the example
\begin{document}
\cite{testa}
\bibliographystyle{plainnat}
\bibliography{refs}
\end{document}
如果您正在加载natbib
,那么您所要做的就是重新定义\bibsection
:
\documentclass[10pt]{book}
\usepackage{natbib}
\renewcommand\bibsection{%
\section*{\bibname\markright{\MakeUppercase{\bibname}}}}
\renewcommand{\bibname}{References}
% this is just for the example
\usepackage{filecontents}
\begin{filecontents*}{refs.bib}
@article{testa,
author = {The A Author},
year = {2014},
title = {The title A},
journal = {The journal A},
pages = {1--5},
}
\end{filecontents*}
% this is just for the example
\begin{document}
\cite{testa}
\bibliographystyle{plainnat}
\bibliography{refs}
\end{document}