[Tex/LaTex] Vertical Alignment of Equations in a Table

equationstablesvertical alignment

I am writing up a university project, and I want to create a table with the left column containing Feynman diagrams (which I have drawn using the feynmp package) and the right column containing equations. When I do this, however, the equations are vertically aligned in the bottom of the cell, and I can’t figure out how to change this, so that they align with the centre of the diagram in the same row.

Here is some sample code which I hope demonstrates the problem without writing out my whole report.

\begin{table*}[t]
\centering
\begin{tabular}{|c|c|}
\hline
\textbf{feynmp diagram goes here}
&
$\begin{aligned} I &= \\ &\frac{D}{4} \end{aligned}$
\\
\hline
\end{tabular}
\end{table*}

Best Answer

You can use the m{width} option of tabular:

\documentclass{article}

\usepackage{array}
\usepackage{amsmath}

\begin{document}
\begin{table*}[t]
\centering
\begin{tabular}{|c|m{5cm}|}
\hline
\textbf{feynmp diagram goes here} \newline
&
$\begin{aligned} I &= \\ &\frac{D}{4} \end{aligned}$
\\
\hline
\end{tabular}
\end{table*}
\end{document}
Related Question