将最后一个子图与左侧对齐

将最后一个子图与左侧对齐

我有 5 张图片,想将它们对齐,使三张图片在左侧,两张图片在右侧。我试过这样

\begin{figure}
\centering
\begin{subfigure}[h]{.48\textwidth}
\centering
\includegraphics[width=0.9\textwidth]{pictures/deltaphi_09_21.png}
\caption{Measurement 1: 2:1 CO$_2$-Argon.}
\label{fig:delta phi 1}
\end{subfigure}
\begin{subfigure}[h]{.48\textwidth}
\centering
\includegraphics[width=0.9\textwidth]{pictures/deltaphi_10_11.png}
\caption{Measurement 2: 1:1 CO$_2$-Argon.}
\label{fig:delta phi 2}
\end{subfigure}
\\
\begin{subfigure}[h]{.48\textwidth}
\centering
\includegraphics[width=0.9\textwidth]{pictures/deltaphi_08_21.png}
\caption{Measurement 3: 2:1 CO$_2$-Argon.}
\label{fig:delta phi 3}
\end{subfigure}
\begin{subfigure}[h]{.48\textwidth}
\centering
\includegraphics[width=0.9\textwidth]{pictures/deltaphi_08_11.png}
\caption{Measurement 4: 1:1 CO$_2$-Argon.}
\label{fig:delta phi 4}
\end{subfigure}
\\
\begin{subfigure}[h]{.48\textwidth}
\includegraphics[width=0.9\textwidth, left]{pictures/deltaphi_11_21.png}
\caption{Measurement 5: 2:1 CO$_2$-Argon.}
\label{fig:delta phi 5}
\end{subfigure}
\caption{Phase shift of the different plasma measurements over their incident power.}
\label{fig:delta phi over P} 
\end{figure}

我的问题是最后一张图片仍然位于中心,但我希望它正好位于左边两张图片的下方。

答案1

我会删除所有\centering指令,将各个图形的宽度设置为1\textwidth而不是,在相邻环境之间0.9\textwidth插入指令,并在子图行之间发出指令。此外,为了更好的措施,请考虑加载 LaTeX 化学包,例如\hfillsubfigure\medskip化学工程,并将 的所有实例替换CO$_2$\ce{CO2}。 (我相信“ce”是“化学表达式”的缩写。)

在此处输入图片描述

\documentclass{article} % or some other suitable document class
\usepackage[demo]{graphicx} % remove 'demo' option in real document
\usepackage{subcaption} % for subfigure environment
\usepackage{mhchem}     % for \ce macro
\begin{document}

\begin{figure}
\captionsetup[subfigure]{skip=0.333\baselineskip} % place captions closer to graphs

\begin{subfigure}{.48\textwidth}
\includegraphics[width=1\textwidth]{pictures/deltaphi_09_21.png}
\caption{Measurement 1: 2:1 \ce{CO2}-Argon.}
\label{fig:delta phi 1}
\end{subfigure}\hfill % <-- new
\begin{subfigure}{.48\textwidth}
\includegraphics[width=1\textwidth]{pictures/deltaphi_10_11.png}
\caption{Measurement 2: 1:1 \ce{CO2}-Argon.}
\label{fig:delta phi 2}
\end{subfigure}

\medskip % <-- new
\begin{subfigure}{.48\textwidth}
\includegraphics[width=1\textwidth]{pictures/deltaphi_08_21.png}
\caption{Measurement 3: 2:1 \ce{CO2}-Argon.}
\label{fig:delta phi 3}
\end{subfigure}\hfill % <-- new
\begin{subfigure}{.48\textwidth}
\includegraphics[width=1\textwidth]{pictures/deltaphi_08_11.png}
\caption{Measurement 4: 1:1 \ce{CO2}-Argon.}
\label{fig:delta phi 4}
\end{subfigure}

\medskip
\begin{subfigure}{.48\textwidth}
\includegraphics[width=1\textwidth]{pictures/deltaphi_11_21.png}
\caption{Measurement 5: 2:1 \ce{CO2}-Argon.}
\label{fig:delta phi 5}
\end{subfigure}

\caption{Phase shift of the different plasma measurements over their incident power.}
\label{fig:delta phi over P} 

\end{figure}

\end{document}

答案2

\hspace{0.48\textwidth}在最后一张(第 5 张)图像之后以 的形式添加一张“假图像” 。

在此处输入图片描述

\documentclass{article}

\usepackage[draft]{graphicx}
\usepackage{subcaption}

\begin{document}

\begin{figure}
  \centering
  \begin{subfigure}{.48\textwidth}
    \centering
    \includegraphics[width=0.9\textwidth]{pictures/deltaphi_09_21.png}
    \caption{Measurement 1: 2:1 CO$_2$-Argon.}
  \end{subfigure}
  \begin{subfigure}{.48\textwidth}
    \centering
    \includegraphics[width=0.9\textwidth]{pictures/deltaphi_10_11.png}
    \caption{Measurement 2: 1:1 CO$_2$-Argon.}
  \end{subfigure}

  \begin{subfigure}{.48\textwidth}
    \centering
    \includegraphics[width=0.9\textwidth]{pictures/deltaphi_08_21.png}
    \caption{Measurement 3: 2:1 CO$_2$-Argon.}
  \end{subfigure}
  \begin{subfigure}{.48\textwidth}
    \centering
    \includegraphics[width=0.9\textwidth]{pictures/deltaphi_08_11.png}
    \caption{Measurement 4: 1:1 CO$_2$-Argon.}
  \end{subfigure}

  \begin{subfigure}{.48\textwidth}
    \centering
    \includegraphics[width=0.9\textwidth]{pictures/deltaphi_11_21.png}
    \caption{Measurement 5: 2:1 CO$_2$-Argon.}
  \end{subfigure}
  \hspace{.48\textwidth}\mbox{}
  \caption{Phase shift of the different plasma measurements over their incident power.}
\end{figure}

\end{document}

相关内容