I have got a problem with one of my figures in my Latex file and I
can't find the solution.
I have a big figure, consisting of 12 subfigures which should go over
2 pages. When I have 6 of them in two separate figures then everything
works fine but the numbering doesn't work. Hence I use the captcont
package.
However, it always fails to create the dvi when it gets to the 12th
subfigure. Shortening the file names didn't help.
It comes up with the message
<figures/VM_050126_FMSPGR/VM_050126_SE2_IM19_annotated.eps>
! Missing $ inserted.
<inserted text>
$
l.272 ...126_FMSPGR/VM_050126_SE2_IM19_annotated}}
%\\
?
Here is the source:
\begin{figure}%
\centering
\subfigure[][]{%
\label{fig:VM_050126_FMSPGR-b}%
\includegraphics[width=55mm]{figures/VM_050126_FMSPGR/
VM_050126_SE2_IM08_annotated}}%
\hspace{8pt}%
\subfigure[][]{%
\label{fig:VM_050126_FMSPGR-c}%
\includegraphics[width=55mm]{figures/VM_050126_FMSPGR/
VM_050126_SE2_IM09}}\\%
\subfigure[][]{%
\label{fig:VM_050126_FMSPGR-d}%
\includegraphics[width=55mm]{figures/VM_050126_FMSPGR/
VM_050126_SE2_IM10}}%
\hspace{8pt}%
\subfigure[][]{%
\label{fig:VM_050126_FMSPGR-e}%
\includegraphics[width=55mm]{figures/VM_050126_FMSPGR/
VM_050126_SE2_IM11_annotated2}}\\%
\subfigure[][]{%
\label{fig:VM_050126_FMSPGR-f}%
\includegraphics[width=55mm]{figures/VM_050126_FMSPGR/
VM_050126_SE2_IM12}}%
\hspace{8pt}%
\subfigure[][]{%
\label{fig:VM_050126_FMSPGR-g}%
\includegraphics[width=55mm]{figures/VM_050126_FMSPGR/
VM_050126_SE2_IM13_annotated}}\\
\captcont{\textbf{Patient VM\_050126}\newline
Axial FMSPGR (`Fast Multiplanar SPoiled GRadient-echo') images
acquired at:
\texttt{112.9775466919 - $n\cdot$6}; where $n$ is the $n^{th}$
image when counting from \subref{fig:VM_050126_FMSPGR-b}.\newline
See main text for explanation.}
\label{fig:VM_FirstPart}%
\end{figure}
\begin{figure}
\centering
\subfigure[][]{%
\label{fig:VM_050126_FMSPGR-h}%
\includegraphics[width=55mm]{figures/VM_050126_FMSPGR/
VM_050126_SE2_IM14}}%
\hspace{8pt}%
\subfigure[][]{%
\label{fig:VM_050126_FMSPGR-i}%
\includegraphics[width=55mm]{figures/VM_050126_FMSPGR/
VM_050126_SE2_IM15}}\\%
\subfigure[][]{%
\label{fig:VM_050126_FMSPGR-j}%
\includegraphics[width=55mm]{figures/VM_050126_FMSPGR/
VM_050126_SE2_IM16_annotated}}%
\hspace{8pt}%
\subfigure[][]{%
\label{fig:VM_050126_FMSPGR-k}%
\includegraphics[width=55mm]{figures/VM_050126_FMSPGR/
VM_050126_SE2_IM17}}\\%
\subfigure[][]{%
\label{fig:VM_050126_FMSPGR-l}%
\includegraphics[width=55mm]{figures/VM_050126_FMSPGR/
VM_050126_SE2_IM18}}\\%
\hspace{8pt}%
\subfigure[][]{%
\label{fig:VM_050126_FMSPGR-m}%
\includegraphics[width=55mm]{figures/VM_050126_FMSPGR/
VM_050126_SE2_IM19_annotated}}%\\
\caption*{continued}%
\label{fig:VM_050126}%
\end{figure}
I hope anyone can shed some light on why it complains about a missing
$.
Thanks,
Olivier
first try to make a minimal example:
* replace all figures by \rule{3cm}{3cm} (because we done have the figures)
* then create a full minimal document we can compile on our system without
having to guess which packages you are using, or the documentclass
then it might be easier to fix the problem
--
/daleif (remove RTFSIGNATURE from email address)
LaTeX FAQ: http://www.tex.ac.uk/faq
LaTeX book: http://www.imf.au.dk/system/latex/bog/ (in Danish)
Remember to post minimal examples, see URL below
http://www.tex.ac.uk/cgi-bin/texfaq2html?label=minxampl
http://www.minimalbeispiel.de/mini-en.html
try \usepackage{underscore}
Herbert
--
http://PSTricks.tug.org
http://tug.org/CTAN/info/math/voss/
> first try to make a minimal example:
>
> * replace all figures by \rule{3cm}{3cm} (because we done have the figures)
\usepackage[demo]{graphicx}
does the trick ...
> It comes up with the message
>
> <figures/VM_050126_FMSPGR/VM_050126_SE2_IM19_annotated.eps>
> ! Missing $ inserted.
> <inserted text>
> $
> l.272 ...126_FMSPGR/VM_050126_SE2_IM19_annotated}}
> %\\
> ?
>
> Here is the source:
When I insert your source code into
\documentclass{article}
\usepackage[demo]{graphicx}
\usepackage{subfigure,captcont}
\listfiles
\begin{document}
... % <= YOUR SOURCE HERE!
\end{document}
it compiles fine here. So please give us a minimal example, please.
See: http://www.minimalbeispiel.de/mini-en.html
Axel
I think it may have something to do with the documentclass, which the
journal wants us to use.
Olivier
\documentclass{elsart}
\usepackage{graphicx}
\usepackage{subfigure}
\usepackage{captcont}
\begin{document}
\begin{figure}%
\centering
\subfigure[][]{%
\rule{3cm}{3cm}}%
\hspace{8pt}%
\subfigure[][]{%
\rule{3cm}{3cm}}\\%
\subfigure[][]{%
\rule{3cm}{3cm}}%
\hspace{8pt}%
\subfigure[][]{%
\rule{3cm}{3cm}}\\%
\subfigure[][]{%
\rule{3cm}{3cm}}%
\hspace{8pt}%
\subfigure[][]{%
\rule{3cm}{3cm}}\\
\captcont{Caption of First Figure...}
\label{fig:FirstPart}%
\end{figure}
\begin{figure}
\centering
\subfigure[][]{%
\rule{3cm}{3cm}}%
\hspace{8pt}%
\subfigure[][]{%
\rule{3cm}{3cm}}\\%
\subfigure[][]{%
\rule{3cm}{3cm}}%
\hspace{8pt}%
\subfigure[][]{%
\rule{3cm}{3cm}}\\%
\subfigure[][]{%
\rule{3cm}{3cm}}%
\hspace{8pt}%
\subfigure[][]{%
\rule{3cm}{3cm}}%\\
\caption*{Caption continued}%
\label{fig:SecondPart}%
\end{figure}
\end{document}
No problems here
using these versions
elsart.cls 2006/05/01, 2.19: Elsevier
latexsym.sty 1998/08/17 v2.2e Standard LaTeX package (lasy symbols)
ulasy.fd 1998/08/17 v2.2e LaTeX symbol font definitions
graphicx.sty 1999/02/16 v1.0f Enhanced LaTeX Graphics (DPC,SPQR)
keyval.sty 1999/03/16 v1.13 key=value parser (DPC)
graphics.sty 2006/02/20 v1.0o Standard LaTeX Graphics (DPC,SPQR)
trig.sty 1999/03/16 v1.09 sin cos tan (DPC)
graphics.cfg 2007/01/18 v1.5 graphics configuration of teTeX/TeXLive
dvips.def 1999/02/16 v3.0i Driver-dependant file (DPC,SPQR)
subfigure.sty 2002/03/15 v2.1.5 subfigure package
subfigure.cfg
captcont.sty 2002/02/14 v2.0 captcont package
***********
why is it even necessary?
\includegraphics should be able to handle _'s by itself.
I use the documentclass for the formatting convenience (Abstract,
Keywords, Authors etc...). It now works fine, and includegraphics
works fine with the _'s
So all good - Thanks again.
Olivier
[...]
>> try \usepackage{underscore}
>> Herbert
>>
>
> why is it even necessary?
>
> \includegraphics should be able to handle _'s by itself.
Yes, but \subfloat fixes the catcodes. (Well, one could have a
xgraphicx package that runs stuff through eTeX' reparsing mechanisms.)
Ulrich
--
struct a{typedef int foo;};struct a1:a{};struct a2:a{};
#define X(b,a) struct a##1:b##1,b##2{};struct a##2:b##1,b##2{};
X(a,b)X(b,c)X(c,d)X(d,e)X(e,f)X(f,g)X(g,h)X(h,i)X(i,j)X(j,k)X(k,l)
X(l,m)X(m,n) n1::foo main(){} /* -- /bin/true-Clone von SR. Testen! */
stupid \subfloat ;-)