How far can I go with the integral $\int \frac{\sin ^{n} x \cos ^{n} x}{1-\sin x \cos x} d x, $ where $n\in N$? Latest Edit
By the aid of my recent post, a closed form for its definite integral is obtained as below:
$$
\int_{0}^{\frac{\pi}{2}} \sin ^{k} \theta d \theta= \frac{\sqrt{\pi} \Gamma\left(\frac{k+1}{2}\right)}{k \Gamma\left(\frac{k}{2}\right)}
$$
Hence \begin{aligned}
\int_{0}^{\frac{\pi}{2}} \frac{\sin ^{n} x \cos ^{n} x}{1-\sin x \cos x} d x&=\frac{2}{\sqrt{3}}\left[\tan ^{-1}\left(\frac{2 \tan x-1}{\sqrt{3}}\right)-x\right]_{0}^{\frac{\pi}{2}} -\sum_{k=1}^{n-1} \frac{1}{2^{k}} \cdot \frac{\sqrt{\pi} \Gamma\left(\frac{k+1}{2}\right)}{k \Gamma\left(\frac{k}{2}\right)}\\&=\frac{\pi}{3\sqrt3}- \sum_{k=1}^{n-1} \frac{1}{2^{k}} \cdot \frac{\sqrt{\pi} \Gamma\left(\frac{k+1}{2}\right)}{k \Gamma\left(\frac{k}{2}\right)}
\end{aligned}

In my answer, I have found the integral
$$\int \frac{d x}{1-\sin x \cos x} =\frac{2}{\sqrt{3}} \tan ^{-1}\left(\frac{2 \tan x-1}{\sqrt{3}}\right)+C_0 
$$
Next,
$$
\begin{aligned}
& \int \frac{\sin x \cos x}{1-\sin x \cos x} d x \\
=& \int \frac{d x}{1-\sin x \cos x}-\int 1 d x \\
=& \frac{2}{\sqrt{3}} \tan ^{-1}\left(\frac{2 \tan x-1}{\sqrt{3}}\right)-x+C_{1}
\end{aligned}
$$
and
$$
\begin{aligned}
& \int \frac{\sin ^{2} x \cos ^{2} x}{1-\sin x \cos x} d x \\
=& \int \frac{1-\left(1-\sin ^{2} x \cos ^{2} x\right)}{1-\sin x \cos x} d x
\\
=& \int \frac{d x}{1-\sin x \cos x}-\int(1+\sin x \cos x) d x \\
=& \frac{2}{\sqrt{3}} \tan ^{-1}\left(\frac{2 \tan x-1}{\sqrt{3}}\right)-x+\frac{\cos 2 x}{4}+C_2
\end{aligned}
$$
Now I want to go further, $$
\begin{aligned}
& \int \frac{\sin ^{3} x \cos ^{3} x}{1-\sin x \cos x} d x \\
=& \int \frac{1-\left(1-\sin ^{3} x \cos ^{3} x\right)}{1-\sin x \cos x} d x \\
=& \int \frac{d x}{1-\sin x \cos x}-\int\left(1+\sin x \cos x+\sin ^{2} x \cos ^{2} x\right) d x \\
=& \frac{2}{\sqrt{3}} \tan ^{-1}\left(\frac{2 \tan x-1}{\sqrt{3}}\right)-x+\frac{\cos 2 x}{4}-\int \frac{\sin ^{2} 2 x}{4} d x \\
=& \frac{2}{\sqrt{3}} \tan ^{-1}\left(\frac{2 \tan x-1}{\sqrt{3}}\right)-x+\frac{\cos 2 x}{4}-\frac{1}{4}\int\frac{1-\cos 4 x}{2} d x\\
=& \frac{2}{\sqrt{3}} \tan ^{-1}\left(\frac{2 \tan x-1}{\sqrt{3}}\right)-x+\frac{\cos 2 x}{4}-\frac{1}{8}\left(x-\frac{\sin 4 x}{4}\right) +C\\=& \frac{2}{\sqrt{3}} \tan ^{-1}\left(\frac{2 \tan x-1}{\sqrt{3}}\right)-\frac{9}{8}  x+\frac{\cos 2 x}{4}+\frac{\sin 4 x}{32} +C_3
\end{aligned}
$$
Then I discovered that the integral
$$
I(n)=\int \frac{\sin ^{n} x \cos ^{n} x}{1-\sin x \cos x} d x
$$
has a telescoping series
$$I(k+1)-I(k)=-\int \sin ^{k} x \cos ^{k} x d x$$
Hence $$
I(n)-I(1)=-\sum_{k=1}^{n-1} \frac{1}{2^{k}} \int\sin ^{k}(2 x) d x
$$
We can conclude that
$$
I(n)=\frac{2}{\sqrt{3}} \tan ^{-1}\left(\frac{2 \tan x-1}{\sqrt{3}}\right)-x-\sum_{k=1}^{n-1} \frac{1}{2^{k}}\int\sin ^{k}(2 x) d x
$$
Then I was stuck with the last sum.
My question is whether we can find a closed form for the last sum.
 A: Just for your curiosity.
As said in comments, the result is not very pretty.
Using
$$I_k=\int_0^{\frac \pi 2} \sin^k(x)\,dx=\frac{\sqrt{\pi }}{2}\,\,\frac{\Gamma \left(\frac{k+1}{2}\right)}{\Gamma \left(\frac{k+2}{2}\right)}$$
$$S_n=\sum_{k=1}^{n-1} \frac{1}{2^{k+1}} \int_{0}^{\frac{\pi}{2}} \sin ^{k}( x)\, d x$$
$$S_n=\frac{8 \sqrt{3}-9}{36} \pi-\frac{\sqrt{\pi }}{ 2^{n+3}}\, T_n$$
$$T_n=2\frac{  \Gamma
   \left(\frac{n+1}{2}\right)}{\Gamma \left(\frac{n+2}{2}\right)}\, _2F_1\left(1,\frac{n+1}{2};\frac{n+2}{2};\frac{1}{4}\right)+\frac{ \Gamma
   \left(\frac{n+2}{2}\right)}{\Gamma \left(\frac{n+3}{2}\right)}\,
   _2F_1\left(1,\frac{n+2}{2};\frac{n+3}{2};\frac{1}{4}\right)$$ where appears the gaussian hypergeometric function.
However, the individual values of the $S_n$ are not bad. They write
$$S_n=a_n+ \pi b_n$$
The $a_n$ form the sequence
$$\left\{0,\frac{1}{4},\frac{1}{4},\frac{7}{24},\frac{7}{24},\frac{3}{10},\frac{3}{10},
   \frac{169}{560},\frac{169}{560},\frac{1523}{5040},\frac{1523}{5040},\frac{133}{440},\cdots\right\}$$ and the $b_n$ form the sequence
$$\left\{0,0,\frac{1}{32},\frac{1}{32},\frac{19}{512},\frac{19}{512},\frac{157}{4096},
   \frac{157}{4096},\frac{5059}{131072},\frac{5059}{131072},\frac{40535}{1048576},\frac{40535}{1048576},\cdots\right\}$$
Edit
If you plan to integrate in the range $0\le x \le \frac \pi 2$
$$I_{k+1}-I_k=\frac{\sec ^{-(k+1)}(x) }{k+1}\,\, _2F_1\left(\frac{1-k}{2},\frac{k+1}{2};\frac{k+3}{2};\cos^2(x)\right)$$
A: Let’s find a more general result and simplify with standard functions. The first step is a geometric series and the double angle formula:
$$\int \frac{\sin ^{n} x \cos ^{n} x}{1-\sin x \cos x} d x = \int \frac{\frac1{2^n}\sin ^{n}(2 x) }{1-\frac12\sin(2x)} d x\mathop=^{\big|\frac12\sin(2x)\big|<1} 2^{-n}\int \sin ^{n}(2 x)\sum_{m=0}^\infty \left(\frac12\sin(2x)\right)^m=2^{-n}\sum_{m=0}^\infty 2^{-m}\int\sin^{m+n}(2x)dx$$
The $(1m+1n)$ causes a coefficient of $\frac12$ in the resulting Hypergeometric/ Incomplete Beta function argument which cannot be used for a closed form since the coefficient should be a natural number
I tried with a few substitutions, but could never get natural number coefficients times the sum index showing that there is no closed with the Kampé de Fériet function, a double hypergeometric series function.
$$\,_2\text F_1(a,b;b+1;z)=bz^{-b} \text B_z(b,1-a)\implies 2^{-n}\sum_{m=0}^\infty 2^{-m}\int\sin^{m+n}(2x)dx = 2^{-n}\sum_{m=0}^\infty 2^{-m}\frac{\text{sgn}(\cos(2x))\sin^{m+n+1}(2x)}{2(m+n+1)}\,_2\text F_1\left(\frac12,\frac{m+n+1}2,\frac{m+n+1}2+1,\sin^2(2x)\right)= 2^{-n}\sum_{m=0}^\infty 2^{-m}\frac{\text{sgn}(\cos(2x))\sin^{m+n+1}(2x)}{2(m+n+1)}\left[\frac{m+n+1}2 \sin^2(2x)^ {-\frac{m+n+1}2}\text B_{\sin^2(2x)}\left(\frac{m+n+1}2,\frac12 \right)\right]$$
Therefore:
$$\boxed{\int \frac{\sin ^{n} x \cos ^{n} x}{1-\sin x \cos x} d x = C+2^{-n-2}\sum_{m=0}^\infty \frac{\text{sgn}(\sin(2x))^{m+n+1}\text{sgn}(\cos(2x))}{2^m} \text B_{\sin^2(2x)}\left(\frac{m+n+1}2,\frac12 \right) , |\sin(2x)|<2 }$$
Which again cannot be a closed form, but the integral can take a few complex values of $x$ with the Incomplete Beta function becoming a square root times a polynomial for certain values. Please correct me and give me feedback!
