# How to make \left<\overrightarrow{b}\right> look good?

I want a 'b' with an arrow on top, enclosed in angle brackets.

\left<\overrightarrow{b}\right>


gives angle brackets which are far too high.

<\overrightarrow{b}>


gives far too much horizontal space between the brackets and the \overrightarrow{b}:

\left<\smash{\overrightarrow}\right>


makes that formula look good, but the upper end of the 'b' touches the line above.

So what I want is basically a \smash that only affects the brackets, but not e.g. line spacing. Is this possible?

## migrated from stackoverflow.comMar 21 '11 at 17:10

This question came from our site for professional and enthusiast programmers.

• There is also \vec{b} to make that arrow---perhaps you like it better. – Svante Mar 21 '11 at 20:05

## 3 Answers

< and > are less than and greater than. If you use them where TeX expects delimiters (such as after \left, then you get angle brackets instead. I suspect what you want is just

\langle\overrightarrow{b}\rangle


which produces

use \big instead of \left/ \right

$\big<\overrightarrow{b}\big>$

• Gives the same result as @TH 's variant, except for the brackets being a bit bigger. Thanks. – srs Mar 21 '11 at 18:40

What about

\left<\smash{\overrightarrow{b}}\vphantom{b}\right>\vphantom{\overrightarrow{b}}


This is probably going to give the same result as TH.'s answer, but it illustrates the technique to get what you want: a b with an arrow on top which is treated for the purpose of expanding delimiters as a plain b.

Edit You are right about the line spacing--the \smashed \overrightarrow{b} will run over the line above. I've added another \vphantom to stretch the line after the delimiter.

• not quite. - As the arrow is not considered for line spacing, it can interfere with the above line. (at least it happened to me). Thanks however for explaining the \vphantom command. – srs Mar 21 '11 at 18:36
• @rainmaker: good point. I fixed that. – Matthew Leingang Mar 22 '11 at 0:12