









































































Study with the several resources on Docsity
Earn points by helping other students or get them with a premium plan
This page cannot be seen from the preview
Don't miss anything!










































































Math 1A: introduction to functions and calculus Oliver Knill, 2012
Calculus formalizes the process of taking differences and taking sums. Differences measure change, sums explore how things accumulate. The process of taking differences has a limit called derivative. The process of taking sums will lead to the integral. These two pro- cesses are related in an intimate way. In this first lecture, we look at these two processes in the simplest possible setup, where functions are evaluated only on integers and where we do not take any limits. About 25’000 years ago, numbers were represented by units like
1 , 1 , 1 , 1 , 1 , 1 ,...
for example carved in the fibula bone of a baboon^1. It took thousands of years until numbers were represented with symbols like today 0 , 1 , 2 , 3 , 4 ,....
Using the modern concept of function, we can say f (0) = 0, f (1) = 1, f (2) = 2, f (3) = 3 and mean that the function f assigns to an input like 1001 an output like f (1001) = 1001. Lets call Df (n) = f (n + 1) − f (n) the difference between two function values. We see that the function f satisfies Df (n) = 1 for all n. We can also formalize the summation process. If g(n) = 1 is the function which is constant 1, then Sg(n) = g(0) + g(1) +... + g(n − 1) = 1 + 1 + ... + 1 = n. We see that Df = g and Sg = f. Now lets start with f (n) = n and apply summation on that function: Sf (n) = f (0) + f (1) + f (2) +... + f (n − 1).
In our case, we get the following values:
0 , 1 , 3 , 6 , 10 , 15 , 21 ,....
The new function g satisfies g(1) = 1, g(2) = 3, g(2) = 6, etc. These numbers are called triangular numbers. From the function g we can get f back by taking difference:
Dg(n) = g(n + 1) − g(n) = f (n).
For example Dg(5) = g(6) − g(5) = 15 − 10 = 5 which indeed is f (5). Finding a formula for the sum Sf (n) is not so easy. Can you do it? When Karl-Friedrich Gauss was a 9 year old school kid, his teacher, Mr. B¨uttner gave him the task to sum up the first 100 numbers 1+2+· · ·+100. Gauss found the answer immediately by pair- ing things up: to add up 1+2+3+.. .+100 he would write this as (1+100)+(2+99)+· · ·+(50+51) leading to 50 terms of 101 to get for n = 101 the value g(n) = n(n − 1)/2 = 5050. Taking differ- ences again is easier Dg(n) = n(n + 1)/ 2 − n(n − 1)/2 = n = f (n).
(^1) This is the Ishango bone. The lengths of the marks could also have some astronomical significance but this is not relevant here
Lets add up the new sequence again and compute h = Sg. We get the sequence 0 , 1 , 4 , 10 , 20 , 35 , ...
These numbers are called the tetrahedral numbers because one use h(n) balls to build a tetrahedron of side length n. For example, we need h(4) = 20 golf balls for example to build a tetrahedron of side length 4. The formula which holds for h is h(n) = n(n − 1)(n − 2)/ 6. We see (see worksheet) that summing the differences gives the function in the same way as differencing the sum:
SDf (n) = f (n) − f (0), DSf (n) = f (n)
This is an arithmetic version of the fundamental theorem of calculus. The process of adding up numbers will lead to the integral
∫ (^) x 0 f^ (x)^ dx^.
The process of taking differences will lead to the derivative (^) dxd f (x). Later
in this course, we will encounter the fundamental theorem of calculus ∫ (^) x (^0) dtd f^ (t)^ dt^ =^ f^ (x)^ −^ f^ (0),^ dxd
∫ (^) x 0 f^ (t)^ dt^ =^ f^ (x)
and realize why it is such a fantastic result. You see how well it fits the result for difference and sum. A major goal of this course will be to understand this fundamental theorem result and how we apply it. We have just seen it once and packed the essence of the theorem in the above version with S and D. We will revisit the theorem at least twice again. 2 The above version will lead us. Note that if we define [n]^0 = 1, [n]^1 = n, [n]^2 = n(n − 1)/ 2 , [n]^3 = n(n − 1)(n − 2)/6 then D[n] = [1], D[n]^2 = 2[n], D[n]^3 = 3[n]^2 and in general
d dx [x]
n (^) = n[x]n− 1
We will generalize this from h = 1 to general h > 0 and then see that it also holds in the limit h → 0 where it is the familiar formula (d/dx)xn^ = nxn−^1 you might have seen in high school. The calculus you have just seen, contains the essence of single variable calculus. This core idea will become more powerful and natural if we use it together with the concept of limit.
Problem: The sequence 1, 1 , 2 , 3 , 5 , 8 , 13 , 21 ,... satisfies the rule f (x) = f (x − 1) + f (x − 2). It defines a function on the positive integers. For example, f (6) = 8. What is the function g = Df , if we assume f (0) = 0? Solution: We take the difference between successive numbers and get the sequence of numbers
0 , 1 , 1 , 2 , 3 , 5 , 8 , ...
which is the same sequenc again. We can deduce from this recursion that f has the property that Df (x) = f (x − 1). It is called the Fibonnacci sequence, a sequence of great fame.
compute the function h(n) = Sf (n) obtained by summing the first n numbers up. It gives the sequence 1, 2 , 4 , 7 , 12 , 20 , 33 , .... What sequence is that? Solution: Because Df (x) = f (x − 1) we have f (x) − f (0) = SDf (x) = Sf (x − 1) so that Sf (x) = f (x + 1) − f (1). Summing the Fibonnacci sequence produces the Fibonnacci sequence shifted to the left with f (2) = 1 is subtracted. It has been relatively easy to find the sum, because we knew what the difference operation did. This example shows: (^2) Many textbooks need hundreds of pages until the fundamental theorem is reached.
Find a formula for Sf (n) = f (0) + f (1) + f (2) +... + f (n − 1). For example g(3) = f (0) + f (1) + f (2) = 1 + 3 + 5 = 9.
f (n) = [n]^0 = 1 we have g(n) = Sf (n) = n. f (n) = [n]^1 = n we have g(n) = Sf (n) = n(n − 1)/2. f (n) = [n]^2 = n(n − 1)/ 2 we have g(n) = Sf (n) = n(n − 1)(n − 2)/6.
Verify that if f (n) = n(n − 1)(n − 2)/6 then Sf (n) = n(n − 1)(n − 2)(n − 3)/24 satisfies Dg(n) = f (n). Can you see a pattern?
so, compute successive derivatives g = Df of f , then h = Dg until you see a pattern.
that F (1) = 1, F (2) = 5, F (3) = 14 leading to the sequence of numbers
0 , 1 , 5 , 14 , 30 , 55 , 91 , 140 , 204 , 285 ,....
We have already have computed Sg for g(n) = n(n − 1)/2 as well as Sh for h(n) = n. Try to write f as a combination of g and h and use the addition rule D(h + h) = Dg + Dh.
Df of f and go from there.
Math 1A: introduction to functions and calculus Oliver Knill, 2012
A function is a rule which assigns to a real number a new real number. The function f (x) = x^2 − 2 x for example assigns to the number x = 4 the value 4^2 − 8 = 8. A function is given with a domain A, the points where f is defined and a codomain B a set of numbers which f can reach. The function f (x) = x^2 − 2 x is defined on the entire real axes. While f (x) ≥ −1, the codomain is the set of real numbers.
Typically, the codomain agrees with the set of real numbers and the domain to be all the numbers, where the function is defined. The function f (x) = 1/x for example is not defined at x = 0 so that we chose the domain A = R \ { 0 }, all numbers except 0. The function f (x) = 1/x takes values in the codomain R. If we choose A = B, then f (x) = 1/x reaches every point in B and is invertible. It is its own inverse. Here are a few examples of functions. We will look at them in more detail during the lecture, especially the polynomials, trigonometric functions and exponential function.
identity f (x) = x constant f (x) = 1 linear f (x) = 3x + 1 quadratic f (x) = x^2 cosine f (x) = cos(x) sine f (x) = sin(x) exponentials f (x) = exph(x) = (1 + h)x/h logarithms f (x) = logh(x) = exp− h^1
power f (x) = 2x exponential f (x) = ex^ = exp(x) logarithm f (x) = log(x) = exp−^1 (x) absolute value f (x) = |x| devil comb f (x) = sin(1/x) bell function f (x) = e−x^2 witch of Agnesi f (x) = (^) 1+^1 x 2 sinc sin(x)/x
We can build new functions by:
addition f (x) + g(x) scaling 2 f (x) translate f (x + 1) compose f (g(x)) invert f −^1 (x) difference f (x + 1) − f (x) sum up f (x) + f (x + 1) +...
Here are important functions:
polynomials x^2 + 3x + 5 rational functions (x + 1)/(x^4 + 1) exponential ex logarithm log(x) trig functions sin(x), tan(x) inverse trig functions arcsin−^1 (x), arctan(x). roots
x, x^1 /^3
We will look at these functions a lot during this course. The logarithm, exponential and trigono- metric functions are especially important. For some functions, we need to restrict the domain, where the function is defined. For the square root function
x or the logarithm log(x) for example, we have to assume that the number is positive. We write that the domain is (0, ∞) = R+. For the function f (x) = 1/x, we have to assume that x is different from zero. Keep these three examples in mind.
The graph of a function is the set of points {(x, y) = (x, f (x)) } in the plane, where x runs over the domain A of f. Graphs allow us to visualize functions. We can ”see them”, when we draw the graph.
a) A function is called odd if f (−x) = −f (x). Is f odd? b) A function is called even if f (x) = f (−x). Is f even? c) A function is called monotone increasing if f (y) > f (x) if y > x. Is f monotone increasing? No need to decide this yet analytically. Just draw(∗)^ and decide.
g such that g(f (x)) = x for all x in A and f (g(y)) = y for all y ∈ B. For example, the function g(x) =
x is the inverse of f (x) = x^2 as a function from A = [0, ∞) to B = [0, ∞). Determine from the following functions whether they are invertible. If they are invertible, find the inverse. a) f (x) = cos(x) from A = [0, π/2] to B = [0, 1] b) f (x) = x^5 from A = R to B = R c) f (x) = x^4 from A = R to B = R d) f (x) = exp(2x) from A = R to B = R+^ = (0, ∞). e) f (x) = 1/(1 + x^2 ) from A = [0, ∞) to B = [0, ∞).
a) Draw the graphs of the functions f 1 , f 2 , f 3 on the interval [0, 1]. b) Can you imagine what f 100 (x) looks like? You might want to make more experiments here to see the answer. Of course you are allowed to plot the functions with a calculator ✞with Wolfram alpha or with Mathematica. Plot [ NestList [ ( 7 / 2 ) (# ( 1 − #)) &, x , 3 ] , {x , 0 , 1 } ] ✝ ✆
example, the function f (x) = x^2 + 1 is the composition square root of g(x) = x^4 + 2x^2 + 2 be- cause f (f (x)) = (x^2 +1)^2 +1 = g(x). Find the composition square roots of the following func-
tions:
a) f (x) = cos(cos(x)). b) f (x) = x^4 c) f (x) = x
d) f (x) = x^4 + 2x^2 + 2 e) f (x) = eex.
Note that it can be difficult in general to find the square root function in general. Already for basic functions like exp(x) or sin(x), we are speechless.
zero. Find one root for each of the following functions or state that there is none. a) f (x) = cos(x) b) f (x) = exp(−x^2 ) c) f (x) = x^3 − x
d) f (x) = sin(x) − 1 e) f (x) = csc(x) = 1/ sin(x)
✞(*) Here is how you can use the Web to plot a function. The example given is sin(x). http : / /www. wolframalpha. com/ i n p u t /? i=Plot+s i n ( x ) ✝ ✆
Math 1A: introduction to functions and calculus Oliver Knill, 2012
We have seen that functions like 1/x are not defined everywhere. Sometimes, however, functions do not make sense at first but can nevertheless be saved. A silly example is f (x) = x/x which is apriori not defined at x = 0 because we divide by x but can be ”saved” by noticing that f (x) = 1 for all x different from 0. Functions often can be continued to ”non-allowed” places if we write the function differently. This often involves dividing out a common factor. Lets look at some examples:
to 1, nothing really bad happens. We can evaluate the function at points closer and closer to 1 and get closer and closer to 3. We will say limx→ 1 f (x) = 3. Indeed, as you might have noticed already, we have f (x) = x^2 + x + 1 by factoring out the term (x − 1). While the function was initially not defined at x = 1, we can assign a natural value 3 at the point x = 1 so that the graph continues nicely through that point.
Definition. We write x → a to say that the number x approaches a from either side. A function f (x) has a limit at a point a if there exists b such that f (x) → b for x → a. We write limx→a f (x) = b. It should not matter, whether we approach a from the left or from the right. In both cases, we should get the same limiting value b.
geometrically by comparing the side a = sin(x) of a right angle triangle with a small angle α = x and hypotenuse 1 with the length of the arc between B, C of the unit circle centered at A. The arc has length x which is close to sin(x) for small x. Keep this example in mind. It is a crucial one. The fact that the limit of f (x) exists for x → 0 is some important that it is sometimes called the fundamental theorem of trigonometry.
have to worry about limits, if we deal with polynomials.
defined. We do not have to worry about limits if we deal with trigonometric polynomials like sin(3x) + cos(5x). The function tan(x) however has no limit at x = π/2. No finite value b can be found so that tan(π/2 + h) → b for h → 0. This is due to the fact that cos(x) is zero at π/2. We have tan(x) goes to +∞ ”plus infinity” for x ց π/2 and tan(x) goes to −∞ for x ր π/2. In the first case, we approach π/2 from the right and in the second case from the left.
we have f (x) = 1/10 for x = 1/n^3 the value f (x) is 1/n. The cube root function is defined everywhere on the real line, like f (−8) = −2 and is continuous everywhere. 1
3
If the limit exists, find it. a) f (x) = cos(x)/ cos(2x) b) f (x) = tan(x)/x c) f (x) = (x^2 − x)/(x − 1) d) f (x) = (x^4 − 1)/(x^2 − 1) e) f (x) = (x + 1)/(x − 1) f) f (x) = x/ sin(x) g) f (x) = 5x/ sin(6x) h) f (x) = sin(x)/x^2 i) f (x) = sin(x)/ sin(2x) j) f (x) = exp(x)/x Solutions:
a) There is no problem at all at x = 0. Both, the nominator and denominator converge to
4
fact that sin(x)/x has the limit 1 as x → 0. a) f (x) = (x^2 − 1)/(x − 1) b) f (x) = sin(3x)/x c) f (x) = sin^2 (5x)/x^2 d) f (x) = sin(3x)/ sin(5x)
f (x) =
(1 − cos(x)) x^2
b) Where is the function f defined? Can you find the limit at the places, where it is not defined?
x = 0 for the function f (x) = sin(x)? b) Verify that the function f (x) = exph(x) = (1 + h)x/h^ satisfies [f (x + h) − f (x)]/h = f (x). Remark. The exponential function can be defined as ex^ = exp(x) = limh→ 0 exph(x).
a) f (x) = (x^2 − 2 x + 1)/(x − 1). b) f (x) = 2x. c) f (x) = 2^2 x. d) f (x) = sin(sin(x))/ sin(x).
a limit? Take a calculator or use Wolfram α and experiment. What do you see when x → 0? Only optional: can you find a explanation for your experiments?
Rules: a) If f and g are continuous, then f + g is continuous. b) If f and g are continuous, then f ∗ g is continuous. c) If f and g are continuous and if g > 0 then f /g is continuous. d) If f and g are continuous, then f ◦ g is continuous.
x^2 + 1 is continuous everywhere on the real line.
integer n, we have f (e−n) = −n, this can become arbitrarily large for n → ∞ even so e−n converges to 0 for n running to infinity.
it continuous everywhere?
week that nothing bad happens when h becomes smaller and smaller and that the continuity will not deteriorate. Indeed, we will see that we get closer and closer to the cos function. There are three major reasons, why a function is not continuous at a point: it can jump, oscillate or escape to infinity. Here are the prototype examples. We will look at more during the lecture.
sign x
x
x 1 x x
Why do we like continuity? We will see many reasons during this course but for now lets just say that:
A wild continuous function. This Weierstrass function is believed to be a fractal.
”Continuity tames a func- tion.
It can be pretty wild, but not too crazy.”
A crazy discontinuous function. It is discontinuous at every point and known to be a fractal.
Continuity will be useful later for extremization. A continuous function on an interval [a, b] has a maximum and minimum. And if a continuous function is negative at some place and positive at an other, there is a point between, where it is zero. These are all useful properties to have and they do not hold if a function is not continuous.
a) f (x) = log(|x^2 − 1 |) b) f (x) = sin(cos(π/x)) c) f (x) = cot(x) + tan(x) + x^4 d) f (x) = x^4 + 5x^2 − 3 x + 4 e) f (x) = x^2 − x^4 x Solution. a) log(|x|) is continuous everywhere except at x = 0. Since x^2 − 1 = 0 for x = 1 or x = −1, the function f (x) is continuous everywhere except at x = 1 and x = −1. b) The function π/x is continuous everywhere except at x = 0. Therefore cos(cos(π/x) is continuous everywhere except possibly at x = 0. We have still to investigate the point x = 0 but there, the function cos(π/x) takes values between −1 and 1 for points arbitrarily close to x = 0. The function f (x) takes values between sin(−1) and sin(1) arbitrarily close to x = 0. It is not continuous there. c) The function x^4 is continuous everywhere. The function tan(x) is continuous everywhere except at the points kπ. The function cot(x) is continuous everywhere except at points π/2 + kπ. The function f is therefore continuous everywhere except at the point x = kπ/2, multiples of π/2. d) The function is a polynomial. We know that polynomials are continuous everywhere. e) The function is continuous everywhere except at x = 0, where we have to look at the function more closely. But we can heal the function by dividing nominator and denominator by x which is possible for x different from 0. The healed function is f (x) = x − 4.
Math 1A: introduction to functions and calculus Oliver Knill, 2012
If f (a) = 0, then the value a is called a root of f. The function f (x) = cos(x) for example has the root x = π/2 or x = 3π/2.
1 f (x) = 4x + 6. Find the roots of f. Answer: set the function equal to 0 and solve for x. We get 4x + 6 = 0 2 f (x) = x^2 + 2x+ 1 Find the roots of f. Answer: we can write f (x) = (x+ 1)^2. The function has the root x = −1. 3 f (x) = (x − 2)(x + 6)(x + 3). Find the roots of f. 4 f (x) = 12 + x − 13 x^2 − x^3 + x^4. Find the roots of f. We do not have a formula for this, but we can try. Indeed, we see that for x = 1, x = − 3 , x = 4, x = −1 we have roots. 5 f (x) = exp(x). This function does not have any root. 6 f (x) = 2x^ − 16 has the root x = 2.
Intermediate value theorem of Bolzano. If f is continu- ous on [a, b] and f (a), f (b) have different signs, there is a root of f in (a, b).
Proof. We can assume f (a) < 0 and f (b) > 0. The other case is similar. Look at the point c = (a + b)/2. If f (c) < 0, then look take [c, b] as your new interval, otherwise, take [a, c]. We get a new root problem on a smaller interval. Repeat the procedure. After n steps, the search is narrowed to an interval [un, vn] of size 2−n(b − a). Continuity assures that f (un) − f (vn) → 0 and f (un), f (vn) have different signs. Both un, vn converge to a root of f. 7 The function f (x) = x^17 − x^3 + x^5 + 5x^7 + sin(x) has a root. Solution. The function goes to +∞ for x → ∞ and to −∞ for x → −∞. We have for example f (10000) > 0 and f (−1000000) < 0. The intermediate value theorem assures there is a point where f (x) = 0. 8 There is a solution to the equation xx^ = 10. Solution: for x = 1 we have xx^ = 1 for x = 10 we have xx^ = 10^10 > 10. Apply the intermediate value theorem. 9 There exists a point on the earth, where the temperature is the same as the temperature on its antipode. Solution: Lets draw a meridian through the north and south pole and let f (x) be the temperature on that circle. Define g(x) = f (x) − f (x + π). If this function is zero on the north pole, we have found our point. If not, g(x) different signs on the north and south pole. There exists therefore a point, where the temperature is the same.
Wobbly Table Theorem. On an arbitrary floor, a square table can be turned so that it does not wobble any more.
Why? The 4 legs ABCD are on a square. Let x be the angle of the line AC with with some coordinate axes if we look from above. Given the angle x, we can position the table uniquely as follows: the center of ABCD is on the z-axes, the legs ABC are on the floor and AC points in the direction x. Let f (x) denote the height of the fourth leg D from the ground. If we find an angle x such that f (x) = 0, we have a position where all four legs are on the ground. Assume f (0) is positive. (If it is negative, the argument is similar.) Tilt the table around the line AC so that the two legs B,D have the same vertical distance h from the ground. Now translate the table down by h. This does not change the angle x nor the center of the table. The two previously hovering legs BD now touch the ground and the two others AC are below. Now rotate around BD so that the third leg C is on the ground. The rotations and lowering procedures have not changed the location of the center of the table nor the direction. This position is the same as if we had turned the table by π/2. Therefore f (π/2) < 0. The intermediate value theorem assures that f has a root between 0 and π/2.
Define Df (x) = (f (x+h)−f (x))/h. Lets call it the derivative of f for the constant h. We will study it more in the next lecture. But you have verified for example D exph(x) = exph(x) in a homework.
Lets call a point p, where Df (x) = 0 a critical point for h. Lets call a point a a local maximum if f (a) ≥ f (x) in an open interval containing a. Define similarly a local minimum as a point where f (a) ≤ f (x).
11 The function f (x) = x(x − h)(x − 2 h) has the derivative Df (x) = 3x(x − h) as you have verified in the case h = 1 in the first lecture of this course in a worksheet. We will write [x]^3 = x(x − h)(x − 2 h) and [x]^2 = x(x − h). The computation just done tells that D[x]^3 = 3[x]^2. Since [x]^2 has exactly two roots 0, h, the function [x]^3 has exactly 2 critical points. 12 More generally for [x]n+1^ = x(x − h)(x − 2 h)...(x − nh) we have D[x]n+1^ = (n + 1)D[x]n. Because [x]n^ has exactly n roots, the function [x]n+1^ has exactly n critical points. Keep the formula D[x]n^ = n[x]n−^1 in mind! 13 The function exph(x) = (1 + h)x/h^ satisfies D exph(x) = exph(x). Because this function has no roots and the derivative is the function itself, the function has no critical points. Indeed, this function is monotone.
Figure: We see the function [x]^4 = x(x − h)(x − 2 h)(x − 3 h) with h = 0.5. This function has 3 critical points because D[x]^4 = 4[x]^3 and [x]^3 has roots at 0, h, 2 h. There are three local maxima or minima according to the theorem. Later in the course, we will look at the derivative Df in the limit when h → 0. And then the critical points are places where the tangent is horizontal. In our case now, a critical point is a point so that if we walk by a step h to the right, the function does not change. For now, just remember the formula D[x]n^ = n[x]n−^1. It will be the same formula later on when we go to the limit h → 0. Critical points lead to extrema as we will see later in the course. In our discrete setting we can say:
Fermat’s maximum theorem If f is continuous and has a critical point a for h, then f has either a local maximum or local minimum inside the open interval (a, a + h).
Look at the range of the function f restricted to [a, a + h]. It is a bounded interval [c, d] by the intermediate value theorem. There exists especially a point u for which f (u) = c and a point v for which f (v) = d. These points are different if f is not constant on [a, a + h]. There is therefore one point, where the value is different than f (a). If it is larger, we have a local maximum. If it is smaller we have a local minimum.
14 Problem. Verify that a cubic polynomial has maximally 2 critical points. Solution f (x) = ax^3 + bx^2 + cx + d. Because the x^3 terms cancel in f (x + h) − f (x), this is a quadratic polynomial. It has maximally 2 roots. What we have called ”critical point” here will in the limit h → 0 be called ”critical point” later in this course. While the h-critical point notion makes sense for any continuous func- tion, we will need more regularity to take the limit h → 0. This limit h → 0 will be one of the major features.
1 Find the roots for f (x) = −18 + 9x + 20x^2 − 10 x^3 − 2 x^4 + x^5. You are told that all roots are integers. 2 Use the intermediate value theorem to verify that f (x) = x^5 − 6 x^4 + 8 has at least two roots on [− 2 , 2]. 3 Madonnas height is 161 cm. Lady Gagas height is 155 cm. Gaga was born March 28, 1986, Madonna was born August 16, 1958. Gaga owns probably 0.5 billions, Madonna owns probably 1.3 billion. a) Can you argue that there was a moment when Gaga’s height was exactly half of Madonnas height? b) Can you argue that there was a moment when Gaga’s fortune was exactly a third of Madonnas fortune? c) Can you argue that if you drive the 190 miles from here to New York in 4 hours then there are at least two moments of time when you drive with exactly 40 miles per hours. The trip is not part of a larger trip. Your start is in Boston and your Destination is New York. 4 Argue why there is a solution to a) 1 + cos(x) = x. b) exp(2x) = x. c) sinc(x) = x^4. d) Why does the following argument not work: The function f (x) = 1/ cos(x) satisfies f (0) = 1 and f (π) = −1. There exists therefore a point x where f (x) = 0. e) Does the function f (x) = x + log | log | log |x||| have a root? 5 a) Draw the graph of f (x) = x^3 − x. b) Locate the local maxima and minima. c) Find the critical points of f to the constant h = 1. That means, find the places, where f (x + 1) − f (x) = 0. d) For every point a you have found in c), verify that there is a local maximum or minimum in [a, a + 1].
Math 1A: introduction to functions and calculus Oliver Knill, 2012
Calculus is the theory of differentiation and integration. We explore this still in a discrete setup and practice differentiation and integration. We fix a positive constant h and take differences and sums. Without taking limits, we prove a fundamental theorem of calculus. You can so differentiate and integrate polynomials, exponentials and trigonometric functions. Later we will do the same with real derivatives and integrals. But now, we can work with arbitrary continuous functions.
Given a function f (x), define the differential quotient Df (x) = (f (x + h) − f (x)) (^1) h If f is continuous then Df is a continuous. We call it also ”derivative”.
1 Lets take the constant function f (x) = 5. We get Df (x) = (f (x+h)−f (x))/h = (5−5)/h = 0 everywhere. You can see that in general, if f is a constant function, then Df (x) = 0. 2 f (x) = 3x. We have Df (x) = (f (x + h) − f (x))/h = (3(x + h) − 3 x)/h which is 3. You see in general that if f is a linear function f (x) = ax + b, then Df (x) = a is constant. 3 If f (x) = ax + b, then Df (x) = a.
For constant functions, the derivative is zero. For linear functions, the derivative is the slope.
4 For f (x) = x^2 we compute Df (x) = ((x + h)^2 − x^2 )/h = (2hx + h^2 )/h which is 2 x + h.
Given a function f , define a new function Sf (x) by summing up all values of f (jh), where 0 ≤ jh < x. That is, if k is such that (k − 1)h is the largest below x, then Sf (x) = h[ f (0)+f (h)+f (2h)+· · ·+f ((k −1)h) ] We call Sf also the ”integral” or ”antiderivative” of f.
5 Compute Sf (x) for f (x) = 1. Solution. We have Sf (x) = 0 for x ≤ h, and Sf (x) = h for h ≤ x < 2 h and Sf (x) = 2h for 2h ≤ x < 3 h. In general S1(jh) = j and S1(x) = kh where k is the largest integer such that kh < x. The function g grows linearly but grows in quantized steps.
The difference Df (x) will become the derivative f ′(x). The sum Sf (x) will become the integral ∫^0 x f (t) dt.
Df means rise over run and is close to the slope of the graph of f. Sf means areas of rectangles and is close to the area under the graph of f.
k h (^) x
y
0 h
f Hk h L-f H 0 L
k h
y
0 h
f Hk h L
Theorem: Sum the differences and get SDf (kh) = f (kh) − f (0)
Theorem: Difference the sum and get DSf (kh) = f (kh)
6 For f (x) = [x]mh = x(x − h)(x − 2 h)...(x − mh + h) we have f (x + h) − f (x) = (x(x − h)(x − 2 h)...(x − kh + 2h)) ((x + h) − (x − mh + h)) = [x]m−^1 hm and so D[x]mh = m[x]( hm −1). Lets leave the h away to get the important formula D[x]m^ = m[x]m−^1
We can establish from this differentiation formulas for polynomials. 7 If f (x) = [x] + [x]^3 + 3[x]^5 then Df (x) = 1 + 3[x]^2 + 15[x]^4. The fundamental theorem allows us to integrate and get the right values at the points k/n: 8 Find Sf for the same function. The answer is Sf (x) = [x]^2 /2 + [x]^4 /4 + 3[x]^6 /6.
Define exph(x) = (1 + h)x/h. It is equal to 2x^ for h = 1 and morphs into the function ex^ when h goes to zero. As a rescaled exponential, it is continuous and monotone.
9 You have already computed the derivative in a homework. Lets do it again. The function exph(x) = (1 + h)x/h^ satisfies D exph(x) = exph(x). Solution: exph(x + h) = (1 + h) exp(x) shows that. D exph(x) = exph(x)
10 Define exp(a · x) = (1 + ah)x/h. It satisfies D exph(a · x) = a exph(a · x) We write a dot be- cause exph(ax) is not equal to exph(a · x). What is important to us is only the differentiation rule for this function.
11 If we allow a to become complex, we get exp(1 + ia)(1 + aih)x/h. We still have D expaih (x) = ai expaih (x). Taking real and imaginary parts define new functions expaih (x) = cosh(a · x) + i sinh(a · x). Despite the fact that we have for a moment escaped to the complex, these func- tions exist and morph into the familiar cos and sin functions for h → 0. But in general, for any h > 0 and any a, we have D cosh(a · x) = −a sinh(a · x) and D sinh(a · x) = a cosh(a · x). If h is the size of the Planck constant h = 1. 616 · 10 −^35 m, we would notice a difference be- tween the cos and cosh only if an x-ray traveling for 13 billion years. It would appear as a gamma ray burst.
We leave the h away in this homework. To have more fun, also define logh as the inverse of exph and define 1/[x]h = D logh(x) for x > 0. If we start integrating from 1 instead of 0 as usual we write S 1 f and get S 11 /[x]h = logh(x). We also write here xn^ for [x]nh and write exp(a · x) = ea·x^ instead of expah(x) and log(x) instead of logh(x) because we are among friends. Use the differentiation and integration rules on the right to find derivatives and integrals of the following functions: 1 Find the derivatives Df (x) of the following functions: a) f (x) = x^6 + 6x^4 + x a) f (x) = x^2 + 3 log(x) c) f (x) = − 3 x^3 + 17x^2 − 5 x. What is Df (0)? 2 Find the integrals Sf (x) of the following functions: a) f (x) = x^4. b) f (x) = x^2 + 6x^7 + x c) f (x) = − 3 x^3 + 17x^2 − 5 x. What is Sf (1)? 3 Find the derivatives Df (x) of the following functions a) f (x) = exp(3 · x) + x^6 b) f (x) = 4 exp(− 3 · x) + 9x^6 c) f (x) = − exp(5 · x) + x^6
4 Find the integrals Sf (x) of the following functions a) f (x) = exp(6 · x) − 3 x^6 b) f (x) = exp(8 · x) + x^6 c) f (x) = − exp(5 · x) + x^6
5 Define f (x) = sin(4 · x) − exp(2 · x) + x^4 and assume h = 1/100 in part c). a) Find Df (x) b) Find Sf (x) c) Determine the value of 1 100 [f^ (
0 100 ) +^ f^ (
1 100 ) +^ · · ·^ +^ f^ (
99 100 )]^.
Fundamental theorem of Calculus: DSf (x) = f (x) and SDf (x) = f (x) − f (0). Differentiation rules Dxn^ = nxn−^1 Dea·x^ = aea·x D cos(a · x) = −a sin(a · x) D sin(a · x) = a cos(a · x) D log(x) = 1/x
Integration rules (for x = kh) Sxn^ = xn+1/(n + 1) Sea·x^ = ea·x/a S cos(a · x) = sin(a · x)/a S sin(a · x) = − cos(a · x)/a S (^1) x = log(x)
Fermat’s extreme value theorem: If Df (x) = 0 and f is continuous, then f has a local maximum or minimum in the open interval (x, x + h).
[x]^3 h for h = 0. 1 exph(x) for h = 0. 1
sinh(x) for h = 0. 1 logh(x) for h = 0. 1