Search code examples
solversagemaxima

Output of solve in maxima and sage have x on both side


I am trying to solve equation

sqrt(x)==sqrt(20*(1500-x))

in sage and getting the output as given bellow,

sqrt(x) == sqrt(-20*x + 30000)

Problem in the above solution is that there is x in both side. How can I solve this kind of question sot that I get proper solution. I have tried the same problem in maxima also and getting same answer.


Solution

  • There are a few options in Sage with solve, and this one seems to help (I assume the answer is okay).

    sage: solve(sqrt(x)==sqrt(20*(1500-x)),x,to_poly_solve=True)
    [x == (10000/7)]