错误的内容生成(一个章节位于另一个章节内)

错误的内容生成(一个章节位于另一个章节内)

我对 TeX 还比较陌生。

我正在使用特定的 latex 模板来撰写论文。我的内容在 TexStudio 中看起来不错。但是,在 PDF 文件内容中,第 4 章出现在第 3 章内(因为它是第 3 章的子节)。我的文档中还有多个附录(A、B、C),它们在 PDF 文件内容中也显示错误,请参阅所附的屏幕截图。

在此处输入图片描述

这是我的 .tex 文件的结构:

\documentclass[12pt]{nuthesis}  % The nuthesis class is based on 
% amsbook.cls.
\usepackage{hyperref}
\usepackage{graphicx}
\usepackage{color}
\usepackage{colortbl}
\usepackage{cancel}
\author{Mikhail Genkin}

\title{---}
\bibliographystyle{unsrt}
\begin{document}
\frontmatter        % Preliminary pages start here.

\maketitle      % Produces the title page.

\copyrightpage      % Creates the copyright page.


\abstract   
 la-la-la
\acknowledgements
 la-la-la

\clearpage\phantomsection % needed for the hyperlinks to work correctly
\tableofcontents    % Table of Contents will be automatically
% generated and placed here.

\clearpage\phantomsection % needed for the hyperlinks to work correctly
\listoftables       % List of Tables and List of Figures will be placed

\clearpage\phantomsection % needed for the hyperlinks to work correctly
\listoffigures      % here, if applicable (optional).



\mainmatter             % Actual text starts here.

%%%%%%%%%%%%%%%%%%%%%%%%%%%
% Actual text starts here %
%%%%%%%%%%%%%%%%%%%%%%%%%%%

% If there is an introduction it must be the first chapter

\chapter{Introduction}  % The firs

\chapter{Chapter1},
...
...

\begin{singlespace}
 \renewcommand\refname{\begin{centering}References\end{centering}}
 \bibliography{ref}
\bibliographystyle{unsrt}   
\end{singlespace}

\appendices 
\chapter{...}
....

这是.toc 文件:

\contentsline {chapter}{\tocchapter {Chapter}{}{ABSTRACT}}{3}{chapter*.1}
\contentsline {chapter}{\tocchapter {Chapter}{}{Acknowledgments}}{5}    {chapter*.2}
\contentsline {chapter}{\tocchapter {Chapter}{}{List of Tables}}{9}{section*.4}
\contentsline {chapter}{\tocchapter {Chapter}{}{List of Figures}}{10}{section*.5}
\contentsline {chapter}{\tocchapter {Chapter}{1}{Introduction}}{20}{chapter.1}
\contentsline {section}{\tocsection {}{1.1}{Active systems modeling}}{22}{section.1.1}
\contentsline {subsection}{\tocsubsection {}{1.1.1}{Direct particle simulations}}{22}{subsection.1.1.1}
\contentsline {subsection}{\tocsubsection {}{1.1.2}{Continuous models}}{23}{subsection.1.1.2}
\contentsline {subsection}{\tocsubsection {}{1.1.3}{Swimming suspensions: hydrodynamics}}{24}{subsection.1.1.3}
\contentsline {subsection}{\tocsubsection {}{1.1.4}{Kinetic approach}}{26}{subsection.1.1.4}
\contentsline {subsection}{\tocsubsection {}{1.1.5}{Reduction of kinetic models}}{28}{subsection.1.1.5}
\contentsline {section}{\tocsection {}{1.2}{Liquid crystals}}{29}{section.1.2}
\contentsline {subsection}{\tocsubsection {}{1.2.1}{Liquid crystal structure}}{30}{subsection.1.2.1}
\contentsline {subsection}{\tocsubsection {}{1.2.2}{Mesomorphic phases}}{31}{subsection.1.2.2}
\contentsline {subsection}{\tocsubsection {}{1.2.3}{Director description}}{33}{subsection.1.2.3}
\contentsline {subsection}{\tocsubsection {}{1.2.4}{Order parameter and Landau-de Gennes theory}}{34}{subsection.1.2.4}
\contentsline {subsection}{\tocsubsection {}{1.2.5}{Elasticity of nematic liquid crystal}}{36}{subsection.1.2.5}
\contentsline {subsection}{\tocsubsection {}{1.2.6}{Anisotropic response to external fields}}{38}{subsection.1.2.6}
\contentsline {section}{\tocsection {}{1.3}{Living nematics}}{39}{section.1.3}
\contentsline {subsection}{\tocsubsection {}{1.3.1}{Systems with nematic interactions}}{40}{subsection.1.3.1}
\contentsline {subsection}{\tocsubsection {}{1.3.2}{Bacteria suspensions in nematic liquid crystal}}{41}{subsection.1.3.2}
\contentsline {chapter}{\tocchapter {Chapter}{2}{A new computational model for living nematic}}{45}{chapter.2}
\contentsline {section}{\tocsection {}{2.1}{Liquid crystal description}}{45}{section.2.1}
\contentsline {subsection}{\tocsubsection {}{2.1.1}{Harvard model}}{46}{subsection.2.1.1}
\contentsline {subsection}{\tocsubsection {}{2.1.2}{Ericksen-Leslie model}}{48}{subsection.2.1.2}
\contentsline {subsection}{\tocsubsection {}{2.1.3}{Edwards-Beris approach}}{50}{subsection.2.1.3}
\contentsline {section}{\tocsection {}{2.2}{Model details}}{53}{section.2.2}
\contentsline {subsection}{\tocsubsection {}{2.2.1}{The system of interest and     model assumptions}}{53}{subsection.2.2.1}
\contentsline {subsection}{\tocsubsection {}{2.2.2}{Additional model details}}{55}{subsection.2.2.2}
\contentsline {subsubsection}{\tocsubsubsection {}{2.2.2.1}{Small Reynolds number approximation}}{55}{subsubsection.2.2.2.1}
\contentsline {subsubsection}{\tocsubsubsection {}{2.2.2.2}{Wall anchoring}}{56}{subsubsection.2.2.2.2}
\contentsline {subsubsection}{\tocsubsubsection {}{2.2.2.3}{Active stress}}{57}{subsubsection.2.2.2.3}
\contentsline {subsection}{\tocsubsection {}{2.2.3}{Equations for bacteria dynamics}}{58}{subsection.2.2.3}
\contentsline {subsubsection}{\tocsubsubsection {}{2.2.3.1}{Bacteria orientation}}{58}{subsubsection.2.2.3.1}
\contentsline {subsubsection}{\tocsubsubsection {}{2.2.3.2}{Bacteria concentration}}{60}{subsubsection.2.2.3.2}
\contentsline {section}{\tocsection {}{2.3}{Numerical integration}}{61}{section.2.3}
\contentsline {subsection}{\tocsubsection {}{2.3.1}{Scaling of the model parameters}}{63}{subsection.2.3.1}
\contentsline {subsection}{\tocsubsection {}{2.3.2}{Reduction to a set of scalar equations}}{63}{subsection.2.3.2}
\contentsline {subsection}{\tocsubsection {}{2.3.3}{Numerical Scheme}}{67}{subsection.2.3.3}
\contentsline {subsection}{\tocsubsection {}{2.3.4}{Additional implementation details}}{69}{subsection.2.3.4}
\contentsline {section}{\tocsection {}{2.4}{Materials and methods}}{70}{section.2.4}
\contentsline {subsection}{\tocsubsection {}{2.4.1}{Numerical implementation.}}{70}{subsection.2.4.1}
\contentsline {subsection}{\tocsubsection {}{2.4.2}{ Defect detection and tracking}}{71}{subsection.2.4.2}
\contentsline {subsection}{\tocsubsection {}{2.4.3}{Experimental details}}{72}{subsection.2.4.3}
\contentsline {section}{\tocsection {}{2.5}{The results of numerical integration}}{74}{section.2.5}
\contentsline {subsection}{\tocsubsection {}{2.5.1}{Simulation results}}{74}{subsection.2.5.1}
\contentsline {subsection}{\tocsubsection {}{2.5.2}{Statistics of topological defects}}{75}{subsection.2.5.2}
\contentsline {subsection}{\tocsubsection {}{2.5.3}{Experimental verification.}}{76}{subsection.2.5.3}
\contentsline {section}{\tocsection {}{2.6}{Linear stability analysis}}{78}    {section.2.6}
\contentsline {subsection}{\tocsubsection {}{2.6.1}{The details of stability analysis}}{78}{subsection.2.6.1}
\contentsline {subsection}{\tocsubsection {}{2.6.2}{The results of stability analysis}}{80}{subsection.2.6.2}
\contentsline {section}{\tocsection {}{2.7}{Discussion and solutions of the simplified model}}{82}{section.2.7}
\contentsline {subsection}{\tocsubsection {}{2.7.1}{Heuristic explanation of the accumulation and depletion phenomena.}}{82}{subsection.2.7.1}
\contentsline {subsection}{\tocsubsection {}{2.7.2}{Frozen nematic field}}{82}{subsection.2.7.2}
\contentsline {subsection}{\tocsubsection {}{2.7.3}{Asymptotic expansion}}{84}{subsection.2.7.3}
\contentsline {section}{\tocsection {}{2.8}{Conclusion}}{87}{section.2.8}
\contentsline {chapter}{\tocchapter {Chapter}{3}{Living nematics near the     isotropic-nematic phase transition}}{97}{chapter.3}
\contentsline {section}{\tocsection {}{3.1}{Preliminaries}}{98}{section.3.1}
\contentsline {subsection}{\tocsubsection {}{3.1.1}{Biphasic state of a nematic LC}}{98}{subsection.3.1.1}
\contentsline {subsection}{\tocsubsection {}{3.1.2}{Mathematical description}}{99}{subsection.3.1.2}
\contentsline {section}{\tocsection {}{3.2}{Model details}}{100}{section.3.2}
\contentsline {subsection}{\tocsubsection {}{3.2.1}{Additional model equation}}{100}{subsection.3.2.1}
\contentsline {subsection}{\tocsubsection {}{3.2.2}{Tactoid introduction}}{102}{subsection.3.2.2}
\contentsline {subsection}{\tocsubsection {}{3.2.3}{I-N anchoring}}{104}{subsection.3.2.3}
\contentsline {section}{\tocsection {}{3.3}{Numerical integration}}{105}{section.3.3}
\contentsline {section}{\tocsection {}{3.4}{Material and Methods}}{107}{section.3.4}
\contentsline {subsection}{\tocsubsection {}{3.4.1}{Topological charge of an arbitrary closed region}}{107}{subsection.3.4.1}
\contentsline {subsection}{\tocsubsection {}{3.4.2}{Experimental details}}{108}{subsection.3.4.2}
\contentsline {section}{\tocsection {}{3.5}{Results}}{109}{section.3.5}
\contentsline {subsection}{\tocsubsection {}{3.5.1}{Isotropic tactoids in nematic phase}}{109}{subsection.3.5.1}
\contentsline {subsection}{\tocsubsection {}{3.5.2}{Nematic tactoids in isotropic phase}}{111}{subsection.3.5.2}
\contentsline {subsection}{\tocsubsection {}{3.5.3}{Experimental verification}}{113}{subsection.3.5.3}
\contentsline {section}{\tocsection {}{3.6}{Discussion}}{113}{section.3.6}
\contentsline {subsection}{\tocsubsection {}{3.6.1}{Fokker-Plank model}}{114}{subsection.3.6.1}
\contentsline {subsection}{\tocsubsection {}{3.6.2}{Tactoid's charge density}}{120}{subsection.3.6.2}
\contentsline {section}{\tocsection {}{3.7}{Relation to Rapini-Papoular approach}}{121}{section.3.7}
\contentsline {section}{\tocsection {}{3.8}{Conclusion}}{125}{section.3.8}
\contentsline {chapter}{\tocchapter {Chapter}{4}{Quantized bending excitation of a living nematic in cylindrical confinement}}{137}{chapter.4}
\contentsline {section}{\tocsection {}{4.1}{Introduction}}{137}{section.4.1}
\contentsline {section}{\tocsection {}{4.2}{Experimental setup and data processing}}{138}{section.4.2}
\contentsline {section}{\tocsection {}{4.3}{Materials and Methods}}{141}{section.4.3}
\contentsline {subsection}{\tocsubsection {}{4.3.1}{Experimental details}}{141}{subsection.4.3.1}
\contentsline {subsubsection}{\tocsubsubsection {}{4.3.1.1}{Cell manufacturing}}{141}{subsubsection.4.3.1.1}
\contentsline {subsubsection}{\tocsubsubsection {}{4.3.1.2}{Living nematics preparation}}{144}{subsubsection.4.3.1.2}
\contentsline {subsubsection}{\tocsubsubsection {}{4.3.1.3}{Experimental setup}}{145}{subsubsection.4.3.1.3}
\contentsline {subsection}{\tocsubsection {}{4.3.2}{Bacteria tracking algorithm}}{146}{subsection.4.3.2}
\contentsline {section}{\tocsection {}{4.4}{Results and discussion}}{147}{section.4.4}
\contentsline {section}{\tocsection {}{4.5}{Conclusion}}{150}{section.4.5}
\contentsline {chapter}{\tocchapter {Chapter}{}{References}}{152}{chapter*.9}
\contentsline {chapter}{\tocappendix {Appendix}{A}{The relationship between different models of nematic LC}}{161}{chapter.1}
\contentsline {chapter}{\tocappendix {Appendix}{B}{Multi-constant elastic energy}}{168}{chapter.2}
\contentsline {chapter}{\tocappendix {Appendix}{C}{Depth-averaging}}{170}{chapter.3}
\contentsline {section}{\tocsection {}{C.1}{Isotropic case}}{170}{section.3.1}
\contentsline {section}{\tocsection {}{C.2}{Anisotropic case}}{173}{section.3.2}

如果还有其他需要附加的内容,请告诉我。我对简单的解决方案感兴趣 :)

谢谢,米哈伊尔

编辑:我仔细检查了我的代码。相关部分:

\chapter{Chapter 3}
...different sections, subsections, subsubsections, etc...
\section{Conclusion}
   .... some text...
\chapter{Chapter 4}
....

我不知道为什么内容生成不正确。我也尝试了替代方法:为每个章节使用单独的 .tex 文件,并在主文件中将其与命令合并\include{chap1}。问题并没有消失。

该问题是否与以下警告有关?

destination with the same identifier (name{section.3.1}) has been already 
used, duplicate ignored<to be read again> \relax l.2633 \section{Isotropic 
case} pdfTeX warning (ext4): destination with the same

答案1

我找到了一个答案(但不明白它为什么有效)。

问题出在附录上。模板中的相关代码片段:

\appendix       % Appendix begins here (optional).

%\appendices            % If more than one appendix chapters,
% use appendices instead of appendix

在我的文档中,附录中有三章,因此,根据注释,我将其注释掉\appendix并使用\appendices。一分钟前,我尝试使用这两个命令:

 \appendix
 \appendices

效果很好!修复后,我的内容可以正常生成了!

相关内容