# Thread: solving limit using taylor series..

1. ## solving limit using taylor series..

$
\lim _{x->0} \frac{cos(xe^x)-cos(xe^{-x})}{x^3}\\
$

$
e^x=1+x+O(x^2)\\
$

$
e^{-x}=1-x+O(x^2)\\
$

$
xe^x=x+O(x^2)\\
$

$
cos(x)=1-\frac{1}{2!}x^2+O(x^3)\\
$

$
\lim_{x->0} \frac{1-\frac{1}{2!}(x+O(x^2))^2+O(x^3)-1+\frac{1}{2!}(x+O(x^2))^2+O(x^3)}{x^3}
$

but i dont know how to deal with the remainders
there squaring of them etc..

??

2. Apply L'Hopital a few times.

You will get limit x-> 0

(1/6)*((-3*E^x*(-2 + x)*(-1 + x)*Cos[x/E^x] -
3*E^(5*x)*(1 + x)*(2 + x)*Cos[E^x*x] -
E^(2*x)*(-3 + x)*Sin[x/E^x] + (-1 + x)^3*Sin[x/E^x] +
E^(6*x)*(1 + x)^3*Sin[E^x*x] - E^(4*x)*(3 + x)*Sin[E^x*x])/E^(3*x))

= -2

3. i know that i can solve it with lhopital..
but i want to solve it by the way i showed..

4. The nice thing about taking a limit at zero in this case is you don't need to worry about the remainders because as you approach zero the series is exact to any order you want.

So, take 3rd order:

$\lim _{x->0} cos(xe^x) = \lim _{x->0} 1-\frac{x^2}{2}-x^3$

No remainder because this is exact at limit x-> 0

Similarly:

$\lim _{x->0} cos(xe^{-x}) = \lim _{x->0} 1-\frac{x^2}{2}+x^3$

Then, $\lim _{x->0} cos(xe^x) - cos(xe^{-x}) = \lim _{x->0} -2x^{3}$

Then,

$
\lim _{x->0} \frac{cos(xe^x)-cos(xe^{-x})}{x^3} = \lim _{x->0} \frac {-2x^{3}} {x^{3}} = -2
$

5. i dont want to use the x->0 in the middle of process

i want to turn the last expression that i got
$
\lim_{x->0} \frac{1-\frac{1}{2!}(x+O(x^2))^2+O(x^3)-1+\frac{1}{2!}(x+O(x^2))^2+O(x^3)}{x^3}
$

into 1 O() expression..

6. i tried to solve it again
$
\lim _{x->0} \frac{cos(xe^x)-cos(xe^{-x})}{x^3}\\
$

$
e^x=1+x+O(x^2)\\
$

$
e^{-x}=1-x+O(x^2)\\
$

$
xe^x=x+x^2+O(x^2)
$

$
xe^{-x}=x-x^2+O(x^2)
$

$
cos(x)=1-\frac{1}{2!}x^2+O(x^3)\\
$

$
\lim_{x->0} \frac{1-\frac{1}{2!}(x+x^2+O(x^2))^2+O(x^3)-1+\frac{1}{2!}(x-x^2+O(x^2))^2+O(x^3)}{x^3}=\\
$

$
=\lim_{x->0} \frac{1-\frac{1}{2!}(x^2+O(x^2))+O(x^3)-1+\frac{1}{2!}(x^2+O(x^2))+O(x^3)}{x^3}=0\\
$