#I=int_0^(pi) x/(1+(sinx)^2)*dx#
After using #x=pi-y# and #dx=-dy# transforms, #I# became
#I=int_(pi)^0 (pi-y)/(1+(sin(pi-y))^2)*(-dy)#
=#int_(pi)^0 (pi-y)/(1+(siny)^2)*(-dy)#
=#int_0^(pi) (pi-y)/(1+(siny)^2)*dy#
=#int_0^(pi) (pi-x)/(1+(sinx)^2)*dx#
After summing 2 integrals,
#2I=int_0^(pi) x/(1+(sinx)^2)*dx#+#int_0^(pi) (pi-x)/(1+(sinx)^2)*dx#
=#piint_0^(pi) (dx)/(1+(sinx)^2)#
=#piint_0^(pi) ((cscx)^2*dx)/((cscx)^2+1)#
=#piint_0^(pi) ((cscx)^2*dx)/((cotx)^2+2)#
=#piint_(pi)^0 (-(cscx)^2*dx)/((cotx)^2+2)#
After using #z=cotx# and #dz=-(cscx)^2*dx# transforms, it became
#2I=piint_(-oo)^oo (dz)/(z^2+2)#
=#(pisqrt2)/2*[arctan(z/sqrt2)]_(-oo)^oo#
=#(pi^2sqrt2)/2#
Thus, #I=(pi^2sqrt2)/4#