[texhax] Mathmode and Subfigures

Wood, Tobias C t.wood07 at imperial.ac.uk
Thu Feb 24 19:35:30 CET 2011


Hello,
First off apologies if this is the wrong place to post this, but I couldn't find another list on tug that seemed appropriate.

I have a figure that consists purely of three example 4x4 matrices. They're not equations, just the matrix by itself. Instead of constructing these in an external image editor and then including them via \includegraphics I decided to try and put the maths into LaTeX directly. However this was causing problems with \subfigure - instead of the matrices being placed nicely side by side in one horizontal row they were above and below each other with the caption separating them. I seem to have found a solution by placing a \makebox round all the subfigure commands, but I wanted to check whether this is right approach and what particular feature of mathmode is making it necessary? Thanks for any help - example code is given below.

Regards,
Toby Wood

P.S. I have no idea whether my indenting style is typical for LaTeX so sorry if this is hard to follow!

\begin{figure}
	\begin{center}
	\makebox[\textwidth]{
		\subfigure[1]{
			\begin{math}
			...
			\end{math}
		}
		\hfill
		\subfigure[2]{
			\begin{math}
			...
			\end{math}
		}
		\hfill
		\subfigure[3]{
			\begin{math}
			...
			\end{math}
		}
	}
	\end{center}
\end{figure}



More information about the texhax mailing list