
This is the original problem.

I understand that I have to change the order of integration, substitute u, and derive, but I'm confused as to why I get the derivative of d with respect to u, and du with respect to x. Can someone explain why I use those derivatives in those places? According to my lesson, it's due to the chain rule, but I don't see the chain rule actually being applied. If it were the chain rule, it would have to be the ENTIRE integral, rather than just u, right?
Thank you for your time.