Graphics, Figures & TablesFigures

Information and discussion about graphics, figures & tables in LaTeX documents.
Post Reply
Muhammad Tayyab
Posts: 1
Joined: Sun May 18, 2014 1:29 am

Figures

Post by Muhammad Tayyab »

Hello,
Now a days I am writing my Masters thesis, it includes some figure. I am facing the issue if I add some figure after subsection it gives a space between subsection and the figure. How can I get rid of this?
Code is below

Code: Select all

\subsection{Graphical Interpretation  of Mittag-Leffler Function}
\begin{figure}
  \centering
 \includegraphics[width=5in, height= 3.5in]{1parmgraph.eps}\\
  \caption{\large{Graph of $E_{\alpha}(-t^\alpha)$ for
$0<\alpha\leq1$.}}
\includegraphics[width=5in, height= 3.5in]{1parameter2.eps}\\
  \caption{\large{Graph of $E_{\alpha}(-t^\alpha)$ for
$0<\alpha\leq2$.}}
\end{figure}
\begin{figure}[!htbp]
  \centering
\includegraphics[width=5in, height= 3.5in]{2parameter.eps}\\
  \caption{\large{Graph of $E_{\alpha,\beta}(-t^\alpha)$ for
$0<\alpha\leq\beta\leq1$.}}
\end{figure}
Last edited by Stefan Kottwitz on Sun May 18, 2014 12:15 pm, edited 1 time in total.

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

tom
Posts: 73
Joined: Thu Apr 18, 2013 4:02 am

Figures

Post by tom »

Hi Muhammed,

Just use the optional argument [ht] to {figure}. If there is still too much space between the heading and the figure, use a negative \vspace to move the figure up. Also, consider the subfig package for a better alignment of multiple figures.

Code: Select all

\documentclass[a4paper,12pt]{article}
\begin{document}
\section{some section}\clearpage
\subsection{Graphical Interpretation  of Mittag-Leffler Function}
\begin{figure}[ht]\vspace{-20pt}
\centering
\rule{0.5\textwidth}{0.5\textwidth}
\caption{\large{Graph of $E_{\alpha}(-t^\alpha)$ for $0<\alpha\leq1$.}}
\rule{0.5\textwidth}{0.5\textwidth}
\caption{\large{Graph of $E_{\alpha}(-t^\alpha)$ for
$0<\alpha\leq2$.}}
\end{figure}
\begin{figure}[ht]
  \centering
\rule{0.5\textwidth}{0.5\textwidth}
  \caption{\large{Graph of $E_{\alpha,\beta}(-t^\alpha)$ for $0<\alpha\leq\beta\leq1$.}}
\end{figure}
\end{document}
Post Reply