1

I am currently working on a book that collects several finished standalone *.tex articles. Each article has its own title, abstract, sections, etc. So simply using \include will unfortunately not work (e.g. because of multiple \title{} and \abstract{} blocks in the resulting document). The book itself has some additional material such as a preface, a title page and a table of contents. What I would like to achieve is a unified styling across the entire material (e.g. all single column), consistent page numbering and a unified bibliography at the very end, if possible. Simply concatenating the output PDFs is therefore also not an option.

How would you do this? I would like to avoid too much manual intervention in the original *.tex files, if possible.

5
  • The question is too general IMHO. The viability of the possible solutions depends heavily on which assumptions you can make about the original tex files. Do they use the same packages for similar things? Do they follow some macro convention? Do they use the same classes? Are they divided in mainfile+subfiles?
    – Bordaigorl
    Apr 9, 2018 at 16:39
  • I authored all original *.tex files myself, so if absolutely necessary I can make edits to them. They are all single *.tex files (no sub files except for images and *.bib files). They use different document classes (e.g. IEEEtran), but I can unify them to article if that helps. Other than that it should be easy to find a common superset of all used packages. Apr 9, 2018 at 16:50
  • To clarify: I am mainly worried about \title{} and \abstract{} blocks (as they are limited to one per master *.tex file) and \ref{}s which should remain intact in the combined document. Apr 9, 2018 at 16:53
  • 1
    you might get some ideas from one of these questions: tex.stackexchange.com/q/149790/579 Apr 9, 2018 at 16:57
  • combine looks promising indeed. Thank you barbara, I will try to work with that! Apr 9, 2018 at 17:03

1 Answer 1

3

Warning: I'm the author of combine.

I think that you could do it using combine with a little work on your part. For combine everything must be of the same class but from what you said you want to use a bunch of article within a book. A main difference between these is that book provides \chapter while article does not. If you used article throughout while faking an equivalent to \chapter in the few instances you might need it could work with little trouble but beware of book's \frontmatter, \mainmatter and \backmatter commands if you were inclined to use them (perhaps replicate them in the context of the main article if necessary).

2
  • Thanks for your answer. I think that the concept behind the combine class is brilliant. However, I was facing severe technical difficulties (LaTeX error messages are extremely hard to decipher once the parser finds something it doesn't expect...) and opted to simply \include{} the papers after all. I moved the title and authors blocks elsewhere and it looks fine. I use the books \chapter to separate the papers (which oly use \section and lower). It might be primitive, but I'm happy with that for now. Still, thanks for your efforts! Apr 11, 2018 at 18:43
  • @Alan47 Glad your method works for you. Apr 11, 2018 at 18:50

You must log in to answer this question.

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