How to type the letter “i” with two dots (diaeresis) in math mode? [duplicate]

I would like to type the letter "i" in math mode, but with two (horizontally aligned) dots rather than with just one.

I know there is \ddot{i}, but that puts the two dots on top of the existing one, while \text{\"i} sets the letter in text form rather than in math mode. MWE:

\documentclass{article}
\begin{document}

\begin{align*}
f(x) = \ddot i \\
f(x) = \text{\"i}
\end{align*}

\end{document}


gives

How can I get the desired result? Thanks! (And I know that the two dots can lead to confusion with the second derivative.)

-

marked as duplicate by egreg, lockstep, karlkoeller, Claudio Fiandrino, T. VerronJul 17 '13 at 9:13

\ddot{\imath} –  egreg Jul 17 '13 at 8:00
The same applies to \jmath. –  Martin Jul 17 '13 at 8:26
\ddot{\imath} for mathitalic – or \ddot{\i} for mathroman.