The teacher hasn't uploaded a solution for this question yet.
We use the property $\int_{0}^{a}f(x)dx = \int_{0}^{a}f(a-x)dx$. Applying this to the given integral, we have $$I = \int_{0}^{\pi}\frac{dx}{a^{2}\cos^{2}x+b^{2}\sin^{2}x} = \int_{0}^{\pi}\frac{dx}{a^{2}\cos^{2}(\pi-x)+b^{2}\sin^{2}(\pi-x)}$$ Since $\cos(\pi-x) = -\cos x$ and $\sin(\pi-x) = \sin x$, we get $$I = \int_{0}^{\pi}\frac{dx}{a^{2}(-\cos x)^{2}+b^{2}(\sin x)^{2}} = \int_{0}^{\pi}\frac{dx}{a^{2}\cos^{2}x+b^{2}\sin^{2}x}$$ This doesn't simplify the integral, so we proceed with a different approach.
Divide both the numerator and the denominator by $\cos^{2}x$: $$I = \int_{0}^{\pi}\frac{\sec^{2}x}{a^{2}+b^{2}\tan^{2}x}dx$$
Since $\tan x$ is not defined at $x = \frac{\pi}{2}$, we split the integral at this point: $$I = \int_{0}^{\pi/2}\frac{\sec^{2}x}{a^{2}+b^{2}\tan^{2}x}dx + \int_{\pi/2}^{\pi}\frac{\sec^{2}x}{a^{2}+b^{2}\tan^{2}x}dx$$
For the first integral, let $t = \tan x$, so $dt = \sec^{2}x dx$. When $x = 0$, $t = 0$. When $x = \frac{\pi}{2}$, $t \to \infty$. $$I_{1} = \int_{0}^{\infty}\frac{dt}{a^{2}+b^{2}t^{2}} = \frac{1}{b^{2}}\int_{0}^{\infty}\frac{dt}{\frac{a^{2}}{b^{2}}+t^{2}} = \frac{1}{b^{2}}\left[\frac{b}{a}\arctan\left(\frac{bt}{a}\right)\right]_{0}^{\infty} = \frac{1}{ab}\left[\arctan\left(\frac{bt}{a}\right)\right]_{0}^{\infty} = \frac{1}{ab}\left(\frac{\pi}{2}-0\right) = \frac{\pi}{2ab}$$
For the second integral, let $t = \tan x$, so $dt = \sec^{2}x dx$. When $x = \frac{\pi}{2}$, $t \to -\infty$. When $x = \pi$, $t = 0$. $$I_{2} = \int_{-\infty}^{0}\frac{dt}{a^{2}+b^{2}t^{2}} = \frac{1}{b^{2}}\int_{-\infty}^{0}\frac{dt}{\frac{a^{2}}{b^{2}}+t^{2}} = \frac{1}{b^{2}}\left[\frac{b}{a}\arctan\left(\frac{bt}{a}\right)\right]_{-\infty}^{0} = \frac{1}{ab}\left[\arctan\left(\frac{bt}{a}\right)\right]_{-\infty}^{0} = \frac{1}{ab}\left(0-\left(-\frac{\pi}{2}\right)\right) = \frac{\pi}{2ab}$$
Therefore, $$I = I_{1} + I_{2} = \frac{\pi}{2ab} + \frac{\pi}{2ab} = \frac{\pi}{ab}$$
Final Answer: $\frac{\pi}{ab}$
AI generated content. Review strictly for academic accuracy.