在海报中包含子图

在海报中包含子图

我正在尝试为会议演示写一张海报,到目前为止,除了我想包含的 2 个图(两个图应该在同一行,并有一个共同的标题)之外,一切都运行良好。出于某种原因,我不断收到错误。我使用的软件包是:

\usepackage{palatino}
\usepackage[latin1]{inputenc}
\usepackage{epsf}
\usepackage{graphicx,psfrag,color,pstcol,pst-grad}
\usepackage{amsmath,amssymb}
\usepackage{latexsym}
\usepackage{calc}
\usepackage{multicol}
  \usepackage{amsmath,amsfonts,latexsym,amssymb,enumerate,amsthm,array,bm,amscd,overcite,psfrag,epsfig}
\usepackage{capt-of}
\usepackage{subfig}

我曾尝试使用:

\begin{center}

\mbox{\subfigure%[Feasible Case \label{fig:Feas_Case}]
{\includegraphics[scale=0.4]{FeasibleCase.eps} }\qquad
\subfigure%[Infeasible Case \label{fig:Infeas_Case}]
{\includegraphics[scale=0.4]{InfeasibleCase.eps} }
}
\captionof{figure}{My Feas-inf figures} 
\label{fig:Feas_Infeas}

\end{center}

但我一直收到这些错误:

! Undefined control sequence.
<argument> \subfigure
{\includegraphics [scale=0.4]{FeasibleCase.eps} }\qqua...
l.593 }
The control sequence at the end of the top line
of your error message was never \def'ed. If you have
misspelled it (e.g., `\hobx'), type `I' and the correct
spelling (e.g., `I\hbox'). Otherwise just continue,
and I'll forget about whatever was undefined.
File: FeasibleCase.eps Graphic file (type eps)
<FeasibleCase.eps>
! Undefined control sequence.
<argument> ...easibleCase.eps} }\qquad \subfigure
{\includegraphics [scale=0...
l.593 }
The control sequence at the end of the top line
of your error message was never \def'ed. If you have
misspelled it (e.g., `\hobx'), type `I' and the correct
spelling (e.g., `I\hbox'). Otherwise just continue,
and I'll forget about whatever was undefined.
File: InfeasibleCase.eps Graphic file (type eps)
<InfeasibleCase.eps>

我不知道该怎么做才能解决这个问题。有什么想法吗?(我也尝试过使用 \usepackage{subfigure} 包而不是 \usepackage{subfig} 包,但这会给我带来更多错误。)

答案1

\documentclass{article}
\usepackage[demo]{graphicx}
\usepackage{subfig}
\usepackage{float}
\begin{document}
\begin{figure}[H]
  \centering
  \begin{tabular}{cc}
    \subfloat[caption]{\includegraphics[width = 1.5in]{something}} &
    \subfloat[caption]{\includegraphics[width = 1.5in]{something}}
  \end{tabular}
  \caption{caption}
\end{figure}
\end{document}

这应该可以为你完成工作:

在此处输入图片描述

相关内容