Aligning multiple matrices and vectors

Hello, I would like to create two vectors or matrices, such that the rows of each vector/matrix line up horizontally. For example, consider the following

$ vec(f_a, f_b, f_c) = vec(a, b, c) $

Screenshot 2024-10-14 at 15.27.49

I would instead like the right vector to have vertical padding in each cell, such that I can draw parallel lines from $f_a$ to $a$, $f_b$ to $b$, and so on.

I tried to use the gap parameter, but this yields the following results:

#set math.vec(gap: 2em)
$ vec(f_a, f_b, f_c) = vec(a, b, c) $

Screenshot 2024-10-14 at 15.34.22

I can get closer using grid, but it requires manual tuning and the braces still differ.

$ vec(#grid(columns: 1, gutter: 5pt, $ f_a $, $ f_b $, $ f_c $)) = vec(#grid(columns: 1, gutter: 10pt, $ a $, $ b $, $ c $)) $ 

As a new user, I can only add two images so you will need to imagine the results.

This is a layout issue that was fixed for 0.12. You can try out the effect using the release candidate (0.12.0-rc1) right now, following instructions here and/or here.

1 Like