I am trying to use moderncv
in conjunction with the aas_macros.sty
(found at http://cdsads.u-strasbg.fr/abs_doc/aas_macros.sty). However, the following fails:
\documentclass[11pt,letterpaper,sans]{moderncv}
\usepackage{aas_macros}
\name{First}{Last}
\begin{document}
\nocite{*}
\bibliographystyle{plain}
\bibliography{test}
\end{document}
while the following
\documentclass[11pt,letterpaper,sans]{paper}
\usepackage{aas_macros}
%\name{First}{Last}
\begin{document}
\nocite{*}
\bibliographystyle{plain}
\bibliography{test}
\end{document}
works just fine. In both cases, the test.bib
file contains
@ARTICLE{2015ApJ...806L..12O,
author = {{Oishi}, J.~S. and {Mac Low}, M.-M. and {Collins}, D.~C. and {Tamura}, M.},
title = "{Self-generated Turbulence in Magnetic Reconnection}",
journal = {\apjl},
archivePrefix = "arXiv",
eprint = {1505.04653},
primaryClass = "astro-ph.SR",
keywords = {magnetic reconnection, turbulence},
year = 2015,
month = jun,
volume = 806,
eid = {L12},
pages = {L12},
doi = {10.1088/2041-8205/806/1/L12},
adsurl = {http://adsabs.harvard.edu/abs/2015ApJ...806L..12O},
adsnote = {Provided by the SAO/NASA Astrophysics Data System}
}
Could anyone provide guidance on what is going on? Incidentally, this is a duplicate of Undefined control sequence error with moderncv but with a minimum failing case.
Thanks!
Best Answer
The AAS macros are part of the document class
aastex
. So if you want to use these macros you should use this class and notmoderncv
. Classmoderncv
does not know what\def\apjl{\ref@jnl{ApJ}}
from your namedsty
files should do.So in my eyes the best would be---if you insist in using this abreviation commands---to create an own abreviation file, for example
my-aas_macros.sty
and add there the renaming command.For example:
If you have abreviations please add them in a new line. Or copy lines 37 until line 101 of
ass_macros.sty
and change all of them as shown above (\apjl
you find in line 41).Now change your line
\usepackage{aas_macros}
to\usepackage{my-aas_macros}
to use the bib file from the journal with their abreviations.