2
$\begingroup$

Suppose you a function $f(x)=1/x+x^2$. At large values of $x$, it is closely approximated by $f(x)=x^2$.

Can Mathematica do this for me for a more complicated function? How would I input the command?

$\endgroup$
8
$\begingroup$

Take a series around infinity, dropping all $1/x^n$ terms.

Series[1/x + x^2, {x, \[Infinity], 0}]
(* x^2+O[1/x]^1 *)

Use Normal to obtain an ordinary expression from the SeriesData object.

A slightly more complicated example: the hyperbola represented by $\sqrt{x^2-1}$ has asymptote $y=x$ for positive $x$; so we get:

Normal@Series[Sqrt[x^2 - 1], {x, \[Infinity], 0}]
(* x *)
$\endgroup$
1
$\begingroup$

If you want to keep the function as it is without converting to series than you may try this:

1/x + x^2 /. (y_ /; (Limit[y, x -> \[Infinity]] == 0) :> 0)
(*x^2*)
Sin[x] + 1/x /. (y_ /; (Limit[y, x -> \[Infinity]] == 0) :> 0)
(*Sin[x]*)

You may also find this link useful (here)

$\endgroup$
  • $\begingroup$ Note that this fails in cases like Sqrt[x^2-1] or x^2/(1+x^2), resulting in no simplification, and zero, respectively, i.e. It only handles cases where the decaying terms are totally separated already. $\endgroup$ – 2012rcampion Feb 10 '15 at 20:34

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.