# How to decrease space height (margin) between equations

I want to decrease spaces(margin) height before and after equations because I found big space when text end and display formula appears or between equations each in separate line.

Also I want to do the same between caption text and table there is also big space.

All of this in elsarticle class.

-
Could you please export a small example LyX document to LaTeX and post this as part of your question? Even include the current output that you don't like. There are ways of changing these lengths, but it would be clear what you're after with some visual aid. –  Werner Sep 11 '12 at 19:17

You can try to put the following after \begin{document}:

\abovedisplayskip=0pt
\abovedisplayshortskip=0pt
\belowdisplayskip=0pt
\belowdisplayshortskip=0pt


The "short" skips correspond to equations after a short line.

For the captions:

\abovecaptionskip=0pt
\belowcaptionskip=0pt

-
thanks it works –  mero Sep 11 '12 at 20:54

Try using the following to reduce the spacing between equation display and the rest of the text.

\AtBeginDocument{\setlength\abovedisplayskip{4pt}}
\AtBeginDocument{\setlength\belowdisplayskip{4pt}}

-
thank you for help –  mero Sep 11 '12 at 20:57
{"extraction_info": {"found_math": true, "script_math_tex": 0, "script_math_asciimath": 0, "math_annotations": 0, "math_alttext": 0, "mathml": 0, "mathjax_tag": 0, "mathjax_inline_tex": 0, "mathjax_display_tex": 0, "mathjax_asciimath": 1, "img_math": 0, "codecogs_latex": 0, "wp_latex": 0, "mimetex.cgi": 0, "/images/math/codecogs": 0, "mathtex.cgi": 0, "katex": 0, "math-container": 0, "wp-katex-eq": 0, "align": 0, "equation": 0, "x-ck12": 0, "texerror": 0, "math_score": 0.8065328001976013, "perplexity": 1765.956714922843}, "config": {"markdown_headings": true, "markdown_code": true, "boilerplate_config": {"ratio_threshold": 0.18, "absolute_threshold": 10, "end_threshold": 15, "enable": true}, "remove_buttons": true, "remove_image_figures": true, "remove_link_clusters": true, "table_config": {"min_rows": 2, "min_cols": 3, "format": "plain"}, "remove_chinese": true, "remove_edit_buttons": true, "extract_latex": true}, "warc_path": "s3://commoncrawl/crawl-data/CC-MAIN-2015-32/segments/1438042986625.58/warc/CC-MAIN-20150728002306-00055-ip-10-236-191-2.ec2.internal.warc.gz"}