How to divide by a matrix I found a question in an old exam, where the function $\phi(z) := \frac{\exp(z) - 1}{z}$ is given. 
Now we evaluate $\phi(\mathbf{A})$. But how do I divide by a matrix? 
I already thought about taking the inverse, but how do I now on which side I have to multiply the inverse? 

Note that applying function to a matrix is meant in sense of series, that is if
$$
\phi(z) = c_0 + c_1 z + c_2 z^2 + \dots
$$
then
$$
\phi(\mathbf A) = c_0 \mathbf I + c_1 \mathbf A + c_2 \mathbf A^2 + \dots.
$$
Observe that 
$$
\phi(z) = \frac{e^z - 1}{z} = 1 + \frac{z}{2} + \frac{z^2}{6} + \dots = 
\sum_{k = 1}^\infty \frac{z^{k-1}}{k!}.
$$
Also, to your question, dividing by a matrix is multiplying with its inverse, but that depends on commutativity, there's basically two ways to divide on a matrix - on the right and on the left. Luckily, a matrix commute with any power of itself, so there's no difference on which side do you write the $\mathbf A^{-1}$:
$$
\phi(\mathbf A) = \mathbf A^{-1} (e^\mathbf{A} - \mathbf I).
$$
