两幅图像之间的数学符号

两幅图像之间的数学符号

子浮点数

我希望这些左右箭头的位置更高,位于中心,就像红色箭头一样,但我不知道该怎么做。这是我的代码:

\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}

我尝试将其设为子浮点数,但我不知道如何定位它。

第二个问题——我怎样才能去掉这些(a)(b)等,只留下标题?

答案1

下面我使用adjustboxvalign=c。这会将v垂直锚点(用于alignment)放置在c入口处。由于每幅图像都设置为相同(固定)宽度,因此“子标题”设置在类似宽度的 内\makebox

在此处输入图片描述

\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}

无需子浮点编号,您只需将整个结构设置在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}

答案2

在此处输入图片描述

它是通过使用包\usepackage[export]{adjustbox}(将图像的基线移动到图像的垂直中心)并设置subfig选项来实现的\captionsetup[subfloat]{labelformat=empty},从而消除subcaption编号:

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

\begin{document}
\begin{figure}[htb]%
\captionsetup[subfloat]{labelformat=empty}

\centering
\subfloat[$f(t)$]{{\includegraphics[width=5cm,valign=m]{pierw1} }}%
\qquad
\subfloat{$\Longleftrightarrow$}%
\qquad
\subfloat[$F(\omega)$]{{\includegraphics[width=5cm,valign=m]{pierw2} }}%

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

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

相关内容