0

I have the following figures which need to be on 1 page, but it creates a separate page for each figure, I don't know why?

\begin{figure}[!htb]\centering
\includegraphics[width=1\textwidth]{HIV-AIDSIII.pdf}
\setlength{\textfloatsep}{10pt plus 1.0pt minus 2.0pt}
\caption{$p=0.3$, $q=0.4$, $r=0.5$, $\xi_1 =0.001$, $\xi_2 =0.003$  hence $\mathcal{R}_0 \approx 3.204$.}
\end{figure}

\begin{figure}[!htb]\centering \includegraphics[width=1\textwidth]{HIV-AIDSIV.pdf} \setlength{\textfloatsep}{10pt plus 1.0pt minus 2.0pt} \caption{Density plotted against time for HIV-AIDS model with $S\left(0\right)=50$, $I_1\left(0\right)=0.50$, $I_2\left(0\right)=50$, $J\left(0\right)=20$ and $A\left(0\right)=20$.} \end{figure}

Math
  • 765
  • In this case you probably should put both includegraphics in the same figure float and use captionof to give each of them their own caption... – Thruston Dec 02 '21 at 15:52
  • 1
    just delete the central \end{figure} \begin{figure}[!htb]\centering so they are in a single float (note that [htb] omits p so makes the figure floating to the end of document more likely. – David Carlisle Dec 02 '21 at 15:59
  • apart from putting them in one figure the main reason they would not go on a page is that you were preventing them from being placed on a float page with the optional argument. also note \setlength{\textfloatsep}{10pt plus 1.0pt minus 2.0pt} has no effect at all if you set it inside the float, this is a global parameter used in the output routine for making up the page. – David Carlisle Dec 02 '21 at 20:18

0 Answers0