# Integrals that keep me up at night!

Physics Slayer
Homework Statement:
Need help finding the following indefinite integrals
Relevant Equations:
-
Been struggling with a few integrals, I might post a few more once I progress further in my assignment.

$$1. \int \sqrt{tanx} + \sqrt{cotx} (dx)$$

Attempt1:
for integral 1, I try to apply integration by parts on both ##\sqrt{tanx}## and ##\sqrt{cotx}## separately, I then get
$$\int \underbrace{\sqrt{tanx}}_{\textrm{u}}\underbrace{(dx)}_{\textrm{dv}} + \int \underbrace{\sqrt{cotx}}_{\textrm{u}}\underbrace{(dx)}_{\textrm{dv}}$$

this gives,
$$=\left( x\sqrt{tanx}-\int \underbrace{x}_{\textrm{u}}.\underbrace{\frac{sec^2x}{2\sqrt{tanx}}}_{\textrm{dv}}(dx)\right) + \left(x\sqrt{cotx}-\int \underbrace{x}_{\textrm{u}}.\underbrace{\frac{(-coesc^2x)}{2\sqrt{cotx}}}_{\textrm{dv}}(dx)\right)$$

after applying integration by parts again I sadly get, RHS = LHS

$$=\left(xtanx - \left(x\sqrt{tanx}-\int \sqrt{tanx}(dx)\right)\right) + \left(x\sqrt{cotx}-\left(x\sqrt{cotx}-\int\sqrt{cotx}(dx)\right)\right)$$
$$=\int\sqrt{tanx}(dx)+\int\sqrt{cotx}(dx)$$
this basically lead me back to the beginning:(

Attempt2:
I also tried using a the substitution, ##t^2 = tan(x)## but even this brought me back to where I started,
$$\int \sqrt{tanx}+\frac{1}{\sqrt{tanx}} (dx) = \int\frac{tanx+1}{\sqrt{tanx}}(dx)$$
using the above sub,
$$\int\frac{t^2+1}{t}\frac{2t}{1+t^4}(dt) = 2\int\frac{t^2+1}{t^4+1}dt$$
now ##u=t^2##
$$=\int\frac{u+1}{u^2+1}\frac{du}{\sqrt{u}}=\int\frac{\sqrt{u}}{u^2+1}+\frac{1}{\sqrt{u}(u^2+1)}(du)$$
and finally if you use the trig sub, ##u = tan\theta## you end up with,
$$=\int \sqrt{tan\theta}+\sqrt{cot\theta}(d\theta)$$
I usually don't like asking for help while solving integrals, there is a different satisfaction one gets when they finally get the "aha" moment and then solve the problem, but these are literally getting in the way of my life, I don't want entire solutions, a hint or a reassurance that I am thinking in the right direction will do :)

I need help in these two as well, but I'll show my working for them once I get this pesky one out of the way.

$$2. \int \frac{1}{x^{1/2} + x^{1/3}} (dx)$$
$$3. \int \frac{cos(2x) - sin(2\phi)}{cos(x) - sin(\phi)} (dx)$$

Last edited:
• Joshy

Homework Helper
Gold Member
2022 Award
Attempt2:
I also tried using a the substitution, ##t^2 = tan(x)## but even this brought me back to where I started,
$$\int\frac{t^2+1}{t}\frac{2t}{1+t^4}(dt) = 2\int\frac{t^2+1}{t^4+1}dt$$
This looks like progress.
and finally if you use the trig sub, ##u = tan\theta##
That takes you back to square one - you've undone your first substitution.

• Physics Slayer
Homework Helper
Gold Member
2022 Award
Instead:$$\int\frac{t^2+1}{t^4+1}dt = \int\frac{t^2}{t^4+1}dt + \int\frac{1}{t^4+1}dt$$

Homework Helper
Gold Member
2022 Award
Instead:$$\int\frac{t^2+1}{t^4+1}dt = \int\frac{t^2}{t^4+1}dt + \int\frac{1}{t^4+1}dt$$
On second thoughts, perhaps that's not such a good idea.

Physics Slayer
On second thoughts, perhaps that's not such a good idea.
I thought about this, but the only think I could think of was the substitution ##u=t^2## so I could get rid of ##t^4## in the denominators, but the integral was still challenging to solve.

Homework Helper
Gold Member
2022 Award
I thought about this, but the only think I could think of was the substitution ##u=t^2## so I could get rid of ##t^4## in the denominators, but the integral was still challenging to solve.
$$t^4 +1 = (t^2 + \sqrt 2 t +1)(t^2 - \sqrt 2 t +1)$$

• Physics Slayer
Physics Slayer
$$t^4 +1 = (t^2 + \sqrt 2 t +1)(t^2 - \sqrt 2 t +1)$$
$$2\int\frac{t^2+1}{t^4+1}(dt) = \int\frac{2t^2+2}{(t^2+\sqrt{2}t+1)(t^2-\sqrt{2}t+1)}(dt)$$
$$\int\frac{(t^2+\sqrt{t}+1)+(t^2-\sqrt{2}t+1)}{(t^2+\sqrt{2}t+1)(t^2-\sqrt{2}t+1)}(dt)=\int\frac{1}{t^2+\sqrt{2}t+1}+\frac{1}{t^2-2\sqrt{t}+1}(dt)$$
$$\int \frac{1}{(t + \frac{1}{\sqrt{2}})^2 + (\frac{1}{\sqrt{2}})^2} + \frac{1}{(t - \frac{1}{\sqrt{2}})^2 + (\frac{1}{\sqrt{2}})^2} (dt)$$
we can use,
$$\int\frac{1}{x^2+a^2}dx = \frac{1}{a}tan^{-1}\left(\frac{x}{a}\right)$$
finally my ans is,
$$\sqrt{2}\left[tan^{-1}(\sqrt{2tanx}+1) + tan^{-1}(\sqrt{2tanx}-1)\right] +C$$

how were you able to factor ##(t^4+1)## into ##(t^2 -\sqrt{2}t + 1)(t^2 + \sqrt{2}t + 1)## ?
It's obviously correct(I only know because I multiplied the two and verified) but what method did you use?

Homework Helper
Gold Member
2022 Award
how were you able to factor ##(t^4+1)## into ##(t^2 -\sqrt{2}t + 1)(t^2 + \sqrt{2}t + 1)## ?
It's obviously correct(I only know because I multiplied the two and verified) but what method did you use?
I've seen that sort of thing before. I was actually looking at complex numbers first:
$$t^4 + 1 = (t^2 + i)(t^2 - i)$$but then I remembered that you can factorise a quartic into two quadratics.

• Physics Slayer
Homework Helper
Gold Member
2022 Award
I've seen that sort of thing before. I was actually looking at complex numbers first:
$$t^4 + 1 = (t^2 + i)(t^2 - i)$$but then I remembered that you can factorise a quartic into two quadratics.
You can keep going with the complex numbers:
$$t^4 + 1 = (t + \frac{1}{\sqrt 2} +\frac{i}{\sqrt 2})(t + \frac{1}{\sqrt 2} - \frac{i}{\sqrt 2})(t - \frac{1}{\sqrt 2} +\frac{i}{\sqrt 2})(t - \frac{1}{\sqrt 2} - \frac{i}{\sqrt 2})$$$$= (t^2 +\sqrt 2 t +1)(t^2 - \sqrt 2 t +1)$$Or, simply look for$$t^4 +1 = (t^2 + at +1)(t^2 + bt + 1)$$

Last edited:
• Joshy
Physics Slayer
I've seen that sort of thing before. I was actually looking at complex numbers first:
$$t^4 + 1 = (t^2 + i)(t^2 - i)$$but then I remembered that you can factorise a quartic into two quadratics.
we haven't yet studied complex numbers, so I doubt this was the method they expected us to use. Either way, thanks for your help Perok.

If anybody is able to find a soln. without factorising a quartic, do let me know Homework Helper
Gold Member
2022 Award
If anybody is able to find a soln. without factorising a quartic, do let me know It's definitely the way to go. Factorise then partial fractions.

• Physics Slayer
Homework Helper
Gold Member
2022 Award
If anybody is able to find a soln. without factorising a quartic, do let me know If you can cope with the language, see:

• PeroK and Physics Slayer
Physics Slayer
If you can cope with the language, see:

I'm Indian so I don't mind the heavy accent,
I usually don't search up integrals because they directly slap you with the answer, and I don't like that.
thanks for the video tho :)

Homework Helper
Gold Member
2022 Award
I'm Indian so I don't mind the heavy accent,
I usually don't search up integrals because they directly slap you with the answer, and I don't like that.
thanks for the video tho :)
Being a bit pedantic, can I add that both the integral in Post #1 and the integral at the start of the video are incorrect (brackets)!

The integral should, of course, be:$$\int (\sqrt{tanx} + \sqrt{cotx} )dx$$

Physics Slayer
Being a bit pedantic, can I add that both the integral in Post #1 and the integral at the start of the video are incorrect (brackets)!

The integral should, of course, be:$$\int (\sqrt{tanx} + \sqrt{cotx} )dx$$
As far as I am aware, the notation for a indefinite integral is,
$$\int f(x)dx$$
In #1, ##f(x) = \sqrt{tanx}+\sqrt{cotx}## so I don't really see what's wrong

Homework Helper
Gold Member
2022 Award
As far as I am aware, the notation for a indefinite integral is,
$$\int f(x)dx$$
Agreed.

In #1, ##f(x) = \sqrt{tanx}+\sqrt{cotx}## so I don't really see what's wrong
Maybe it's just the convention I was taught. But I would argue that if
##f(x) = \sqrt{tanx}+\sqrt{cotx}##
then in general
##f(x). a## should be be written as
##(\sqrt{tanx}+\sqrt{cotx}).a## and not as
##\sqrt{tanx}+\sqrt{cotx}.a##
because ##\sqrt{tanx}## would not get be multiplied by ##a##. (For example 1+2*3 = 7, not 9.)

This should apply whatever'##a##' is, even if it is the infinitessimal quantity ##dx##.

• vela and Physics Slayer
Physics Slayer
$$2. \int\frac{1}{x^{1/2}+x^{1/3}} dx$$
I tried both the substitutions, ##u^2=x## and ##u^3=x## and both lead to integrals I am unable to solve,

##u^2=x##
$$\int\frac{2u}{u+u^{2/3}}(du) = 2\int\frac{1}{1+u^{-1/3}}(du)=2\int\frac{u^{1/3}}{u^{1/3}+1}(du)$$
now I use the substitution ##u=t^3##
$$2\int\frac{t}{t+1}(3t^2)(dt) = 6\int\frac{t^3}{t+1}(dt)$$
I am unable to solve this final integral. I tried applying Integration by parts consecutively 3 times to get rid of the ##t^3##, but that didn't work either.

using the other substitution(##u^3=x##) I end up with,
$$3\int\frac{u^2}{u^{3/2}+u} (du) = 3\int\frac{u}{\sqrt{u}+1}(du)$$
which is again a integral I can't solve.

Last edited:
Staff Emeritus
Homework Helper
Gold Member
I need help in these two as well, but I'll show my working for them once I get this pesky one out of the way.

$$2. \int \frac{1}{x^{1/2} + x^{1/3}} (dx)$$
$$3. \int \frac{cos(2x) - sin(2\phi)}{cos(x) - sin(\phi)} (dx)$$

• Physics Slayer
Homework Helper
Gold Member
2022 Award
Why not ##x = u^6##?

Physics Slayer
Why not ##x = u^6##?
actually in my attempt, I first use the substitution ##x=u^2## and then the substitution ##u=t^3## which is equivalent to a single substitution ##x=t^3##

But I was since then able to solve the integral, I just had to reduce the final improper fraction into a proper fraction, it was smooth sailing from there, again thanks for you help.

$$6\int\frac{t^3}{t+1}(dt) = 6\int\frac{(t+1)(t^2-t+1)-1}{t+1}(dt)=6\int\left((t^2-t+1)-\frac{1}{t+1}\right)(dt)$$
$$=6\left(\frac{t^3}{3}-\frac{t^2}{2}+t-ln|t+1|\right)=2x^{1/2}-3x^{1/3}+6x^{1/6}-6ln|x^{1/6}+1|+C$$

I thought multiple posts each with a single integral problem, would appear kind of spammy, I will most definitely encounter much harder integrals as I go ahead, I don't want to flood the forum with threads on integrals, but if that's what's supposed to be done, then I shall.

Last edited:
Staff Emeritus
Homework Helper
Gold Member
actually in my attempt, I first use the substitution ##x=u^2## and then the substitution ##u=t^3## which is equivalent to a single substitution ##x=t^3##

But I was since then able to solve the integral, I just had to reduce the final improper fraction into a proper fraction, it was smooth sailing from there, again thanks for you help.

$$6\int\frac{t^3}{t+1}(dt) = 6\int\frac{(t+1)(t^2-t+1)-1}{t+1}(dt)=6\int\left((t^2-t+1)-\frac{1}{t+1}\right)(dt)$$
$$=6\left(\frac{t^3}{3}-\frac{t^2}{2}+t-ln|t+1|\right)=2x^{1/2}-3x^{1/3}+6x^{1/6}-6ln|x^{1/6}+1|+C$$

I thought multiple posts on just one integral would appear kind of spammy, I will most definitely encounter much harder integrals as I go ahead, I don't want to flood the forum with threads on integrals, but if that's what's supposed to be done, then I shall.
It looks to me that those two integrals I referred to are entirely different from the first one.

Physics Slayer
It looks to me that those two integrals I referred to are entirely different from the first one.
yes they are indeed entirely different, they are three different problems(integrals), what I was trying to say was Three threads(+) each discussing only one integral might be a little spammy, hence I thought it would be better to discuss most of them here, but if that's not allowed then I shall start a new thread.

• PeroK
Staff Emeritus
Homework Helper
Gold Member
Or, simply look for$$t^4 +1 = (t^2 + at +1)(t^2 +bt + 1)$$
@Physics Slayer :
Back to problem #1.

The above quote is from Post #9 by PeroK (with a minor but important Typo fixed).

Expand the right hand side and equate corresponding coefficients.

##t^4+1 = (t^2 + at +1)(t^2 +bt + 1)##

##t^4+1=t^4+(a+b)t^3+(2+ab)t^2+(a+b)t+1##

The cubic terms (also the linear terms) give you that ##\ 0 = a+b\ .\ ## Thus ##b=-a## .

The quadratic terms give you that ##0=2+ab\ .\ ## Together with the previous you get ##a^2=2.##

Thus ##a=\pm\sqrt{2 \,} ## .

• jim mcnamara and Physics Slayer