TeX - LaTeX Stack Exchange is a question and answer site for users of TeX, LaTeX, ConTeXt, and related typesetting systems. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I don't like the way the vector with an arrow $\vec{x}$ looks. I would prefer to indicate it with a line underline but when I google it nothing comes up to show me how to do it. Does anyone know?




share|improve this question
Welcome to TeX.sx! Please add a minimal working example (MWE) that illustrates your problem. – Kurt Oct 7 '12 at 19:53
I did but someone edited it out. – Magpie Oct 7 '12 at 20:30
the macro itself is not an MWE. It is customary here to include the simplest document starting from \documentclass{...} ... \end{document} such that users can copy/paste your code and work on it directly. – percusse Oct 7 '12 at 21:05
up vote 27 down vote accepted

Here is a comparison of a few techniques to represent a vector (not sure about the \overline, \underline ones as I don't think that that is standard usage):

enter image description here



$\vec{x}$  $\overline{x}$  $\underline{x}$  $\mathbf{x}$

$\vec{\mathbf{x}}$  $\overline{\mathbf{x}}$  $\underline{\mathbf{x}}$ 
share|improve this answer
I really dislike using \mathbf since the font changes to upright. I want my vectors italic according to ISO 80000-2. Previously I have used the Boldmath bm package, now I use isomath for this. – Martin Ueding Jul 25 '15 at 20:08
@MartinUeding: I am not familiar with isomath. Perhaps you should post an answer. – Peter Grill Jul 26 '15 at 1:42
Can you underline a single blank space in an align (math mode)? – Jeff Apr 8 at 0:06
@Jeff: Should be able to. Try using \underline{\phantom{\space}}. Otherwise, I'd suggest posting a new question. – Peter Grill Apr 9 at 1:17

You can renew the command \vec.


In this case, if you use \vec your vector will be underlined. If you change mind and you want to use a dot or whatever, you can change the definition and all your \vec on the document will automatically change in the next compilation.



   \vec{x} = \cdots % "x" will be underlined
share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

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