Application Center - Maplesoft

App Preview:

Calculus I: Complete Set of Lessons

You can switch back to the summary page by clicking here.

Learn about Maple
Download Application


 

L1-Limits.mws

Calculus I

Lesson 1: Limits

We have seen that the limit limit((f(x+h)-f(x))/h,h = 0) gives the instantaneous rate of change of the function f at x . In computing this limit, the point x is fixed, we think of the difference quotient as a function of h , and we ask how it behaves when h is close to 0. Of course, we cannot actually put h = 0 , for then the quotient would be undefined. Taking the limit as proc (h) options operator, arrow; 0 end proc is not the same as substituting h = 0 . In this worksheet, we will explore the idea of limit in general; in later worksheets, we will come back to the special type of limit above. We say a function f , defined in some interval around a point a , but not necessarily at a itself, has a limit L as x approaches a , written

limit(f(x),x = a) = L ,

if we can make f(x) as close to L as we like by taking x sufficiently close to (but not equal to) a . (This is a good enough definition to get started; we will see a more precise one later on.)

Lets look at limits from a geometric point of view. The concept of limits can seem difficult, but the idea is quite simple when you see what is happening geometrically. We will construct a diagram which shows a function and points approaching from the left and right.

> restart; with(plots):

Warning, the name changecoords has been redefined

> f := x -> 3 + (x-2)*cos((x-2)); a := 2: left := -1: right :=5:

f := proc (x) options operator, arrow; 3+(x-2)*cos(...

> display( plot( f(x), x = left..right, color = green),
plot( {[[a,0],[a,f(a)]],[[0,f(a)],[a,f(a)]] }, x = left..right,
linestyle=3,color = gold, thickness = 2),
plot([[ a - 1/n, f(a - 1/n)] $n=1..20], x = left..right,
style=point, symbol=circle, color = red),
plot( [[ a+1/n, f(a + 1/n)] $n=1..20], x = left..right,
style=point, symbol=circle, color = blue));

[Maple Plot]

The green curve is the function. The yellow lines indicate where (a,f(a)) is. The blue dots indicate points on f(x) as x approaches a from the right, and the green dots indicate points on f(x) where x is converging to a from the left side. By looking at this diagram, you can guess the right limit by looking at what y value the points seem to be converging to. In a similar way, you can guess the left limit by looking at what value the red dots seem to be converging to. If the red and blue dots appear to be converging to the same value, then the limit exists and equals the value they are converging to.

Here is another example where the function is left and right limits are not the same. After re-defining f(x), copy and paste the display command block above and re-execute.

> f := x -> Heaviside(x-1) - Heaviside(1-x); a := 1: left := -2: right :=4:

f := proc (x) options operator, arrow; Heaviside(x-...

> display( plot( f(x), x = left..right, color = green, discont=true),
plot( {[[a,0],[a,f(a)]],[[0,f(a)],[a,f(a)]] }, x = left..right,
linestyle=3,color = gold, thickness = 2),
plot([[ a - 1/n, f(a - 1/n)] $n=1..20], x = left..right,
style=point, symbol=circle, color = red),
plot( [[ a+1/n, f(a + 1/n)] $n=1..20], x = left..right,
style=point, symbol=circle, color = blue));

[Maple Plot]

In this case, the function is not continuous. It has a jump at x = 1. The red points coming from the left approach -1 while the blue points approaching from the right approach +1. In this case we say that the limit is undefined since there is not a single value for the limit.

Here are some more example functions. For each of them, do the following:

(1) guess whether or not the function has a limit at the indicated point a and try evaluating f(a). ( In most cases, this will not work. )

(2) check (or formulate) your guess numerically by evaluating the function at several points close to a ;

(3) graph the function and confirm that the graph has the expected behaviour near x = a .

(4) use Maple to evaluate the limit of f(x) as x approaches a .

> f := x-> (x-1)/(x^2 - 1) ;
a := 1;

f := proc (x) options operator, arrow; (x-1)/(x^2-1...

a := 1

> f(a);

Error, (in f) numeric exception: division by zero

> plot( f(x), x=a-1..a+1);

[Maple Plot]

> limit(f(x), x=a);

1/2

> f := x-> sin(x)/x ;
a := 0;

f := proc (x) options operator, arrow; sin(x)/x end...

a := 0

> f(a);

Error, (in f) numeric exception: division by zero

> plot( f(x), x=a-5..a+5);

[Maple Plot]

> limit(f(x), x=a);

1

> f := x-> (1 - cos(x))/x ;
a := 0;

f := proc (x) options operator, arrow; (1-cos(x))/x...

a := 0

> f(a);

Error, (in f) numeric exception: division by zero

> plot( f(x), x=a-5..a+5);

[Maple Plot]

> limit(f(x), x=a);

0

> f := x-> (1 - cos(x))/x^2 ;
a := 0;

f := proc (x) options operator, arrow; (1-cos(x))/x...

a := 0

> f(a);

Error, (in f) numeric exception: division by zero

> plot( f(x), x=a-5..a+5);

[Maple Plot]

> limit(f(x), x=a);

1/2

> f := x-> if (x<0) then 0 else 1 fi:
a := 0;

a := 0

> f(a);

1

> plot( f, -1..1);

[Maple Plot]

> f := x-> piecewise(x<=2, x^2, 6-x);
a := 2;

f := proc (x) options operator, arrow; piecewise(x ...

a := 2

> f(a);

4

> plot( f, -3..7, discont=true);

[Maple Plot]

> limit(f(x), x=2, right);

Error, (in limit) directional argument ('left', 'right', 'real' or 'complex') needs to be quoted

> f := x-> sin(Pi/x) ;
a := 0;

f := proc (x) options operator, arrow; sin(Pi/x) en...

a := 0

> f(a);

Error, (in f) numeric exception: division by zero

> plot( f(x), x=a-5..a+5);

[Maple Plot]

> limit(f(x), x=a);

-1 .. 1

> f := x-> abs(x+1)/(x+1) ;
a := -1;

f := proc (x) options operator, arrow; abs(x+1)/(x+...

a := -1

> plot( f(x), x=a-5..a+5, discont=true);

[Maple Plot]

> limit(f(x), x=a);

undefined

> f := x-> abs(x+1)^3/(x+1) ;
a := -1;

f := proc (x) options operator, arrow; abs(x+1)^3/(...

a := -1

> f(a);

Error, (in f) numeric exception: division by zero

> plot( f(x), x=a-5..a+5);

[Maple Plot]

> limit(f(x), x=a);

0

> f := x-> x*sin(1/x) ; a := 0;

f := proc (x) options operator, arrow; x*sin(1/x) e...

a := 0

> f(a);

Error, (in f) numeric exception: division by zero

> plot( f(x), x=a-5..a+5);

[Maple Plot]

> limit(f(x), x=a);

0

>

>