I'm looking for a convenient way to integrate standalone chapters in a main.tex
(scrbook
) file. More specifically, they will be already published papers within a thesis framework text and should
- each have their own counters for figures, tables, equations
- each have their own references with the references not showing up in the references of
main.tex
(preferablynatbib
) - inherit everthing else like formatting, header, footer, packages from
main.tex
- preferably compile with
main.tex
I have looked at the standalone
and subfiles
packages, together with chapterbib
or bibunits
and with resetting the counters before each paper. Although I think I could somehow get this to work, this seems like an ugly workaround for something that has probably been encountered by someone else earlier.
Best Answer
Personally I think this comes down to file and document organization. Few comments based on the work flow I evolved into using:
\begin{document} \input{../Files/ActualStandAloneContent} \end{document}
to direct the compiler to my chapter content.main.tex
main_Ch1.tex
main_Ch2.tex
etc... and when I run myxelatexCompile.bat
I will getmain.pdf
main_Ch1.pdf
main_Ch2.pdf
which keeps everything current.bibunits
) in the main files by using a syntax like\begin{bibunit} \input{File} \putbib \end{bibunit}
or you include this process in your standalone chapter, it doesn't make much difference. Personally, I keep this stuff in the main file as I never know when I am going to subdivide stand-alone files.\input{../Files/FrontMatter.tex}
which you would always include in your main file to save repetition.