# Why do pdflatex and latex LNCS outputs look different?

I've found that using embedded postscript (eps) with the `pdflatex` command, as opposed to the `latex` command, may require more effort; and potentially insecure write18 permissions with cygwin. No problem, I thought, I can just use `latex`. However, the two give different results.

I made a test by unzipping the Springer LNCS file llncs2e.zip. In the first case I used:

``````pdflatex llncs.dem && pdflatex llncs.dem
``````

In the second case I used:

``````latex llncs.dem && latex llncs.dem && dvipdf llncs.dvi
``````

In the second case I find that the bottom margin appears very large, while the top margin is too small; and don't think this looks acceptable. I'm not looking for a way to fix the margins, but would like to know where I went wrong in assuming that both routes would produce identical output.

-
I can't reproduce the problem. Both files look identical. You should provide some more information on the OS and LateX installation you use. Maybe you could post a picture to show what happens in your case. –  Carsten Thiel Jun 18 '11 at 14:29

The `llncs` class should work just like the standard `article` class. You can specify the `a4paper` option to get A4 paper size, or omit it to get the letter paper size.

With pdflatex, this is all that you need.

With latex + dvips + ps2pdf, you will also need to specify the correct paper size on the dvips command line, for example, `dvips -t a4`. The `dvipdf` tool seems to be similar.

Note that dvips might or might not accidentally produce the correct paper size, depending on the configuration of your system. It might be best not to count on it; always specify the paper size on the command line, or you will have surprises when you try to compile it on another computer.

Finally, the LNCS books of course do not have the physical paper size of A4 or letter. If you want to produce a PDF file with a paper size that matches the final printed book, here you can find a very useful trick: use pdflatex and specify

``````\pdfpagesattr{/CropBox [92 112 523 778]}
``````
-
So, the output of pdflatex uses a default papersize? And dvipdf will probably have a switch to set that. Is that what you mean? –  user4417 Jun 20 '11 at 13:30
@user4417: AFAIK: pdflatex should use the paper size selected in the Latex source code, that is, A4 for `a4paper` and letter otherwise. dvipdf will ignore the Latex source code; it will use a default setting that depends on your system configuration. If you want to use dvipdf, use the right command line switch to override the default. –  Jukka Suomela Jun 20 '11 at 13:39
I don't know where the paper size is selected in llncs.dem. I also can't find any command line switches for dvipdf which will take a4paper. I think I will just move to use pdflatex, and use epstopdf in my makefiles. –  user4417 Jun 20 '11 at 13:59
IIRC, `llncs` delegates the paper size selection to the `article` class, which uses letter by default and A4 with the `a4paper` option. You can use `dvips` + `ps2pdf` instead of `dvipdf`, so that you can select the paper size, or you can edit the `dvipdf` script (it is a short shell script that invokes `dvips`). –  Jukka Suomela Jun 20 '11 at 14:11

As far as I can see neither the class nor set the (pdf) paper size. Perhaps you get letterpaper in one case. Apart from this: all the different routes to pdf (pdflatex, xelatex, lualatex, latex+dvips+ps2pdf, latex+dvipdfmx, latex +...) can give different results.

-