TITLE: A strange integral having to do with the sophomore's dream:
QUESTION [45 upvotes]: I recently noticed that this really weird equation actually carries a closed form!
$$\int_0^1 \left(\frac{x^x}{(1-x)^{1-x}}-\frac{(1-x)^{1-x}}{x^x}\right)\text{d}x=0$$
I honestly do not know how to prove this amazing result! I do not know nearly enough about the sophomore's dream integral properties to answer this question, which I have been trying to apply here. (If possible, please stay with real methods, as I do not know contour integration yet)

REPLY [3 votes]: As property of definite integrals   it is known that for any function integrand $f(x)$
$$\int_0^a{f(x)}\text{d}x = \int_0^a{f(a-x)}\text{d}x$$
Geometrically this means the area under the curve when flipped about the line $ x= \dfrac{a}{2}$ as a rigid figure cannot change. The property can be stated symbolically as in  one particular generalisation where ${p} $ is a constant:
$$\int_0^1 \frac{f(x)^p}{f(1-x)^p}\text{d}x=\int_0^1 \frac{f(1-x)^p}{f(x)^p}\text{d}x.$$
For p = 1 you can write the integrand  also as a product in another  example.
$$ \int_0^{\pi}{\cos^5 \phi \sin \phi }\, d \phi = \int_0^{\pi}{\sin ^5 \phi \cos \phi }\, d \phi $$
I am sure the generalisation  takes a fanciful attention.Earlier days I would imagine a "curved roof trapezoid " and flip it without change of area under the roof.