[Tex/LaTex] Math symbol between two images

numberingpositioningsubfloats

Subfloats

I want these left-right-arrows to be higher, at center, as the red ones go, but I have no idea how it can be done.
Here's my code:

\documentclass{article}
\usepackage{geometry}
\usepackage[demo]{graphicx}
\usepackage{subfig}

\begin{document}
\begin{figure}[htb]%
\centering
\subfloat[$f(t)$]{{\includegraphics[width=5cm]{pierw1} }}%
\qquad 
\subfloat{$\Longleftrightarrow$}%
\qquad 
\subfloat[$F(\omega)$]{{\includegraphics[width=5cm]{pierw2} }}%

\subfloat[$F(t)$]{{\includegraphics[width=5cm]{pierw3} }}%
\qquad 
\subfloat{$\Longleftrightarrow$}%
\qquad 
\subfloat[$2 \pi f(-\omega)$]{{\includegraphics[width=5cm]{pierw4} }}%

\caption{2 Figures side by side}%
\label{fig:example}%
\end{figure}
\end{document}

I tried by making it as a subfloat, but I don't know how I can position it.

And second problem – how can I get rid off these (a) (b) etc. while leaving caption only?

Best Answer

Below I set the images using adjustbox's valign=c. This places the vertical anchor (used for alignment) at the centre. Since each image is set with the same (fixed) width, the "subcaptions" are set inside a similar-width \makebox:

enter image description here

\documentclass{article}

\usepackage[export]{adjustbox}

\begin{document}

\begin{figure}
  \centering\small

  % Top images
  \includegraphics[width=5cm, valign=c]{example-image-a}
  \qquad 
  $\Longleftrightarrow$
  \qquad 
  \includegraphics[width=5cm, valign=c]{example-image-b}

  \medskip

  % Top captions
  \makebox[5cm]{$f(t)$}
  \qquad
  \phantom{$\Longleftrightarrow$}
  \qquad
  \makebox[5cm]{$F(\omega)$}

  \bigskip

  % Bottom images
  \includegraphics[width=5cm, valign=c]{example-image-b}
  \qquad 
  $\Longleftrightarrow$
  \qquad 
  \includegraphics[width=5cm, valign=c]{example-image-a}

  \medskip

  % Bottom captions
  \makebox[5cm]{$F(t)$}
  \qquad
  \phantom{$\Longleftrightarrow$}
  \qquad
  \makebox[5cm]{$2 \pi f(-\omega)$}

  \caption{2 figures side by side}%
\end{figure}

\end{document}

Without the need for subfloat numbering, you can just set the entire structure inside a tabular:

\begin{figure}
  \centering\small

  % Top images
  \begin{tabular}{ @{} c @{\qquad} c @{\qquad} c @{} }
    \includegraphics[width=5cm,valign=c]{example-image-a} &
    $\Longleftrightarrow$ &
    \includegraphics[width=5cm,valign=c]{example-image-b} \\
    % Top captions
    \rule{0pt}{\normalbaselineskip}$f(t)$ &&
    $F(\omega)$ \\[\bigskipamount]
    % Bottom images
    \includegraphics[width=5cm, valign=c]{example-image-b} &
    $\Longleftrightarrow$ &
    \includegraphics[width=5cm, valign=c]{example-image-a} \\
    % Top captions
    \rule{0pt}{\normalbaselineskip}$F(t)$ &&
    $2 \pi f(-\omega)$
  \end{tabular}

  \caption{2 figures side by side}%
\end{figure}