# change achemso style in chapterbib

I have a root file and a separate chapter.tex and chapter.bib for each chapter (per the chapterbib setup: I am not using the achemso package).

Root file:

\documentclass[12pt,oneside,final]{thesis}
\usepackage{chapterbib}
\usepackage[superscript]{cite}
\usepackage{chemstyle}
\usepackage{cite}
\begin{document}
\title{Title}
\include{chapter1}
\end{document}


Chapter 1 (as a separate tex file)

\chapter{Chapter 1}
Text goes here\cite{person2013malaria}
\bibliographystyle{achemso}
\bibliography{./Bibliographies/chapter1}


Bib file (as a separate .bib file saved to the appropriate directory above)

@article{person2013malaria,
title={Malaria},
author={Person, One and Person, Two and Person, Three and Person, Four and Person, Five and Person, Six and Person, Seven and Person, Eight and Person, Nine and Person, Ten and Person, Eleven},
journal={J. Amer. Med. Assoc.},
volume={25},
number={2},
pages={160},
year={2013},
publisher={LWW}
}


I am trying to control my achemso style bibliography with the following command:

@Control{achemso-control,
ctrl-article-title = "yes",
ctrl-chapter-title = "no",
ctrl-etal-number = "99",
ctrl-etal-firstonly = "no",
}


...with no success. Not sure if I'm putting it in the wrong location (have tried adding it directly to the .bib file, saved as a separate .bib file (chapter1-control.bib) and calling it in with the \bibliography command.

If you are using the control system by hand, there are two things to do:

• Include a @Control entry in one of your databases
• Cite that control entry (using \nocite, so no text is printed)

If you are using multiple bibliographies, the magic citation needs to apply to each one. Thus a minimal working example would be something like:

\begin{filecontents}{\jobname-chapter-one}
\nocite{achemso-control}% Special citation here
\chapter{Chapter 1}
Text goes here\cite{person2013malaria}
\bibliographystyle{achemso}
\bibliography{\jobname-chapter-one}
\end{filecontents}
\begin{filecontents}{\jobname-chapter-one.bib}
@article{person2013malaria,
title={Malaria},
author={Person, One and Person, Two and Person, Three and Person, Four and Person, Five and Person, Six and Person, Seven and Person, Eight and Person, Nine and Person, Ten and Person, Eleven},
journal={J. Amer. Med. Assoc.},
volume={25},
number={2},
pages={160},
year={2013},
publisher={LWW}
}

@Control{achemso-control,
ctrl-article-title = "yes",
ctrl-chapter-title = "no",
ctrl-etal-number = "99",
ctrl-etal-firstonly = "no",
}
\end{filecontents}

\documentclass{report}
\usepackage[sort&compress,numbers]{natbib}
\usepackage{chapterbib}
\usepackage{chemstyle}
\begin{document}
\title{Title}
\include{\jobname-chapter-one}
\end{document}


Notice that I've included the special \nocite{achemso-control} citation at the start of the file. Also, importantly, notice that achemso is a natbib-based bibliography style, so you cannot use the cite package and must use the appropriate set up in natbib.

In the above, I've included the special entry in the same .bib file as the real citations. You don't have to do that, and indeed the way the achemso package does things is to create a dedicated .bib file with just this one entry in it. If you do that, a demo might look like:

\begin{filecontents}{\jobname-chapter-one}
\chapter{Chapter 1}
\nocite{achemso-control}
Text goes here\cite{person2013malaria}
\bibliographystyle{achemso}
\bibliography{\jobname-control,\jobname-chapter-one}
\end{filecontents}
\begin{filecontents}{\jobname-chapter-one.bib}
@article{person2013malaria,
title={Malaria},
author={Person, One and Person, Two and Person, Three and Person, Four and Person, Five and Person, Six and Person, Seven and Person, Eight and Person, Nine and Person, Ten and Person, Eleven},
journal={J. Amer. Med. Assoc.},
volume={25},
number={2},
pages={160},
year={2013},
publisher={LWW}
}
\end{filecontents}
\begin{filecontents}{\jobname-control.bib}
@Control{achemso-control,
ctrl-article-title = "yes",
ctrl-chapter-title = "no",
ctrl-etal-number = "99",
ctrl-etal-firstonly = "no",
}
\end{filecontents}

\documentclass{report}
\usepackage[sort&compress,numbers]{natbib}
\usepackage{chapterbib}
\usepackage{chemstyle}
\begin{document}
\title{Title}
\include{\jobname-chapter-one}
\end{document}


where the same control database can then be used by each chapter (you still need to cite it in each one!).

• strangely, when I replace {cite} with {natbib}, it does not compile, giving the error \newblock undefined with reference to this line in the bbl - \begin{thebibiliography}{10}. With {cite}, it compiles fine but does not read the control sequence (et al still used, etc). And of course, thank you for your time – nihjhu Jun 30 '13 at 18:33
• @nihjhu This may be down to your document class: I have used article as there are several thesis.cls files about. \newblock should be provided by your class, but \AtBeginDocument{\providecommand{\newblock}{}} should deal with any errors. – Joseph Wright Jun 30 '13 at 19:37