unplebeian said:
... Rainbow_Child, may I ask you what inspiration led you for such a asubstitution? I mean what insight did you have (not joking, I am serious...assuming your steps are correct that's an incredible that you could 'see' that substitution was going to work)...
I didn' t "saw" the transformation from the begging, even though I would like to!

I construct it. The integral was not fitting in any "recipe" I know, so I started like looking for a transformation
[tex]\sin x=\sqrt{k\,f(u)},\quad d\,x=\frac{\sqrt{k}\,f'(u)}{2\,\sqrt{f(u)\,(1-k\,f(u))}}\,d\,u[/tex]
and now the integral becomes
[tex]\int \frac{f'(u)}{2\,\sqrt{k}\,f(u)\,\sqrt{(1-k\,f(u))\,(1+f(u))}}\,d\,u[/tex]
Now I want to get rid of the square root [itex]\sqrt{(1-k\,f(u))\,(1+f(u))}[/itex], so the easy way is to set it equal to [itex]u^2[/itex], but that will produce additional square roots if we solve for [itex]f(u)[/itex].
The
"trick" is to the set [itex]u^2[/itex] the
fraction [tex]\frac{1+f(u)}{1-k\,f(u)}[/tex], so [tex]f(u)=\frac{u^2-1}{k\,u^2+1}[/tex] and
[tex](1+f(u))\,(1-k\,f(u))=\frac{1+f(u)}{1-k\,f(u)}\,(1-k\,f(u))^2=u^2\,\left(\frac{k+1}{k\,u^2+1}\right)^2[/tex]
Putting all these together you have the answer! Maybe there is a quicker way, but I could think only that!
unplebeian said:
... I tried the following and it seems to work out.
Let u= sin^2(x) +k, to get sin^2(x)= u-k and hence cos(x)= sqrt(1-u+k)
dx= cosec(x)/(2 x cos(x)) which yields in
int (du/sqrt(1-u-k)) From there it's easy.
I think that your transformation leads to
[tex]\int \frac{1}{\2\,(u-k)\,\sqrt{u\,(-u+k+1)}}\,du[/tex]
if I did correctly the calculations.