Obtaining the magnitude of the frequency response by plugging $e^{jω}$ into the z-domain transform function? I am reading a text on discrete signal processing, which states that the frequency response of a signal can be obtained by plugging the value $e^{jω}$ into the z-domain transfer function $H(z)$. In other words:

$H_{IIR}(ω) = H(z)|_{z=e^{jω}}$

In the example given in the text, it is given that:

$H(z) = (\frac{1}{1 - \frac{1}{5}z^{-1}}) (\frac{1}{1 + \frac{1}{2}z^{-1}})$

Next, the text presents the following equation for the magnitude of the frequency response when $ω = \frac{\pi}{2T}$:

$|H_{IIR}(\frac{\pi}{2T})| = \frac{|j|}{|j - \frac{1}{5}||j + \frac{1}{2}|} = \frac{1}{\sqrt{\frac{1}{25} + 1}\sqrt{\frac{1}{4} + 1}} = \frac{\sqrt{130}}{13}$

I don't understand how the author derived the above equation. That is, what kind of wizardry leads to the following equations?

$|H_{IIR}(\frac{\pi}{2T})| = |(\frac{1}{1 - \frac{1}{5}e^{-j\frac{\pi}{2T}}}) (\frac{1}{1 + \frac{1}{2}e^{-j\frac{\pi}{2T}}})| = \frac{|j|}{|j - \frac{1}{5}||j + \frac{1}{2}|} = \frac{1}{\sqrt{\frac{1}{25} + 1}\sqrt{\frac{1}{4} + 1}}$

Does it have something to do with magnitude and a special identity regarding the constant $e$?
It's  derived using Euler's equation http://en.wikipedia.org/wiki/Euler's_formula. You start with $$H(z) = (\frac{1}{1 - \frac{1}{5}z^{-1}}) (\frac{1}{1 + \frac{1}{2}z^{-1}})$$

Then plug in $e^{-jwT}$ for $z^{-1}$ and you get 

$$H(z) = (\frac{1}{1 - \frac{1}{5}e^{-j\frac{\pi }{2}}}) (\frac{1}{1 + \frac{1}{2}e^{-j\frac{\pi }{2}}})$$

Now according to Euler we simply have $e^{-j\frac{\pi }{2}} = -j$ so the whole thing simplifies to

$$H(z) = (\frac{1}{1 - \frac{1}{5}\cdot (-j)}) (\frac{1}{1 + \frac{1}{2}\cdot (-j)})$$. 

Utilizing $(-j) \cdot j = 1$ we can multiple each part of the fraction with j/j and get 
$$H(z) = (\frac{j}{j - \frac{1}{5}}) (\frac{j}{j + \frac{1}{2}})$$

Then we can take the magnitude as 

$$\left | H(z) \right | = \frac{\left | j^{2} \right |}{\left | j-\frac{1}{5} \right |\cdot \left | j+\frac{1}{2} \right |}$$

This isn't exactly the same formula that you have given but since magnitude j and j^2 are the same, the final result comes out to be the same.