<span style='font-family:Verdana'><span style='font-size:12px'><span style="font-family:Verdana"><span style="font-size:12px">From: Manfred Braun</span></span><br />
<blockquote style="border-left: 1px solid #CCC; padding-left: 5px; margin-left: 5px; margin-bottom: 0px; margin-top: 0px; margin-right: 0px;" type="cite">
<br />
<div>
<div>
<pre style="white-space: pre-wrap; word-wrap: break-word; font-size:11;pre">
On 17.07.2012, at 16:38, John B. Thoo wrote:
> Hi, everyone. I apologize that this is not a Mac-specific question, but rather a general LaTeX question; however, I don't know whom else to ask.
>
> This code
>
> \begin{figure}
> \begin{tikzpicture}
> \pgftransformscale{0.75}
> %% axes
> \draw[help lines,lightgray] (-1,-1) grid (5,5);
> \draw[thin] (-1,0) -- (5,0) node[anchor=north]{$x$};
> \draw[thin] (0,-1) -- (0,5) node[anchor=west]{$y$};
> %% u and (u1,u2)
> \draw[thick,-latex] (0,0) -- (3,4);
> \draw (1.6,2) node[anchor=west]{$\vec{u} = \left[\begin{array}{c} 3 \\ 4 \end{array}\right]$};
> \fill (3,4) circle (0.08) node[anchor=west]{$(3,4)$};
> \end{tikzpicture}
> \caption{It is useful to picture vectors as arrows, although this may not be a literal representation of vectors. Here we identify the vector $\vec{u} = \left[\begin{smallmatrix} 3 \\ 4 \end{smallmatrix}\right]$ in $\R{2}$ represented as an arrow with the point $(3,4)$ in the $xy$ plane.}
> \label{fig.syslineqns:vectorasarrow}
> \end{figure}
>
> produces this error
>
> [5]
> ! Argument of \@caption has an extra }.
> <inserted text>
> \par
> l.177 ...ith the point $(3,4)$ in the $xy$ plane.}
Within a caption the use of commands and environments is restricted. Commands must be "protected". A possible solution is as follows: Define, for instance,
\newcommand\mymatrix{ \left[ \begin{smallmatrix} 3 \\ 4 \end{smallmatrix} \right] }
in the preamble. Then replace your caption by
\caption{It is useful to picture vectors as arrows, although this may not be a literal representation of vectors. Here we identify the vector $\vec{u} = \protect\mymatrix$ in $\R{2}$ represented as an arrow with the point $(3,4)$ in the $xy$ plane.}
This should work. Important is to include the \protect command. It prevents the immediate expansion of the subsequent \mymatrix command, the expansion is postponed until the caption is typeset.
Manfred</pre>
</div>
</div>
</blockquote>
<p style="margin:0px; padding:0px;" >
</p>
Alternatively, you can load the caption package and provide an alternative title for the caption to be used in the list of figures:<br />
<br />
\usepackage{caption}<br />
<br />
\begin{figure}<br />
...<br />
\captionsetup{singlelinecheck=off}<br />
\caption[stuff for list of figures]{stuff for the actual caption}<br />
\end{figure}<br />
<br />
Alan<br />
<br />
</span></span>