# Order of figure and figure* - figure* either goes to next page or order reversed

I have a two-column document. Figure 1 I would like in-line with the text followed by a figure* on the bottom of that same page. When I put the two figures in order and bunch them as close as possible (below each other), the figure* gets pushed to the bottom of the NEXT page. But if I move the figure* higher in the document I get the right placement but the wrong ordering of the captions. Any ideas to fix?

\documentclass{vgtc}
\usepackage{float}

Figure \ref{fig:1} displays .....

\begin{figure}[H]
\centering
\includegraphics[width=0.6\columnwidth]{Figure1.eps}
\caption{\label{fig:1} View.}
\end{figure}

\begin{figure*}[bh]
\centering
\includegraphics[width=\textwidth]{Figure2.eps}
\caption{\label{fig:2} Use case.}
\end{figure*}

• Might work, I've embedded the \minipage in the full-width figure and added a hefty \enlargethispage{-50\baselineskip}. But then I got text flowing behind the figure and a \newpage or \clearpage didn't seem to do the trick (messing up the following column on the next page). Is what I'm trying to do just beyond latex capabilities? – Shawn Jul 11 '19 at 23:15
• {-50\baselinekip} sounds too hefty. At roughly 6 lines/inch (for 10pt type), that's more than 8 inches, in which case the figure should probably occupy a page by itself. The point is, the figure ((figure}[b], not {figure*}) has to be set in the first column, and the gap put at the bottom of the second column. Exactly where the code for the figure comes in the input file is critical; I have found it easiest to shift around when the figure input (if it's long) is in a separate file. But I'm glad you got something to work. – barbara beeton Jul 12 '19 at 0:02
• by default figure* does not support either b or h position so your \begin{figure*}[bh]  would not allow it to be placed anywhere. If the vtgc class you are using is using an extended float algorithm you should link to it.... That said your real issue is using [H] which makes the first float a non-gloat so allowing figures to get out of order. – David Carlisle Jul 12 '19 at 9:23

## 2 Answers

I was able to solve this problem by manipulating the counter. I embedded \setcounter{figure}{#} into the figure and figure*. The count reordered the figure numbering and preserves the placement.

You can also do it with a savebox, but fooling with the figure counter is probably easier.

\documentclass[twocolumn]{article}% couldn't find vgtc.cls
\usepackage{dblfloatfix}% allows [b] for figure*
\usepackage{caption}% for \captionof{figure}
\usepackage{graphicx}
\usepackage{lipsum}% MWE only

\newsavebox{\tempbox}

\begin{document}
\lipsum[1]
%create both figures (more or less) one page early
\savebox{\tempbox}{\begin{minipage}{\columnwidth}
\centering
\includegraphics[width=0.6\columnwidth]{example-image}% no figure1.eps
\captionof{figure}{\label{fig:1} View.}
\end{minipage}}%

\begin{figure*}[b]% no [h] allowed
\centering
\includegraphics[width=\textwidth, height=0.1\textheight]{example-image}% no figure2.eps
\caption{\label{fig:2} Use case.}
\end{figure*}

\lipsum[2-10]

Figure \ref{fig:1} displays .....

\begin{figure}[bh]
\box\tempbox
\end{figure}

\lipsum[11-16]

\end{document}