Table of Contents
PDF Document Resources
Interleave pages of two versions of lecture slides
<2016-01-25>
Anthony teaches by distributing a copy of his lectures slides replete with blanks, for students to bring to class, and then presenting the complete version of the slides during lectures.
For the Spring 2016 semester, he decided to try and get all Socratic by displaying the empty versions first and asking students what they think should go in the blanks before showing them his answers. For this one needs a file that shows the two versions of each slide, one after the other.
pdftk
The pdftk
command line tools for Linux will do this:
https://www.pdflabs.com/blog/how-to-collate-even-odd-scanned-pages/
https://www.pdflabs.com/docs/pdftk-cli-examples/
https://www.pdflabs.com/docs/pdftk-man-page/
[Note: the GUI freeware version for Windows, etc. appears not to do this unless you cough up US$4.]
To interleave two PDF documents page-by-page:
$ pdftk A=PSYC_4074_2015.1.22_L2_Optics\&Eye_HANDOUT.pdf B=PSYC_4074_2015.1.22_L2_Optics\&Eye_FINAL.pdf shuffle A B output test.pdf
To concatenate all PDF files in a directory:
$ pdftk *pdf cat output all.pdf
evince
Can view output from command line thus:
$ evince test.pdf
pdfshuffler
Will need to remove the many redundant pages “by hand,” because many slides have no blanks to fill in.
To do that on Linux, use pdfshuffler
. (Confusing that this software has a name similar to the command described above for pdftk
.)