20

I have to use Springer [sn-mathphys]{sn-jnl} template to submit a paper and I'm afraid that I'm unable to generate the bibliography. Not even when I use the sample file sn-article.tex that they provide, without changing anything! However, when I compile the file changing the style to \documentclass{article} everything goes fine.

I've tried TexnicCenter and with Winedt; both of them with Biblatex and Biber. In all cases, I keep on getting the error:

" Cannot find 'sn-article.bcf'!"

The format can be found here: https://www.springernature.com/gp/authors/campaigns/latex-author-support

I've searched the web for hours and I've tried many things. Neither one worked. For example:

  1. add at the preamble \usepackage{natbib}
  2. Create the .bbl file and then use \input{sn-article.bbl}

I've seen that many people have had this same problem for years, but I'm afraid that the solutions that they applied are not working for me. Can anyone help me, please?

1
  • If the template is downloaded under several folders and subfolders, try getting rid of these...that fixed the issue for me. Jan 17, 2022 at 18:56

6 Answers 6

21

I have faced this problem, after searching for more than 6 hours even unable to solve it. Indeed it's a very serious problem for those dealing with it.

It has a very interesting solution.

Step 1: Download the springer Latex Template from here.

Step 2: Find "bst" folder in the downloaded zip file from the link given above.

Step 3: Find the required file which you are using in your manuscript i.e.

sn-mathphys, sn-aps, sn-vancouver etc

Step 4: Copy and paste that file into your main folder/directory.

Step 5: Just Run your "main.tex" file with Bibtex and then with pdfLatex.

And problem solved.

3
  • 1
    This was the easiest fix for me! Clearly they didn't give good enough instructions in their template!
    – jdods
    Oct 5, 2022 at 23:45
  • 4
    You are right: the appropriate files are "hidden" within the subfolder \bst of the template supplied by Springer, it is necessary to copy and paste them into the same folder than your main tex file. That should be the accepted answer. Jan 5, 2023 at 13:19
  • 1
    After doing this I face with following error message: I found no \bibstyle command---while reading file sn-article.aux is it possible to prevent it?
    – alper
    Oct 4, 2023 at 20:56
14

I struggled with this for over 3 hours. So, for anyone going through the same.

There is a problem with sns-basic and sns-mathphys bib style files, so I recommend you use sns-vancuover or sns-aps options to the sn-jnl class. The author-year styles like sns-apa should also work, though I have not tried them.

Before you compile your latex script, go to the sn-jnl.cls file and replace the following lines starting with the %% Macros for bibliographystyles %% heading on Line 1643 and ending with the %% Macros for border matrix %% heading on Line 1732 as at Nov 15 2021.

%% Macros for bibliographystyles %%

% \def\bibcommenthead{\if@bibcomment\begingroup\parindent=0pt\parskip=0pt%
% \removelastskip\vskip13pt\nointerlineskip%
%
% \vbox{\bibfont If you are submitting to one of the Nature Research journals, using the eJP
%  submission system, please include the references within the manuscript file itself. You may
%  do this by copying the reference list from your .bbl file, and pasting it into the bibliography
%  environment of the main manuscript .tex file.}\par%
% \removelastskip\nobreak\vskip13pt\nobreak%
% \endgroup\fi}%

\def\bibcommenthead{}%

\if@Spr@basic@refstyle%
  \usepackage[authoryear]{natbib}%
  \gdef\NumBib{NO}%
  \bibliographystyle{bst/sn-basic}%
  \setlength{\bibsep}{1em}%
  \def\bibfont{\reset@font\fontfamily{\rmdefault}\normalsize\selectfont}%
\fi%
\if@Mathphys@refstyle%
  \usepackage[numbers,sort&compress]{natbib}%
  \gdef\NumBib{YES}%
  \bibliographystyle{bst/sn-mathphys}%
  \setlength{\bibsep}{1em}%
  \def\bibfont{\reset@font\fontfamily{\rmdefault}\normalsize\selectfont}%
\fi%
\if@APS@refstyle%
  \usepackage[numbers,sort&compress]{natbib}%
  \gdef\NumBib{YES}%
  \bibliographystyle{bst/sn-aps}%
  \setlength{\bibsep}{1em}%
  \def\bibfont{\reset@font\fontfamily{\rmdefault}\normalsize\selectfont}%
\fi%
\if@Vancouver@refstyle%
  \usepackage[numbers,sort&compress]{natbib}%
  \gdef\NumBib{YES}%
  \bibliographystyle{bst/sn-vancouver}%
  \setlength{\bibsep}{1em}%
  \def\bibfont{\reset@font\fontfamily{\rmdefault}\normalsize\selectfont}%
\fi%
\if@APA@refstyle%
  \usepackage[natbibapa]{apacite}%
  \gdef\NumBib{NO}%
  \bibliographystyle{bst/sn-apacite}%
  \def\refdoi#1{\urlstyle{rm}\url{#1}}%
  \renewcommand{\doiprefix}{}%
  \AtBeginDocument{%
    \renewcommand{\BPBI}{.}% Period between initials - command from apacite.sty
  }%
  \setlength{\bibsep}{1em}%
  \def\bibfont{\reset@font\fontfamily{\rmdefault}\normalsize\selectfont}%
\fi%
\if@Chicago@refstyle%
  \usepackage[authoryear]{natbib}%
  \gdef\NumBib{NO}%
  \bibliographystyle{bst/sn-chicago}%
  \hypersetup{urlcolor=black,colorlinks=false,pdfborder={0 0 0}}\urlstyle{same}%
  \setlength{\bibsep}{1em}%
  \def\bibfont{\reset@font\fontfamily{\rmdefault}\normalsize\selectfont}%
\fi%
\if@Standard@Nature@refstyle%
  \usepackage[numbers,sort&compress]{natbib}%
  \gdef\NumBib{YES}%
  \bibliographystyle{bst/sn-standardNature}%
  \setlength{\bibsep}{1em}%
  \def\bibfont{\reset@font\fontfamily{\rmdefault}\normalsize\selectfont}%
\fi%
\if@Default@refstyle%
  \usepackage[numbers,sort&compress]{natbib}%
  \gdef\NumBib{YES}%
  \setlength{\bibsep}{1em}%
  \def\bibfont{\reset@font\fontfamily{\rmdefault}\normalsize\selectfont}%
\fi%

\AtBeginDocument{\allowdisplaybreaks}%

\def\eqnheadfont{\reset@font\fontfamily{\rmdefault}\fontsize{16}{18}\bfseries\selectfont}%

\newcommand{\eqnhead}[1]{\begingroup%
\begin{center}
{\eqnheadfont #1}\par%
\end{center}
\removelastskip\vskip24pt%
\thispagestyle{titlepage}%%
%%\thispagestyle{empty}%
\endgroup}

%% Macros for border matrix %%
1
  • 1
    This should be reported to Springer Nature so they can improve their latex template.
    – sugab
    Oct 14, 2022 at 7:52
7

In a nutshell there is a problem with sn-mathphys.bst that has to be referred to Springer Nature. You should be able to show them that it is not a problem with WinEdt, your installation of LateX or BibTeX.

So first you have to test your installation and get the right information to submit to the editorial. These are the steps to follow.

(0) Download the journal article template package from journal article template package.

Add the missing .zip to the file (!), open it and put everything in a directory.

Also check that WinEdt is configured to run BibTeX.

Options > Execution Modes > Console Application panel

btx

(1) Create a new directory with the following files from the distribution:

sn-jnl.cls

sn-bibliography.bib

sn-aps.bst (located in the bst sub-directory of the distribution)

sn-mathphys.bst (idem)

and

sn-article-aps.tex (see the code below)

d1

sn-article-aps.tex is a short version of sn-article.tex: just the section Introduction with a single sentence The Introduction section with \cite{bib1} and \cite{bib2}.

For this exercise we will use \documentclass[pdflatex, sn-aps]{sn-jnl} (The American Physical Society (APS) Reference Style)

(2) Test the LaTeX installation.

Open the file with WinEdt and do (a) to (d):

(a) TeX > PDF > PDFLaTeX

Note that the expected References section is missing and it also says The Introduction section with [?] and [?].

b

(b) TeX > BibTeX

In the console will appear

Command Line:   bibtex.exe "sn-article-aps"
Startup Folder: K:\sn-math-test

bibtex: security risk: running with elevated privileges
This is BibTeX, Version 0.99d (MiKTeX 21.3)
The top-level auxiliary file: sn-article-aps.aux
The style file: sn-APS.bst
Database file #1: sn-bibliography.bib

(c) TeX > PDF > PDFLaTeX

The section References appears with the two papers but still The Introduction section with [?] and [?].

c

(d) TeX > PDF > PDFLaTeX

Now the final output appears.

x

If everything went according to plan, you can show that your LaTeX system is working properly.

(3) Testing sn-mathphys.

Now replace the line

\documentclass[pdflatex, sn-aps]{sn-jnl}% American Physical Society (APS) Reference Style in sn-article-aps.tex

with

\documentclass[pdflatex,sn-mathphys]{sn-jnl}% Math and Physical Sciences Reference Style

and save the file as sn-article-math.tex

Open the file with WinEdt and do

(e) TeX > PDF > PDFLaTeX

(f) TeX > BibTeX

This happens

ex

Something is wrong with sn-mathphys.bst.

(TeXstudio will inform in the console, after several seconds,)

Process started: bibtex.exe "sn-article-math"

bibtex: security risk: running with elevated privileges
Error: Command crashed: bibtex.exe "sn-article-math"

Process exited with error(s)

Additional information

By commenting out lines #652 to #654, the error goes away. The output is the same when using the APS style.

But of course the correction of sn-mathphys.bst is something that should be required to Springer Nature.

%        if$            
%
%       v empty$
%         'skip$
%         {v * " " *}

This is the file sn-article-aps.tex to do the testing.

% !TeX TS-program = pdflatex

%% FILE: sn-article-aps.tex <<<<<<<<<

%%======================================================%%
%% to compile with pdflatex/xelatex use pdflatex option %%
%%======================================================%%

%\documentclass[pdflatex,sn-mathphys]{sn-jnl}% Math and Physical Sciences Reference Style

\documentclass[pdflatex, sn-aps]{sn-jnl}% American Physical Society (APS) Reference Style

\jyear{2021}%

%% as per the requirement new theorem styles can be included as shown below
\theoremstyle{thmstyleone}%
\newtheorem{theorem}{Theorem}%  meant for continuous numbers
\newtheorem{proposition}[theorem]{Proposition}% 

\theoremstyle{thmstyletwo}%
\newtheorem{example}{Example}%
\newtheorem{remark}{Remark}%

\theoremstyle{thmstylethree}%
\newtheorem{definition}{Definition}%
\raggedbottom

\begin{document}

\title[Article Title]{Article Title}

\author*[1,2]{\fnm{First} \sur{Author}}\email{[email protected]}

\author[2,3]{\fnm{Second} \sur{Author}}\email{[email protected]}
\equalcont{These authors contributed equally to this work.}

\author[1,2]{\fnm{Third} \sur{Author}}\email{[email protected]}
\equalcont{These authors contributed equally to this work.}

\affil*[1]{\orgdiv{Department}, \orgname{Organization}, \orgaddress{\street{Street}, \city{City}, \postcode{100190}, \state{State}, \country{Country}}}

\affil[2]{\orgdiv{Department}, \orgname{Organization}, \orgaddress{\street{Street}, \city{City}, \postcode{10587}, \state{State}, \country{Country}}}

\affil[3]{\orgdiv{Department}, \orgname{Organization}, \orgaddress{\street{Street}, \city{City}, \postcode{610101}, \state{State}, \country{Country}}}


\abstract{The abstract serves both as a general introduction to the topic and as a brief, non-technical summary of the main results and their implications. Authors are advised to check the author instructions for the journal they are submitting to for word limits and if structural elements like subheadings, citations, or equations are permitted.}

\keywords{keyword1, Keyword2, Keyword3, Keyword4}
\maketitle

\section{Introduction}\label{sec1}

The Introduction section with  \cite{bib1} and \cite{bib2}. % <<<<<<<<<<<<<<<<<<<<<

%%%===========================================================================================%%

\bibliography{sn-bibliography}% common bib file

\end{document}
2
  • So basically there is a folder bst that hides underneath and needs to be brought out. Surprisingly simple, but why would Springer Nature waste everybody's precious time figuring out this tactical problem?
    – kensaii
    Jun 23, 2022 at 15:51
  • I got it to work by using the sn-jnl.cls fix posted by Oluwasegun Ayokunle Somefun and adding the pdflatex option indicated in this answer. But the actual solution is below by ABDUL RAUF where one simply needs to move the appropriate bst file into their working directory.
    – jdods
    Oct 5, 2022 at 23:44
6

I had the same problem when using the template from springnature web. Then I used Spring Nature template from overleaf here and it works even with Mendeley.

2
  • If you are using Overleaf, this is the simplest and working answer. Sep 20, 2022 at 8:06
  • It also gives following error: I found no \bibstyle command---while reading file sn-article.aux
    – alper
    Oct 4, 2023 at 21:02
1

The linked Springer LaTeX template does not use biblatex and Biber. It uses a BibTeX-based bibliography approach.

That means that you cannot compile your document with Biber. You need to compile with BibTeX. The error message " Cannot find 'sn-article.bcf'!" clearly indicates that Biber was run, because only Biber looks for .bcf files, BibTeX doesn't do that.

You should not have to add \usepackage{natbib} to the preamble and any kind of \input{sn-article.bbl} only makes sense after BibTeX ran successfully.

If you configured your editor to always run Biber for you, you may have to follow steps in Biblatex with Biber: Configuring my editor to avoid undefined citations in reverse to allow it to run BibTeX.

1

We need to paste all .bst files into the main directory. Then we need to change the bibliography compiler to BibTeX 8-Bit instead of BibTeX.

In TeXstudio

Options -> Configure TeXstudio

Build -> Default Bibliography Tool

Select BibTeX 8-Bit instead of BibTeX

Hit Ok

Now we are ready to build the pdf

Hit F5 (Build & Run)

Enjoy

2
  • As it’s currently written, your answer is unclear. Please edit to add additional details that will help others understand how this addresses the question asked. You can find more information on how to write good answers in the help center.
    – Community Bot
    Jan 29, 2022 at 16:36
  • Thanks a lot for sharing the details. May 8, 2022 at 22:57

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .