Consider this MWE:
\documentclass{article}
\begin{document}
\[\vec{v}_{12345}^{12345678}\]
\[\overrightarrow{P_{12345}P_{12345}^{12345678}}\]
\end{document}
As you can see, \vec
is designed to typeset a vector with an arrow above the argument.
However, when we do not have a unary symbol to represent a vector (e.g. the difference between the coordinates of two points) then we can use \overrightarrow
. But this notation has two problems:
- When we are working with long chain of numbers
\overrightarrow
collides with it, as shown in the example. - And I think the most important: it is not consistent with
\vec
. Why? Because\vec
stops the arrow before the subscript/superscript, but\overrightarrow
continues the arrow to the end regardless of the existence or not of subscript/superscript.
Remember that we are writing vectors, no matter the length of the text that represents the vector.
What I want
With your huge help, I would like to write the following:
Thanks!!
\[\overrightarrow{P_{12345}P}\!_{12345}^{\,12345678}\]
but I promise you that in a few years you will find this notation awkward. – user121799 Apr 1 '19 at 23:19