Tenho cerca de meia página de espaço entre meus dois gráficos: quero que eles fiquem mais próximos. Aqui está um MWE:
\documentclass[notitlepage]{report}
\usepackage[left=1in, right=1in, top=1in, bottom=1in]{geometry}
\usepackage{enumitem}
\usepackage{titling}
\usepackage{lipsum}
\usepackage[backend=biber]{biblatex}
\usepackage{graphicx}
\usepackage{placeins}
\usepackage{subcaption}
\begin{document}
\begin{figure}
\centering
\begin{subfigure}{0.5\textwidth}
\centering
\includegraphics[height=2.0in]{linear.png}
\caption{$\delta_{1}$ and $\delta_{2}$ $= 0.3$}
\end{subfigure}%
~
\begin{subfigure}{0.5\textwidth}
\centering
\includegraphics[height=2.0in]{exponential.png}
\caption{$\delta_{1}$ and $\delta_{2}$ $= 0.81$}
\end{subfigure}
\caption{Small $x[0]$}
\addtolength{\textfloatsep}{-0.2in}
\end{figure}
\FloatBarrier
This behavior could be due to $y'[t]$ decreasing in value quickly with large $y[0], \delta_{1}$, and $\delta_{2}$ and $x'[t]$ then increasing in value as the $-\delta_{2}y$ decreases in absolute value while the denominator, $1-\delta_{1}$ is small, causing $x[t]$ to increase faster.
For $x_[0] = .45$, we see similar behavior as we adjust our deltas, but $x[t]$ is monotone decreasing.
\begin{figure}
\centering
\begin{subfigure}{0.5\textwidth}
\centering
\includegraphics[height=2.0in]{LowD.png}
\caption{$\delta_{1}$ and $\delta_{2}$ $= 0.3$}
\end{subfigure}%
~
\begin{subfigure}{0.5\textwidth}
\centering
\includegraphics[height=2.0in]{HigherD.png}
\caption{$\delta_{1}$ and $\delta_{2}$ $= 0.81$}
\setlength{\belowcaptionskip}{-10pt}
\end{subfigure}
\caption{Large $x[0]$}
\end{figure}
\FloatBarrier
\end{document}
Como posso conservar o espaço no meio da minha página?
Responder1
Você pode forçar a segunda figura a ficar próxima do texto se adicionar a !htbp
opção -.
\documentclass[notitlepage]{report}
\usepackage[left=1in, right=1in, top=1in, bottom=1in]{geometry}
\usepackage{enumitem}
\usepackage{titling}
\usepackage{lipsum}
\usepackage[backend=biber]{biblatex}
\usepackage{graphicx}
\usepackage{placeins}
\usepackage{subcaption}
\usepackage{setspace}
\renewcommand{\topfraction}{0.45}
\begin{document}
\begin{figure}
\begin{subfigure}{0.5\textwidth}
\centering
\includegraphics[height=2.0in]{1}
\caption{$\delta_{1}$ and $\delta_{2}$ $= 0.3$}
\end{subfigure}%
~
\begin{subfigure}{0.5\textwidth}
\centering
\includegraphics[height=2.0in]{1}
\caption{$\delta_{1}$ and $\delta_{2}$ $= 0.81$}
\end{subfigure}
\caption{Small $x[0]$}
\addtolength{\textfloatsep}{-0.2in}
\end{figure}
\FloatBarrier
This behavior could be due to $y'[t]$ decreasing in value quickly with large $y[0], \delta_{1}$, and $\delta_{2}$ and $x'[t]$ then increasing in value as the $-\delta_{2}y$ decreases in absolute value while the denominator, $1-\delta_{1}$ is small, causing $x[t]$ to increase faster.
For $x_[0] = .45$, we see similar behavior as we adjust our deltas, but $x[t]$ is monotone decreasing.
\begin{figure}[!htbp]
\centering
\begin{subfigure}{0.5\textwidth}
\centering
\includegraphics[height=2.0in]{1}
\caption{$\delta_{1}$ and $\delta_{2}$ $= 0.3$}
\end{subfigure}%
~
\begin{subfigure}{0.5\textwidth}
\centering
\includegraphics[height=2.0in]{1}
\caption{$\delta_{1}$ and $\delta_{2}$ $= 0.81$}
\setlength{\belowcaptionskip}{-10pt}
\end{subfigure}
\caption{Large $x[0]$}
\end{figure}
\FloatBarrier
\end{document}
Responder2
- você não precisa usar
\FloatBarrier
- to float
figure
add opção para seu posicionamento[ht]
(como também sugerido @Jan ema resposta dele) - reduzir a largura de
subcption
de0.5
para, por exemplo0.4
- para espaço entre subfiguras use
\hfil
- removê
\setlength{\belowcaptionskip}{-10pt}
-lofigure
ou movê-lo para o preâmbulo do documento
\documentclass[notitlepage, demo]{report}% in real document delete option demo
\usepackage[margin=1in]{geometry}
\usepackage{enumitem}
\usepackage{titling}
\usepackage{lipsum}
\usepackage[backend=biber]{biblatex}
\usepackage{graphicx}
\usepackage{placeins}
\usepackage{subcaption}
\begin{document}
\begin{figure}[ht]
\centering
\begin{subfigure}{0.4\textwidth}
\centering
\includegraphics[height=2.0in]{linear.png}
\caption{$\delta_{1}$ and $\delta_{2}$ $= 0.3$}
\end{subfigure}%
\hfil
\begin{subfigure}{0.4\textwidth}
\centering
\includegraphics[height=2.0in]{exponential.png}
\caption{$\delta_{1}$ and $\delta_{2}$ $= 0.81$}
\end{subfigure}
\caption{Small $x[0]$}
\end{figure}
%\FloatBarrier
This behavior could be due to $y'[t]$ decreasing in value quickly with large $y[0], \delta_{1}$, and $\delta_{2}$ and $x'[t]$ then increasing in value as the $-\delta_{2}y$ decreases in absolute value while the denominator, $1-\delta_{1}$ is small, causing $x[t]$ to increase faster.
For $x_[0] = .45$, we see similar behavior as we adjust our deltas, but $x[t]$ is monotone decreasing.
\begin{figure}[ht]
\centering
\begin{subfigure}{0.4\textwidth}
\centering
\includegraphics[height=2.0in]{LowD.png}
\caption{$\delta_{1}$ and $\delta_{2}$ $= 0.3$}
\end{subfigure}
\hfil
\begin{subfigure}{0.4\textwidth}
\centering
\includegraphics[height=2.0in]{HigherD.png}
\caption{$\delta_{1}$ and $\delta_{2}$ $= 0.81$}
\end{subfigure}
\caption{Large $x[0]$}
\end{figure}
%\FloatBarrier
\end{document}