0

Using the MDPI journal stylesheet (http://www.mdpi.com/authors/latex), I encounter a sudden vertical spacing after some equation followed by arbitrary text. Here's my document header, as well as the code of the relevant part and a screenshot. I would really appreciate any feedback on how to solve this. Please apologize for not providing a real minimal example. Unfortunately, the dependency on the MDPI template makes this hard.

Header:

\documentclass[entropy,article,submit,moreauthors,pdftex,12pt,a4paper]{mdpi}
\usepackage[table]{xcolor}
\usepackage{epstopdf}
\usepackage{subcaption}
\usepackage{graphicx}
\usepackage{tikz}
\usepackage[all]{xy}
\usetikzlibrary{arrows,automata,shapes,positioning,decorations.pathreplacing}
\theoremstyle{mdpi}

Text fragment:

\subsection{Experiment: The Impact of Anticipation on Survival}\\
Foo
\begin{equation}
\mathfrak{R}(\#\phi)=\frac{|\{i:X_{i,t}>0 \text{ at }t=(\#\phi \cdot N)\}|}{|\{i:X_{i,0}>0\}|}
\end{equation}
Foo Foo Foo FooFoo FooFoo FooFoo FooFoo FooFoo FooFoo FooFoo FooFoo FooFoo FooFoo FooFoo FooFoo FooFoo FooFoo FooFoo FooFoo FooFoo FooFoo Foo Foo FooFoo FooFoo FooFoo FooFoo FooFoo FooFoo FooFoo FooFoo FooFoo FooFoo FooFoo Foo

Screenshot: Please see the vertical spacing between line number 295 and 396

I'm using pdfTeX 3.1415926-1.40.10-2.2 (TeX Live 2009/Debian) in TeXstudio 2.6.2 (SVN 4110).

Thank you very much!

  • Does this happen with another class too? – user31729 Apr 23 '14 at 14:05
  • Making an MWE is actually quite easy, just merge your two snippets, add the required \Title, \Author etc., and add a document environment around the last of the snippets. – Torbjørn T. May 27 '14 at 9:51
3

You used \\ after the subsection heading to start a new line. Instead, please insert a blank line to start a new paragraph. This will solve your problem. (The way headings are defined in the MDPI class file allows you to use \\ there to start a new line. In other document classes you'd receive an error message when using \\ after a heading.)

One other thing: The MDPI class file defines that line numbers are added (using the lineno package) when the documentclass option "submit" is chosen. A known limitation of the lineno package is that it doesn't work well with math display (see lineno user's manual at http://www.ctan.org/tex-archive/macros/latex/contrib/lineno/). A common problem, which I also see in the screenshot you posted, is that the lines before the equation are not numbered. The easiest way to circumvent this is to insert a blank line before the equation. FYI: Once the manuscript is accepted for publication, the documentclass option "submit" will be changed to "accept". Then, line numbers are no longer displayed, and the blank line before the equation can be deleted.

  • Welcome to TeX.SX! The extra space is not directly after the \\ , would it really be the cause? – Torbjørn T. May 27 '14 at 9:36
  • Just tested, and you are indeed correct. – Torbjørn T. May 27 '14 at 9:49

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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