Calculus I
Lesson 2: Continuity and Limits at Infinity I
Example 1 For the following function, find the value of a that makes the function continuous.
Plot the continuous function. Then take different values of the variable a and
plot the associated discontinuous functions.
for x <= 2 and for x > 2
> restart:
Define the two pieces
> f1 := x->a*x; f2 := x->a*x^2+x+1;
Substitute the break point x=2 into both functions, set them equal, and then solve for a:
> a := solve(f1(2)=f2(2), a);
> f1(x); f2(x);
Plot the function.
> f:= x -> piecewise( x <= 2, f1(x), f2(x));
> plot(f(x), x = -5..5);
What if we'd gotten a wrong? Suppose we thought a = -4.
> a := -4;
Plot the (discontinuous) function.
> plot(f(x), x = -5..5, discont=true);
Example 2
Plot the graph of the following function.
Where is the function discontinuous?
q(t) = 0 for t < -4
= for -4 <= t <= -2
= for -2 < t <= 1
= for 1 < t <= 6
= 7 for t > 6
> c:= x -> piecewise( x < -4, 0, -4 <= x and x <= -2, 4*x + 16, -2 < x and x <= 1, 2*x^2, 1 < x and x <= 6, 5 * sqrt(x + 3) - 8, 7);
> plot(c(x),x= -5..7, discont=true, color=magenta);
answer: Function is continuous everywhere; no discontinuity.
Example 3 For each of the following functions:
(i) Plot each function for large vlaues of x.
(ii) Use the plot to conjecture the limitof the function as x goes to
(iii) Determine precisely the limit of the function as x goes to .
a)
b)
c)
> e:= ( ( 1+x)/x )* sin(x);
> plot(e(x), x = 100..200);
> limit((( 1+x)/x)* sin(x), x = infinity);
limit of e(x) as x goes to DNE, since the function oscillates between 1 and -1.
> f:= ( 1/(sqrt(x)) * sin(x));
> plot(f(x), x = 1000..2000, numpoints=1000);
> limit(( 1/(sqrt(x)) * sin(x)), x = infinity);
> g:= (2*x^3 + 7*x)/(x^2);
> plot(g(x), x= 1000..2000);
> limit((2*x^3 + 7*x)/(x^2), x = infinity);
Example 4 A hot piece of steel which is 94 degrees C is placed in a room that is kept at a constant temperature
of 20 degrees C. The steel begins to cool, and has its temperature t minutes after being placed in
the room given by: .
a) Graph T(t)
b) How long till the steel reaches 22 degrees?
c) How long till the steel reaches 21 degrees?
d) What will be the ultimate temp of the steel?
> T:= 20 + 74 * exp( ln(.4)*x/40 );
> plot(T(x), x =0..200 );
> limit(20 + 74 * exp( ln(.4)*x)/40 ), x = infinity);
> eq:= 20 + 74 * exp(( (ln(.4)*x)/40 ) )= 22;
> solve(eq,x);
> eq:= 20 + 74 * exp(( (ln(.4)*x)/40 ) )= 21;
> solve(eq);
It takes approximately 157 minutes to reach 22 F and 187 minutes to reach 21F. The limiting
temp is 20F.
Example 5 Use Maple's limit command to find each of the following limits.
d)
e)
> limit( (3 ^x -1)/x, x = 0);
> limit( ( 2 - 2^x)/(4^x - 4), x = 1);
> limit((1 - cos(x))/(x^2),x = 0);
> limit( (x - sin(x))/(x^3), x = 0);
> limit( ( 1 + x)^(1/x), x = 0);
Example 6 Plot each of the following:
In each case, plot the asymptotic curves on the same axes with different color.
> plot( [(x^3 - 3)/x, x^2], x= 1..10, color=[green,magenta]);
Asymptotic curve is
> plot([ (1 + 2*x - x^4)/(x^2), -x^2], x = 1..10, color=[green, magenta]);
Example 7
f(x) = x -3 for x > 0
= 5 for x = 0
= for x < 0
Plot f(f(x)) and find limit f(f(x)) as x goes to 0 with ` limit ' command.
> z:= x -> piecewise( x > 0, x-3, x = 0, 5, x^2 + 4*x - 1);
> plot(z(x), x = -5..5, discont=true, color=brown);
> plot(z(z(x)), x = -5..5, discont=true, color=brown);
> limit(z(z(x)), x = 0);
Example 8 Find all asymptotes for . Graph f(x) and
all asymptotes on the same axes with different color.
> plot([(3*x^3 - 4*x^2 - 2*x + 5)/(x^2 - 1), 3*x - 4], x = -4..4, color=[red, green], thickness=2);
> plot([(3*x^3 - 4*x^2 - 2*x + 5)/(x^2 - 1), 3*x - 4], x = 1.5..10, color=[red, green], thickness=2);