4

Currently I'm able to generate required output file using pdflatex in A4 page size. To reduce printing cost, I'd like to convert this A4 size PDF into A3 page as mentioned in the diagram below. Is there any package which can help to generate an A3 page PDF?

[Note: There can be A4 size PDF file with 1,2,3,4,5 or 6 pages]

enter image description here

Kindly suggest.

egreg
  • 1,121,712
Pawan Mude
  • 2,921

3 Answers3

5

You can do that with the pdfpages package. I'll give a real example of mine used to make an A5 booklet on A4 paper, and explain the details:

I first compiled my main document, say mymaindoc.tex with this first line:

\documentclass[a5paper, 11pt, twoside]{book}

Then I created another document mybooklet.tex, in A4 landscape format, with this code:

\documentclass[a4paper,11pt, twoside]{book}%

\usepackage{pdfpages}

\begin{document}

\includepdf[pages = {1,{},2-23},signature=28,landscape]{mymaindoc.pdf}

\end{document}

The pages key enumerates the first page (title page), an empty page so that the body begins on an odd page, and every page of mymaindoc.pdf from the second one. That makes a total of 25 pages.

The signature key is the smallest multiple of 4 that is ≥ 25.

Bernard
  • 271,350
5

You can do with the package pdfpages:

MWE

\documentclass{article}
\usepackage[landscape,a3paper]{geometry}
\usepackage{pdfpages}
\begin{document}
\includepdf[pages={4,1,2,3},nup=2x2]{test.pdf}
\end{document}

Or even with the graphicx package if you want a custom layout:

MWE

\documentclass[twocolumn]{article}
\usepackage{graphicx}
\usepackage[landscape,a3paper]{geometry}
\geometry{verbose,tmargin=0cm,bmargin=0cm,lmargin=0cm,rmargin=0cm}
\parindent=0pt
\begin{document}
\centering
\includegraphics[page=4,width=.5\paperwidth,height=.49\paperheight,keepaspectratio]{test.pdf}
\includegraphics[page=2,width=.5\paperwidth,height=.49\paperheight,keepaspectratio]{test.pdf}
\newpage
\includegraphics[page=1,width=.5\paperwidth,height=.49\paperheight,keepaspectratio]{test.pdf}
\includegraphics[page=3,width=.5\paperwidth,height=.49\paperheight,keepaspectratio]{test.pdf}
\end{document}

The test.tex file used for obtain test.pdf:

\documentclass{article}
\usepackage{graphicx}
\usepackage{lipsum}
\usepackage[margin=1cm]{geometry}
\begin{document}
\resizebox{\linewidth}{!}{A4-1} \lipsum[1-8]\newpage
\resizebox{\linewidth}{!}{A4-2} \lipsum[1-8]\newpage
\resizebox{\linewidth}{!}{A4-3} \lipsum[1-8]\newpage
\resizebox{\linewidth}{!}{A4-4} \lipsum[1-8]\newpage
\end{document}
Fran
  • 80,769
1

If your workflow already involves non-TeX programs, you may consider the makebook program:

https://github.com/dgoodmaniii/makebook

You'll have to download and use a separate program; but you won't have to create and compile a separate TeX file. Away from my computer right now; but since your target page size is just twice your source page size, something like the following should do it:

makebook -i source.pdf -o target.pdf -t folio

makebook uses pdfpages internally (which is a fantastic package), but automates the drudgery of using it. It does require a bash shell, though.

Disclaimer: I'm the author of makebook, and am therefore biased about its usefulness.

dgoodmaniii
  • 4,270
  • 1
  • 19
  • 36