[Tex/LaTex] How to typeset $:=$ correctly

math-moderelation-symbolssymbols

I like to use $:=$ for "is defined to be equal to", but this is never typeset with the symmetry one would like, as the colon is always too low relatively to the equals sign. Is there any way of getting this to appear correctly?

Best Answer

See the mathtools package, which offers the macro \coloneqq for this purpose.

\documentclass{standalone}
\usepackage{mathtools}
\begin{document}
\( b := 10 \) \emph{versus} \( b \coloneqq 10 \).
\end{document}

yields

Preview of the above document

Click image or right here to see it at full size (1600×133).

Note that the colon is slightly too low on the left, but vertically centered on the right.