Note that both sides are non-negative, being the sums of non-negative square roots. So squaring both sides will not introduce spurious solutions.
So square both sides to get:
9x+40 = (x+5) + 2sqrt(x+5)sqrt(x+15)+(x+15)9x+40=(x+5)+2√x+5√x+15+(x+15)
=2x+20+2sqrt(x^2+20x+75)=2x+20+2√x2+20x+75
Subtract 2x+202x+20 from both ends to get:
7x+20 = 2sqrt(x^2+20x+75)7x+20=2√x2+20x+75
Note that a valid solution will require 7x + 20 >= 07x+20≥0.
Square both sides (which may introduce extraneous solutions with 7x+20 < 07x+20<0) to get:
49x^2+280x+400 = 4x^2+80x+30049x2+280x+400=4x2+80x+300
Subtract the right hand side from the left to get:
45x^2+200x+100 = 045x2+200x+100=0
Divide through by 55 to get:
9x^2+40x+20 = 09x2+40x+20=0
Solve using the quadratic formula:
x = (-40+-sqrt(40^2-(4xx9xx20)))/(2*9)x=−40±√402−(4×9×20)2⋅9
=(-40+-sqrt(1600-720))/18=−40±√1600−72018
=(-40+-sqrt(880))/18=−40±√88018
=(-40+-sqrt(16*55))/18=−40±√16⋅5518
=(-40+-4sqrt(55))/18=−40±4√5518
=(-20+-2sqrt(55))/9=−20±2√559
(-20-2sqrt(55))/9 ~= -3.870−20−2√559≅−3.870
7(-3.870)+20 < 07(−3.870)+20<0 so this solution is spurious.
(-20+2sqrt(55))/9 ~= -0.574−20+2√559≅−0.574
7(-0.574)+20 > 07(−0.574)+20>0 so this solution is valid.