編譯錯誤:bbl 檔案中缺少插入 $

編譯錯誤:bbl 檔案中缺少插入 $

我有以下乳膠樣本:

    \begin{filecontents}{\jobname.bib}

    @InProceedings{ttest,
    author="H{\"u}bner, Jomi Fred
    and Sichman, Jaime Sim{\~a}o
    and Boissier, Olivier",
    editor="Boissier, Olivier
    and Padget, Julian
    and Dignum, Virginia
    and Lindemann, Gabriela
    and Matson, Eric
    and Ossowski, Sascha
    and Sichman, Jaime Sim{\~a}o
    and V{\'a}zquez-Salceda, Javier",
    title="{\$}{\backslash}mathcal{\{}S-M{\}}oise^{\{}+{\}}{\$}: A Middleware for Developing Organised Multi-agent Systems",
    booktitle="Coordination, Organizations, Institutions, and Norms in Multi-Agent Systems",
    year="2006",
    publisher="Springer Berlin Heidelberg",
    address="Berlin, Heidelberg",
    pages="64--77",
    isbn="978-3-540-35176-4"
}

\end{filecontents}
\documentclass{article}

\begin{document}
something about \cite{ttest} and also.

\bibliographystyle{plain}
\bibliography{\jobname}
\end{document}

當我使用 pdflatex 編譯時,出現此錯誤:缺少插入的 $。錯誤位於 bbl 檔案中

提前謝謝。

答案1

您從該期刊網站獲得的資訊具有過於激進的轉義功能。該title條目應該是

title="{$\mathcal{S-M}oise^{+}$}: A Middleware foar Developing Organised Multi-agent Systems",

我會使用該filecontents包,因為標準filecontents環境一旦創建就永遠不會覆蓋生成的文件。讓不知道這一點的用戶感到困惑。

這是修正後的 MWEfilecontents

\documentclass{article}
\usepackage{filecontents}
\begin{filecontents*}{\jobname.bib}

    @InProceedings{ttest,
    author="H{\"u}bner, Jomi Fred
    and Sichman, Jaime Sim{\~a}o
    and Boissier, Olivier",
    editor="Boissier, Olivier
    and Padget, Julian
    and Dignum, Virginia
    and Lindemann, Gabriela
    and Matson, Eric
    and Ossowski, Sascha
    and Sichman, Jaime Sim{\~a}o
    and V{\'a}zquez-Salceda, Javier",
    title="{$\mathcal{S-M}oise^{+}$}: A Middleware foar Developing Organised Multi-agent Systems",
    booktitle="Coordination, Organizations, Institutions, and Norms in Multi-Agent Systems",
    year="2006",
    publisher="Springer Berlin Heidelberg",
    address="Berlin, Heidelberg",
    pages="64--77",
    isbn="978-3-540-35176-4" 
}
\end{filecontents*}


\begin{document}
something about \cite{ttest} and also.

\bibliographystyle{plain}
\bibliography{\jobname}
\end{document}

filecontents之間的差異請參閱手冊filecontentsfilecontents*

相關內容