3

I try to have a simple tabularx-table in which the cell content is vertically aligned to the top. While this works as expected for text, two aligned-environments in adjacent cells are vertically centered for no reason I could find.

How do I get the content of the first tabularx-environment aligned to the top?

Thank you.

\documentclass[10pt,a4paper]{article}

\usepackage{lipsum}
\usepackage{amsmath}
\usepackage{tabularx}

\begin{document}

    \begin{tabularx}{\textwidth}{X l}
        \hline
        $
            \begin{aligned}
                a &= 1 \\
                b &= 2
            \end{aligned}
        $
        &
        $
            \begin{aligned}
                c =& 3
            \end{aligned}
        $\\  
        \hline          
    \end{tabularx}

    \begin{tabularx}{\textwidth}{X l}
        \hline
            \lipsum[1]
        &
            $
                \begin{aligned}
                    c =& 3
                \end{aligned}
            $\\  
        \hline          
    \end{tabularx}

\end{document}

vertical alignment in tabularx fails for "aligned" environment

2

You want

\begin{aligned}[t]

to align on the top.

  • Although I don't understand why the aligned-environment in the second table behaves differently. – Bastian Oct 7 '14 at 15:45

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.