包标题警告:未知的文档类(或包),将使用标准默认值。如何解决

包标题警告:未知的文档类(或包),将使用标准默认值。如何解决

包标题警告:未知的文档类(或包),将使用标准默认值。请参阅标题包文档以了解解释。 在此处输入图片描述

请问上面的错误是什么,这是我的文档前的代码。我需要将表格的标题放在中间。

%\documentclass[review]{elsarticle}
\documentclass[sn-mathphys]{sn-jnl}
\usepackage[justification=centering]{caption}

\usepackage{lineno}
\usepackage{graphicx}
\usepackage{tabularx}
\usepackage{booktabs}
\usepackage{supertabular}
\usepackage{multirow}
%\usepackage[skip=0.5\baselineskip,skip=0.5\abovecaptionskip]{caption}
\newcolumntype{P}[1]{>{\centering\arraybackslash}p{#1}}

\usepackage{verbatim}
% \usepackage{subfiles}
\hyphenation{presents}
\setlength{\textfloatsep}{3pt}
\date{February 2022}
%%% journal %%%

%%%%%%%%%%%%%%%%%%%%%%%
%% Elsevier bibliography styles
%%%%%%%%%%%%%%%%%%%%%%%
%% To change the style, put a % in front of the second line of the current style and
%% remove the % from the second line of the style you would like to use.
%%%%%%%%%%%%%%%%%%%%%%%

%% Numbered
%\bibliographystyle{model1-num-names}

%% Numbered without titles
%\bibliographystyle{model1a-num-names}

%% Harvard
%\bibliographystyle{model2-names.bst}\biboptions{authoryear}

%% Vancouver numbered
%\usepackage{numcompress}\bibliographystyle{model3-num-names}

%% Vancouver name/year
%\usepackage{numcompress}\bibliographystyle{model4-names}\biboptions{authoryear}

%% APA style
%\bibliographystyle{model5-names}\biboptions{authoryear}

%% AMA style
%\usepackage{numcompress}\bibliographystyle{model6-num-names}

%% 'Elsevier LaTeX' style
%\bibliographystyle{elsarticle-num}
%%%%%%%%%%%%%%%%%%%%%%%
\setlength{\textfloatsep}{3pt}
\setlength{\abovedisplayskip}{3pt} %%% 3pt 

\setlength{\belowdisplayskip}{3pt}
\begin{document}

答案1

正如其他评论中提到的,caption 包不知道文档类sn-jnl。避免警告的一个选项是使用silence包通过将此代码片段放在行上方来隐藏警告\usepackage{caption}

\usepackage{silence}
\WarningFilter{caption}{Unknown document class (or package)}

相关内容