0

I am using the following lines to include images to my latex file but it always puts the image at the top of the page irrespective of whether I call this evrironment. I have used \usepackage{graphicx} as from so many online instructions:

\begin{figure}
\begin{center}
\includegraphics[scale = 0.4]{vectorAB.png}
\hspace{0.2in}
\includegraphics[scale = 0.5]{berryAB.png}
\caption{Phase transformation due to magnetic flux in inaccessible region due to either traversal for two quantun states from either of the sides, or by looping around the flux line, even when $\vec{B}=0$}
\end{center}
\end{figure}

What exactly am I missing here?

Torbjørn T.
  • 206,688
  • 1
    \begin{figure}[htbp!] where h for here, t for top, b for bottom, p for page. For example, you can use it as \begin{figure}[h!] to place it where it is first called. – fromthebeeland Jul 26 '21 at 14:02
  • 2
    Unrelated: don't use the center environment in figure: it adds unwanted vertical spacing to the vertical spacing of figure. Use the \centering directive instead. – Bernard Jul 26 '21 at 14:44
  • thank you very much, both the answers were very helpful! – prikarsartam Jul 26 '21 at 16:20
  • @fromthebeeland - Actually, [h!] is no more likely to go where you expect it than [htp] (unless you have more than 3 figures on one page/column). – John Kormylo Jul 26 '21 at 23:37

0 Answers0