# The dot product integral in the proof of the Parallel axis theorem

The first picture is a question about proving the Parallel axis theorem and the second is the solution. I have no problem with the solution except for the part which says that $$\int 2\vec h \cdot \vec r_\text{cm} dm = 2\vec h \cdot \int \vec r_\text{cm} dm$$ I don't understand how they got the dot product out of the integral. It seems mathematically illogical to me. Can anyone explain that to me. Thanks in advance.

Presumably you're okay with the intermediate step $$\int 2\vec h\cdot \vec r_\text{cm} dm = 2\int \vec h\cdot \vec r_\text{cm} dm \tag1$$ since the number two is a constant, and integration is linear over a constant. The authors assert that $\vec h$ is also constant, so it comes out as well.
If it's motion of the dot product across the integral sign that bothers you, expand the dot product in terms of vector components: $$\vec h \cdot \vec r = h_x r_x + h_y r_y + h_z r_z$$ Now it's clear that the single vector-product integral in (1) is the sum of three scalar-product integrals. The first is $$\int h_x r_x dm = h_x \int r_x dm$$ where the extraction is totally okay because $h_x$ is a constant in this problem.