I'm trying to put vertical lines between the equations, but I can't do it. Here's my MWE.

\frac{dx_1}{dt} &= f_1&(x_1,\dots,x_i, x_n)\\
\vdots & &\vdots \\
\frac{dx_i}{dt} &= f_i&(x_1,\dots,x_i, x_n)\\
\vdots & &\vdots \\
\frac{dx_n}{dt} &= f_n&(x_1,\dots,x_i, x_n)

The dots are not in the right place. I want centered dots in both sides.


1 Answer 1


The magic word is \vdotswithin{...}. It horizontally centers \vdots in a box of the same width as .... Result Note that the \vdots in the first column are centered within the = which I consider better than within the whole expression.

Furthermore I'd recommend to not number the even lines (\nonumber). And there is another version of \vdotswithin, namely \shortvdotswithin, but this will cause a linebreak and therefore you cannot use it in this case, unless you don't use the workaround described in the mathtools documentation.


    \newlength{\mylengthA} \settowidth{\mylengthA}{$\dfrac{dx_i}{dt}$}
        \frac{dx_1}{dt} &= f_1           & &(x_1,\dots,x_i, x_n)               \\
                        &\vdotswithin{=} & &\vdotswithin{(x_1,\dots,x_i, x_n)} \\
        \frac{dx_i}{dt} &= f_i           & &(x_1,\dots,x_i, x_n)               \\
                        &\vdotswithin{=} & &\vdotswithin{(x_1,\dots,x_i, x_n)} \\
        \frac{dx_n}{dt} &= f_n           & &(x_1,\dots,x_i, x_n)

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .