Graphics, Figures & TablesGetting rid of a large space

Information and discussion about graphics, figures & tables in LaTeX documents.
Post Reply
kwokowok
Posts: 3
Joined: Tue Jun 01, 2021 6:40 am

Getting rid of a large space

Post by kwokowok »

Hello,
I have a large space when i compile a document with the following code and I'm not sure why
\begin{document}
\raggedright
\begin{flushleft}
What would happen as $x$ approaches $3$? We can figure this out by applying a limit.
\end{flushleft}
\begin{center}
\[ \lim_{x\to 3} g(x) \]
\enddocument

Recommended reading 2024:

LaTeXguide.org • LaTeX-Cookbook.net • TikZ.org

NEW: TikZ book now 40% off at Amazon.com for a short time.

And: Currently, Packt sells ebooks for $4.99 each if you buy 5 of their over 1000 ebooks. If you choose only a single one, $9.99. How about combining 3 LaTeX books with Python, gnuplot, mathplotlib, Matlab, ChatGPT or other AI books? Epub and PDF. Bundle (3 books, add more for higher discount): https://packt.link/MDH5p

Ijon Tichy
Posts: 640
Joined: Mon Dec 24, 2018 10:12 am

Getting rid of a large space

Post by Ijon Tichy »

There are several mistakes in the code, e.g., not ending the center environment, using nonsense sequences of commands and environment etc.

If I delete all the nonsense code and make a Infominimal working example from the code snippet:

Code: Select all

\documentclass{article}
\begin{document}
What would happen as $x$ approaches $3$? We can figure this out by applying a limit.
\[ \lim_{x\to 3} g(x) \]
\end{document}
I do not see any problem with the code. So maybe you should either clean up your code or show us a real Infominimal working example. And please mark code correctly as code using the Code button instead of the LaTeX button. The LaTeX button is for inline code only, but not for block code.
Sorry, but I can no longer participate here as the administrator is trampling on my wishes on one of his other platforms. :cry:
Post Reply