43

This is my code.

\documentclass{article}
\usepackage{amssymb,amsmath,amsthm,enumitem}

\begin{document}
How can I decrease vertical space between text above and below \$\$ \ldots \$\$ ?
$$x^{2}+y^{2} = 1$$
How can I decrease vertical space between text above and below \$\$ \ldots \$\$ ?

And how can I decrease vertical space between text above and below align command ?
\begin{align*}
abdefg &= 1\\
     &\leq 2.
\end{align*}
How can I decrease vertical space between text above and below align command ?
\end{document}

And it shows as this picture enter image description here

Everyone know how to fix it? Please help.

Mico
  • 506,678
Mr.Lilly
  • 533
  • It is the default space. Maybe it is too big because you don't have material enough on the page to fill. Insert a lot of text (using \lipsum[1] from the lipsum package, for example) and see if the vertical space is smaller. – Sigur Jan 26 '15 at 11:36
  • 1
    Also, don't use double dollar. Use \[ \] instead. – Sigur Jan 26 '15 at 11:37
  • @sigur It does not different. – Mr.Lilly Jan 26 '15 at 11:40
  • So, don't worry. Just let TeX decide to you. When you finish your document you can try some adjustment. – Sigur Jan 26 '15 at 11:45

1 Answers1

58

The spacing above equations is determined by the length \abovedisplayskip while the spacing below them is determined by the length \belowdisplayskip, so, modify them to achieve what you want, for example,

\setlength{\abovedisplayskip}{3pt}
\setlength{\belowdisplayskip}{3pt}

MWE

\documentclass{article}
\usepackage{amssymb,amsmath,amsthm,enumitem}

\begin{document}

\setlength{\abovedisplayskip}{3pt}
\setlength{\belowdisplayskip}{3pt}

How can I decrease vertical space between text above and below \$\$ \ldots \$\$?
\[x^{2}+y^{2} = 1\]
How can I decrease vertical space between text above and below \$\$ \ldots \$\$?

And how can I decrease vertical space between text above and below align command?
\begin{align*}
abdefg &= 1\\
     &\leq 2.
\end{align*}
How can I decrease vertical space between text above and below align command?
\end{document} 

enter image description here

karlkoeller
  • 124,410