How to sort the order of pages so that they can be printed in a folded book?

Edit:
I just noticed, buried in the comments under your question, that the pages will be cut rather than folded. In that case signature size does not matter, \setuparranging[2UP] is the way to go, and you can forget about \setuppageshift because that is only needed when folding. But perhaps my answer will be of interest to somebody else.

How large do you want your signature?

A 'signature' is a number of pages that is folded and bound together; books are generally made up of multiple signatures. Each signature is held together by stitching (or glue), and the signatures are then attached to a ribbon or somesuch and get a cover put around them. I'm no expert, as you no doubt can tell.

The arrangement you were thinking of, 2UP, sets the signature size equal to the number of pages. In your case, that's 100 pages. You'll have 4 pages on each sheet (2 on the front, 2 on the back), so that equals 25 sheets. That is really quite large — try taking 50 pages (25 sheets) from a nearby book and bending them in the middle. (Don't fold them, please. Not even if you can. ;-)) So I propose you use a smaller signature, if that is possible for you.

Four-sheet (sixteen-page) signatures

ConTeXt provides the predefined arranging 2*2*4. It is like 2UP, but for 4-sheet signatures; each block of 16 pages is arranged as follows.

16   1    % sheet 1 recto
2    15   % sheet 1 verso, so 2 will lie under 1
...  ...
10   7    % sheet 4 recto
8    9    % sheet 4 verso, so 8 wil lie under 7

Use it like this:

\setuppapersize[A5][A4, landscape]
\setuparranging[2*2*4]

It is mentioned among the other imposition schemes on page 13-14 of the new manual chapter on page design. Link obtained from the main page of the wiki.

Custom signature sizes

See the Lua code on the last section of the Imposition page. I don't know what signature size is still safe — grab some sheets of paper, and see what still folds nicely.

Offsetting pages because the outermost sheet is wrapped more thickly.

On page 33 that manual chapter mentions the following:

There is culprit in arranging pages. If multiple layers of paper are folded, the outermost paper will require more width because it has to turn around the inner paper layers. This effect occurs as well in the spine folds as also in the head folds. How much width is required depends on the number of folds and the thickness of the paper. In professional book printing this effect is accounted for by displacing the pages depending on their position in horizontal and vertical direction. The result is that there will be a perfect look-through registering of all pages. There are no simple rules to indicate the required amount of displacement. Mostly it is a matter of experience to set up the page shift information.

This is the pageshift code the book then gives. I've looked at how it shifts the pages if you use 2*2*4 arranging (by turning 0.25 / 0.15 / 0.05 mm into 12 / 8 / 4 mm, because I don't like squinting), and at least the directions and relative magnitudes are right. I have no clue whether these are reasonable values for standard printer A4 paper, but I would assume they are.

\definepageshift[Hor][horizontal]
    [0.25mm,  % page 1
    -0.25mm,  % page 2
     0.15mm,  % 3
    -0.15mm,  % 4
     0.05mm,  % 5
    -0.05mm,  % 6
     0mm,     % 7
     0mm,     % 8
     0mm,     % 9
     0mm,     % 10
     0.05mm,  % 11
    -0.05mm,  % 12
     0.15mm,  % 13
    -0.15mm,  % 14
     0.25mm,  % 15
    -0.25mm]  % 16
\setuppageshift[paper][Hor]  % use the list we just defined

It is probably easier to post-process the PDF. TeXLive contains a tool called pdfbook that does this:

pdfbook --batch example.pdf

will create a example-book.pdf with the pages resorted and 2-on-1. In case you create postscript output, there is also a psbook.

Edit: Maybe your pdfbook is too old? Mine produces a perfect Booklet-PDF with out any extra parameters.


You can use pdfpages package with its signature option.

Here is an example where original A5 document (doc-a5.pdf) must contain 100 pages.

\documentclass[a4paper]{book}
\usepackage{pdfpages}
\begin{document}
\includepdf[pages=-,signature=100,landscape,noautoscale]{doc-a5.pdf}
\end{document}