Taking the derivative of capital per effective unit of labor in the Solow model
I've tried to "fill the blanks", hope this helps.

$$\tilde{k} = \frac{K}{AL}$$
$$\frac{d[\tilde{k}]}{dt} = \frac{d}{dt}\left[\frac{K}{AL} \right] \quad (1)$$ 
Now we use the quocient rule: to differentiate $f(x) = \frac{g(x)}{h{x}}$ (for $h(x) \neq 0$) we can apply the formula $f'(x) = \frac{h(x)g'(x) - g(x)h'(x)}{[h(x)]^2}$. In your problem, $f(x) = \dot{k}$, $g(x) = K$ and $h(x) = AL$, but instead $x$, you have $t$. So, applying the rule in (1), we have:
$$\frac{d[\tilde{k}]}{dt} = \frac{AL\left(\frac{d[K]}{dt}\right) - K\left(\frac{d[AL]}{dt}\right)}{(AL)^2} \quad (2)$$

The second term in the numerator has the derivative of a product ($AL$), so we need again to use the appropriate rule: $(f(x)\cdot g(x))' = f'(x)\cdot g(x) + f(x)\cdot g'(x)$

So, using the rule in (2) we have:

$$\frac{d[\tilde{k}]}{dt} = \frac{AL\left(\frac{d[K]}{dt}\right) - K\left(L\frac{d[A]}{dt}+A\frac{d[L]}{dt}\right)}{(AL)^2}$$

Now we re-write using dot notation - $\dot{x} \equiv \frac{d[x]}{dt}$:

$$\dot{\tilde{k}} = \frac{AL\dot{K} - K(L\dot{A}+A\dot{L})}{(AL)^2} \quad = \frac{AL\dot{K}}{(AL)^2}-\frac{KL\dot{A}}{(AL)^2}-\frac{KA\dot{L}}{(AL)^2}$$

Since $\frac{\dot{A}}{A} = g$ and $\frac{\dot{L}}{L} = n$, we have

$$\dot{\tilde{k}} = \frac{\dot{K}}{AL} - Kg -  Kn = \frac{\dot{K}}{AL} -K(n+g)$$

ps: I'm not sure why your textbook is using dot notation over $\tilde{k}$ before taking the derivative.

EDIT:

I'm adding an alternative way to achieve the same result. 

Starting with $\tilde{k} = \frac{K}{AL}$, you can rewrite as $K = \tilde{k}AL$.

Now, take log on both sides and remember that $log(ab) = log(a) + log(b)$:

$log(K) = log(\tilde{k}AL) = log(\tilde{k}) + log(A) + log(L) \quad (1)$

Now we are going to take the derivative (in t), using the log rule: if $f(x) = log(x)$, then $f'(x) = \frac{1}{x}$. But now we have to use the chain rule, because all variables are in reality functions of $t$. The chain rule is: if z depends on y and y depends on t, then z depends on t: $\frac{dz}{dt} = \frac{dz}{dy}\frac{dy}{dt}$. Using $log(K)$ as example, we have: $\frac{d}{dt}[log(K)] = \frac{d}{dK}[log(K)]\cdot \frac{d}{dt}[K]$.

(1) then became:
$$\frac{d}{dt}[log(K)] =  \frac{d}{dt}[log(\tilde{k})] + \frac{d}{dt}[log(A)] + \frac{d}{dt}[log(L)]$$

Which is...
$$\frac{d}{dK}[log(K)]\cdot \frac{d}{dt}[K] =  \frac{d}{d\tilde{k}}[log(\tilde{k})]\cdot\frac{d}{dt}[\tilde{k}] + \frac{d}{dA}[log(A)]\cdot\frac{d}{dt}[A] + \frac{d}{dL}[log(L)]\cdot\frac{d}{dt}[L]$$

Now we substitute all derivatives of logs and use dot notation:

$$\frac{1}{K}\dot{K} = \frac{1}{\tilde{k}}\dot{\tilde{k}} + \frac{1}{A}\dot{A} + \frac{1}{L}\dot{L} = \frac{\dot{\tilde{k}}}{\tilde{k}} + g + n$$

In the SS we have $\frac{\dot{\tilde{k}}}{\tilde{k}} = 0$, so:

$$\frac{\dot{K}}{K} = g + n$$