I'm curently try to implement a little tutorial concerning limits.
On this stage I'm trying to explain inifnite limits, solved by factoring.
For example, lim x->oo (sqrt(x^2+x))/(2x+5)=(xsqrt(1+1/x))/(x(2+5/x))=sqrt(1+0)/(2+5)=1/2
So, basically, I need to extract highest power from expression and divide by it.
The problem is that I don't know how to do it in general (assume there are no functions at all).
Is there similar function in sympy module or it is not trivial task?
It is easy to do it for rational functions, but things go harder for expressions like (x*sqrt(x-2)-5)(x(x-2)^(3/2)).
Perhaps, I need to combine x*sqrt(x-2) into sqrt(x^3-2x^2) (again how).
Any help will be highly appreciated.
Thanks in advance.