Take the 2-minute tour ×
Ebooks Stack Exchange is a question and answer site for ebook publishers and readers. It's 100% free, no registration required.

PDFs on archive.org are in high resolution yet has relatively small size. For example, this book. The book's resolution is 500 ppi and 46 Mb size.

What I did was I extract the pages using Adobe Acrobat to png with ppi 500, compressed using PNGGauntlet and take 150 pages out of it and combined them using Acrobat. What I got was a 107 Mb PDF file. This is ridiculous because it's has far lesser pages yet 2.5 times bigger.

How does one make a small pdf like the original one?

share|improve this question
1  
When PDF is used "as it should be", there'll be text and vector graphics. If you see pixel graphics, run. That said, you may have introduced wrong precision, i.e. reserving space for information that was never there (lossless encoding, higher resolution/density, ...) –  Raphael Feb 10 at 12:50

3 Answers 3

up vote 12 down vote accepted

The size of a PDF file is dependent on the content of that file. A PDF file is a bundle of streams, with mostly compressed data.

If you generate a PDF file from e.g. a Word or OpenOffice document, these file tend to be relatively small, especially if you do not include Font information and rely on the system provided fonts or font substitutions. Adding images to your text will make the files much larger.

Since PDF is one of the minority of image file formats that support multiple images, it is often (mis-)used to store multiple images, that e.g. come from a scan. Those scans are often already compressed JPEG images and for those the PDF file works only as a container (no, or little further compression is possible). For those kinds of PDF files, the size can be very large, depending on the pixel size of the images (scan resolution x paper format) and in case of lossy compression (JPEG) the quality of the compression.

If you extract such lossy image files to a lossless format like PNG immediately blows up each of the images often by an order of magnitude. So your results are not surprising.

It would be much better to just extract the individual pages of the file into separate PDF files and recombine only the pages that you need. This can be done without having to decompress the streams containing the imagery e.g. by a program like pdftk. If you pick half of the pages of a book, you can expect to have halve the size document in the end (on average).

share|improve this answer
    
So, what's the best container for scanned documents? –  user74158 Feb 11 at 10:07
1  
@user74158 In my experience DjVu, if you have a good tiff -> djvu process you get output files that are 5-20x smaller than corresponding PDFs generated from those tiff files. –  Anthon Feb 11 at 10:18

They are small, because their content is largely just plain text (including equations).

Since they are directly generated from source files (e.g. LaTeX or Microsoft Word documents), the text is as embedded as a bunch of strings in the .pdf.

If you instead have a document and scan it to .pdf, the pdf just contains one large image per page. This is much less efficient comparing the amount of needed disk space.

share|improve this answer
    
How about PDF which contain scanned coloured documents? –  user74158 Feb 7 at 13:29
1  
@user74158 Sorry I read arxiv.org instead of archive.org. This is why I assumed the documents there are not scanned. They probably use some kind of lossless compression, that you do not. Have you used the PDF optimizer in Adobe Acrobat (and checked for correct settings)? I do not have Acrobat, but using pdftk the filesize of your example reduced to 35MB for all but the first 150 pages. –  Tim Feb 7 at 15:27
    
Awesome! I'm gonna check it out. Thanks Tim. –  user74158 Feb 7 at 15:41

It might be the image format you chose; png files tend to run a fair bit larger than jpg files do. Might be worth trying an export to jpg instead.

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.