This is a follow-up question on this one: Expected value for maximum of n normal random variable
@RobertIsrael states the following:
Presumably the $X_i$ are independent. If $\Phi$ is the standard normal cdf, $$P(\max_i X_i < \mu + t \sigma) = \prod_i P(X_i < \mu + t \sigma) = \Phi(t)^n$$ so $$ E[\max_i X_i] = \mu + \sigma \int_{-\infty}^\infty t \dfrac{d}{dt} \Phi(t)^n\ dt $$
I can see some of the ideas that lead to this formula (e.g. the multiplication because of independence) but I don't see all of the details. It would be very helpful if somebody could explain the derivation in detail... Thank you!
It is basically using the definition of expected value and one simple substitution. The first equation can be rewritten as $$ \mathbb{P}(\max_i X_i < t) = \Phi\left(\frac{t - \mu}{\sigma}\right)^n. $$ Then, by definition $$ \mathbb{E} \max_i X_i = \int_{-\infty}^{+\infty} t \cdot \frac{d}{dt} \Phi\left(\frac{t - \mu}{\sigma}\right)^n dt = \int_{-\infty}^{+\infty} \sigma(t + \mu) \cdot \sigma \frac{d}{dt} \Phi(t)^n \frac{dt}{\sigma} = \mu + \sigma \int_{-\infty}^{+\infty} t\cdot \frac{d}{dt} \Phi(t)^n dt, $$ as desired.
So, in the first equation we used the substitution $t \to \sigma t + \mu$, in the second one we simplified the expression and used that integral of the density function over the whole domain is $1$.