1
00:00:00,000 --> 00:00:16,800
Hello everyone, welcome to the magnificence of mathematics.

2
00:00:16,800 --> 00:00:19,520
I'm your host, Eddie Kingston.

3
00:00:19,520 --> 00:00:23,880
If you've ever worked on a farm and had to put up fencing around a particular area, how

4
00:00:23,880 --> 00:00:28,080
could you go about maximizing the area you could enclose with the fencing materials you'd

5
00:00:28,080 --> 00:00:29,160
have on hand?

6
00:00:29,160 --> 00:00:32,960
On the other hand, a lot of you listeners might remember the formula for the area of

7
00:00:32,960 --> 00:00:37,800
a triangle, 1 half base times height, or that of a circle, pi r squared.

8
00:00:37,800 --> 00:00:43,200
But what if you wanted to find the area of, say, a rectangle with a squiggly top, or some

9
00:00:43,200 --> 00:00:44,960
other arbitrary figure?

10
00:00:44,960 --> 00:00:47,760
These two questions can't possibly be related, right?

11
00:00:47,760 --> 00:00:52,920
Well, it turns out that the answers to these two questions turn out to be not only related,

12
00:00:52,920 --> 00:00:55,000
but more or less the opposite of each other.

13
00:00:55,000 --> 00:01:00,080
They have to do with the two subfields of calculus, namely differential calculus and

14
00:01:00,080 --> 00:01:01,840
integral calculus.

15
00:01:01,840 --> 00:01:05,680
Over the course of the next several episodes, we'll answer these two questions using both

16
00:01:05,680 --> 00:01:11,080
differential and integral calculus and see more about how calculus is used a lot in day-to-day

17
00:01:11,080 --> 00:01:12,080
life.

18
00:01:12,080 --> 00:01:17,240
Back in episode 3, I briefly mentioned the idea of a limit in the context of probability.

19
00:01:17,240 --> 00:01:21,520
Knowing what a limit is, is crucial to understanding differential calculus.

20
00:01:21,520 --> 00:01:26,120
The basic idea of a limit is that you want to know how a function behaves near a point

21
00:01:26,120 --> 00:01:28,560
without actually reaching that point.

22
00:01:28,560 --> 00:01:34,300
For example, imagine you draw up two lines, one vertical and one horizontal, intersecting

23
00:01:34,300 --> 00:01:35,600
at one point.

24
00:01:35,600 --> 00:01:38,560
This intersecting point is called the origin.

25
00:01:38,560 --> 00:01:43,640
Now put little marks evenly spaced from each other and label the origin 0, the first mark

26
00:01:43,640 --> 00:01:48,880
to the right of the origin 1, second mark to the right 2, and so on.

27
00:01:48,880 --> 00:01:53,800
Let the first mark to the left be negative 1, the second to the left negative 2, and

28
00:01:53,800 --> 00:01:54,920
so on.

29
00:01:54,920 --> 00:02:00,180
Repeat the same thing for the vertical line, but with right replaced by up and left replaced

30
00:02:00,180 --> 00:02:01,400
with down.

31
00:02:01,400 --> 00:02:06,000
You are now imagining what's called a Cartesian coordinate system, named after 17th century

32
00:02:06,000 --> 00:02:08,240
French philosopher René Descartes.

33
00:02:08,240 --> 00:02:14,160
Now imagine a straight diagonal line going up and to the right, passing through the origin.

34
00:02:14,160 --> 00:02:19,880
You are now imagining the function y equals x, where the x coordinate matches the y coordinate

35
00:02:19,880 --> 00:02:21,280
at every point.

36
00:02:21,280 --> 00:02:25,680
So if you look at where you are on this line at x equals 2, you'll see that you're also

37
00:02:25,680 --> 00:02:28,880
at the y coordinate y equals 2.

38
00:02:28,880 --> 00:02:33,280
Now imagine you move along this line from this spot and get closer and closer to the

39
00:02:33,280 --> 00:02:38,320
point x equals 1, and you'll see that you're approaching the point y equals 1 as well.

40
00:02:38,320 --> 00:02:43,240
In particular, you are said to be approaching y equals 1 from the right, meaning you start

41
00:02:43,240 --> 00:02:48,560
it at the right hand side of the line and work your way from the right to the left.

42
00:02:48,560 --> 00:02:53,600
Now if you start from the left side and work your way up and to the right of the line to

43
00:02:53,600 --> 00:02:59,360
the point x equals 1, you are said to be approaching the point y equals 1 from the left, since

44
00:02:59,360 --> 00:03:03,120
you're starting from the left hand side and working your way to the right.

45
00:03:03,120 --> 00:03:08,840
Since this is true for any real number a, you can then and only then say that the limit

46
00:03:08,840 --> 00:03:14,400
as x approaches a of this function x is simply that number a.

47
00:03:14,400 --> 00:03:18,720
If we were working with a more complicated function, it might be the case that the limit

48
00:03:18,720 --> 00:03:24,600
as x approaches a number a from the right is a different value than the limit as x approaches

49
00:03:24,600 --> 00:03:26,200
a from the left.

50
00:03:26,200 --> 00:03:29,480
In that case, we say that the limit doesn't exist.

51
00:03:29,480 --> 00:03:33,520
For example, consider the function y equals 1 over x.

52
00:03:33,520 --> 00:03:39,160
Since 1 divided by 1 equals 1, the value of y at x equals 1 is simply 1.

53
00:03:39,160 --> 00:03:46,360
If you consider x equals 1 half, the value of y is 2, since 1 divided by 1 half is 2,

54
00:03:46,360 --> 00:03:51,600
because 2 times 1 half is 1, and multiplication and division are inverses, or opposites of

55
00:03:51,600 --> 00:03:52,600
each other.

56
00:03:52,600 --> 00:03:57,360
Now if you consider x equals 1 third, the value of y is 3 for the same reason.

57
00:03:57,360 --> 00:04:02,280
You can see that as x gets smaller, y gets bigger.

58
00:04:02,280 --> 00:04:08,200
In particular, as we get closer and closer to x equals 0, y just grows and grows without

59
00:04:08,200 --> 00:04:09,200
bound.

60
00:04:09,200 --> 00:04:15,120
We say that the limit as x approaches 0 from the right of 1 over x is infinity, positive

61
00:04:15,120 --> 00:04:16,880
infinity in particular.

62
00:04:16,880 --> 00:04:22,560
Similarly, if you consider x equals negative 1 half, y equals negative 2.

63
00:04:22,560 --> 00:04:26,520
If x equals negative 1 third, y equals negative 3.

64
00:04:26,520 --> 00:04:33,120
So as x gets closer and closer to 0 from the negative, i.e. left side, y gets increasingly

65
00:04:33,120 --> 00:04:34,120
negative.

66
00:04:34,120 --> 00:04:39,920
Hence the limit as x approaches 0 from the left of 1 over x is negative infinity.

67
00:04:39,920 --> 00:04:45,040
So we see that as x gets closer and closer to 0 from these two directions, this function

68
00:04:45,040 --> 00:04:47,180
approaches two different values.

69
00:04:47,180 --> 00:04:52,520
So the limit as x approaches 0 of 1 over x does not exist.

70
00:04:52,520 --> 00:04:56,560
Another way limits have the ability to not exist is if they don't approach anything

71
00:04:56,560 --> 00:04:57,840
in particular.

72
00:04:57,840 --> 00:05:03,280
Consider a function that just gradually oscillates back and forth between negative 1 and 1, touching

73
00:05:03,280 --> 00:05:05,620
every real number along the way.

74
00:05:05,620 --> 00:05:09,760
So at one interval, the function starts at negative 1, and as you move right, it goes

75
00:05:09,760 --> 00:05:14,200
up up up up all the way to 1, and then it goes down down down down down all the way

76
00:05:14,200 --> 00:05:15,520
to negative 1.

77
00:05:15,520 --> 00:05:18,840
And this cycle repeats forever in both directions.

78
00:05:18,840 --> 00:05:23,800
One example of this function is called the sine function, so y equals sine of x.

79
00:05:23,800 --> 00:05:28,200
Now what is the limit as x approaches infinity of this function?

80
00:05:28,200 --> 00:05:33,120
Since it's constantly hitting negative 1, 1, and everything in between, it just goes

81
00:05:33,120 --> 00:05:36,360
on forever, not approaching anything in particular.

82
00:05:36,360 --> 00:05:40,700
It's not getting closer and closer to any certain value in the long run, and it's not

83
00:05:40,700 --> 00:05:45,240
growing and growing to either positive or negative infinity, so we say in this instance

84
00:05:45,240 --> 00:05:50,200
that the limit as x approaches infinity of sine of x does not exist either.

85
00:05:50,200 --> 00:05:54,120
Now that we know what limits are, let's get into what derivatives are, and the heart of

86
00:05:54,120 --> 00:05:56,140
what differential calculus is about.

87
00:05:56,140 --> 00:05:59,940
If you've taken an algebra class in high school, you might remember finding slopes

88
00:05:59,940 --> 00:06:02,740
of lines, rise over run, and all that.

89
00:06:02,740 --> 00:06:08,800
This is just how much the value of y changes divided by how much the value of x changes.

90
00:06:08,800 --> 00:06:15,840
For example, for the line y equals 2x, consider the points 1,2, and 2,4, where in the first

91
00:06:15,840 --> 00:06:20,720
point the x coordinates 1 and the y coordinates 2, and in the second point the x coordinates

92
00:06:20,720 --> 00:06:24,400
2 and the y coordinates 4, through both of which the line goes.

93
00:06:24,400 --> 00:06:30,800
The change in y is just 4 minus 2 equals 2, and the change in x is just 2 minus 1 equals

94
00:06:30,800 --> 00:06:31,800
1.

95
00:06:31,800 --> 00:06:36,840
So the slope of this line is the change in y, namely 2, divided by the change in x, namely

96
00:06:36,840 --> 00:06:37,840
1.

97
00:06:37,840 --> 00:06:39,720
So the slope of the line is 2.

98
00:06:39,720 --> 00:06:46,800
Similarly, for any function y equals m times x, for some number m, the slope is just that

99
00:06:46,800 --> 00:06:47,800
number m.

100
00:06:47,800 --> 00:06:51,960
We'll later see that the slope is also the derivative of functions like these.

101
00:06:51,960 --> 00:06:57,240
Any function you can think of has a corresponding straight line at every point, such that the

102
00:06:57,240 --> 00:07:00,560
line just barely touches the function at that point.

103
00:07:00,560 --> 00:07:05,160
This is what's known as a tangent line, and the slope of this tangent line is also the

104
00:07:05,160 --> 00:07:07,920
slope of the function at that point.

105
00:07:07,920 --> 00:07:12,880
This slope at that point is called the derivative of the function at that point.

106
00:07:12,880 --> 00:07:17,760
What if you wanted a function that told you the derivative at every point?

107
00:07:17,760 --> 00:07:22,080
Tangent lines can be approximated by what are called secant lines, which are lines that

108
00:07:22,080 --> 00:07:26,000
just barely touch the function at two different points.

109
00:07:26,000 --> 00:07:30,960
Let's call the x coordinate of one of the points x, and the y coordinate f of x the

110
00:07:30,960 --> 00:07:33,440
function evaluated at that point x.

111
00:07:33,440 --> 00:07:39,160
So for example, for the function f of x equals x squared, the point x equals 3 corresponds

112
00:07:39,160 --> 00:07:43,720
to the point f of 3, which is 3 squared, which is 9.

113
00:07:43,720 --> 00:07:47,560
Also an important thing to notice is that f of x is the exact same thing as y in terms

114
00:07:47,560 --> 00:07:49,120
of function notation.

115
00:07:49,120 --> 00:07:52,600
Now consider moving along the graph by a tiny, tiny amount.

116
00:07:52,600 --> 00:07:55,720
Now we're going to call this tiny, tiny amount h.

117
00:07:55,720 --> 00:08:01,720
So we call the x coordinate of our second point x plus h, and the y coordinate f of

118
00:08:01,720 --> 00:08:03,160
x plus h.

119
00:08:03,160 --> 00:08:08,360
So the secant line intersects the function at two points, the first of which we call

120
00:08:08,360 --> 00:08:13,280
the x coordinate just x, and the y coordinate f of x, and the second point where we call

121
00:08:13,280 --> 00:08:18,600
the x coordinate x plus h, and the y coordinate f of x plus h.

122
00:08:18,600 --> 00:08:24,660
The slope of this secant line is the change in the y coordinate f of x plus h minus f

123
00:08:24,660 --> 00:08:32,400
of x, all divided by the change in the x coordinate x plus h minus x, which is just h.

124
00:08:32,400 --> 00:08:38,800
As h gets closer and closer to zero, the secant line at a point just becomes the tangent line

125
00:08:38,800 --> 00:08:39,920
at that point.

126
00:08:39,920 --> 00:08:47,160
That is, the limit as h approaches zero of the quantity f of x plus h minus f of x divided

127
00:08:47,160 --> 00:08:53,400
by h is the slope of the tangent line, and this limit is by definition the derivative

128
00:08:53,400 --> 00:08:55,640
of the entire function f of x.

129
00:08:55,640 --> 00:09:01,520
This is noted by either f prime of x, which is what's called Lagrange's notation, named

130
00:09:01,520 --> 00:09:06,400
after French mathematician Joseph-Louis Lagrange, whose works were inspired by the famous English

131
00:09:06,400 --> 00:09:13,360
physicist Isaac Newton, or by dy divided by dx, read just dy dx, which is what's called

132
00:09:13,360 --> 00:09:18,360
Leibniz notation, named after German mathematician Gottfried Wilhelm Leibniz.

133
00:09:18,360 --> 00:09:22,640
Regardless of which notation you want to use, this tells you the derivative of the function

134
00:09:22,640 --> 00:09:24,400
at any point you want.

135
00:09:24,400 --> 00:09:29,680
For example, let's consider the function f of x equals m times x for some number m.

136
00:09:29,680 --> 00:09:36,680
If we plug in x plus h in this function, we get f of x plus h equals m times the quantity

137
00:09:36,680 --> 00:09:42,200
x plus h, which if we distribute that out is m times x plus m times h.

138
00:09:42,200 --> 00:09:48,720
Then we subtract f of x, which is just m times x, to get m times h in the numerator of our

139
00:09:48,720 --> 00:09:49,720
limit.

140
00:09:49,720 --> 00:09:52,560
Divide this by h to simply get m.

141
00:09:52,560 --> 00:09:58,400
Since this function no longer depends on what h is, the limit as h approaches zero of m

142
00:09:58,400 --> 00:10:02,380
is simply that number m, and this agrees with what we had earlier.

143
00:10:02,380 --> 00:10:08,120
For a slightly more complicated example, consider f of x equals x squared.

144
00:10:08,120 --> 00:10:14,320
Then f of x plus h is simply the quantity x plus h squared, which if you remember FOIL,

145
00:10:14,320 --> 00:10:20,440
first outer and last from your algebra 1 class, that gets us x squared plus x times h plus

146
00:10:20,440 --> 00:10:28,260
x times h plus h squared, which is x squared plus 2x times h plus h squared.

147
00:10:28,260 --> 00:10:32,580
Subtract off x squared to get 2 times x times h plus h squared.

148
00:10:32,580 --> 00:10:37,520
Note that we have h as a common factor in this expression, so we can factor this as

149
00:10:37,520 --> 00:10:42,960
h times the quantity 2x plus h, and divide that by just h.

150
00:10:42,960 --> 00:10:48,540
The h's cancel out, and we have the limit as h approaches zero of 2x plus h.

151
00:10:48,540 --> 00:10:54,820
We can just evaluate this limit term by term, and get 2x plus zero, which is just 2x.

152
00:10:54,820 --> 00:11:00,240
So the slope of the tangent line at any point x of the function f of x equals x squared

153
00:11:00,240 --> 00:11:03,120
is f prime of x equals 2x.

154
00:11:03,120 --> 00:11:08,320
Whew, okay, so having gone through all that, let's go back to what we talked about before

155
00:11:08,320 --> 00:11:10,500
with the whole fence thing.

156
00:11:10,500 --> 00:11:15,540
Suppose you have 40 square feet of fencing material, say wood or whatever, that you want

157
00:11:15,540 --> 00:11:18,440
to enclose in a rectangular area.

158
00:11:18,440 --> 00:11:23,360
What would you want the dimensions of the fence to be such that the area you enclose

159
00:11:23,360 --> 00:11:25,100
is maximized?

160
00:11:25,100 --> 00:11:30,200
Well since you have 40 square feet of wood to use as the perimeter of your enclosure,

161
00:11:30,200 --> 00:11:37,120
you want to find the length L and the width W such that 2L plus 2W equals 40, that is

162
00:11:37,120 --> 00:11:45,840
the perimeter of the rectangle is 40, and such that the area L times W is maximized.

163
00:11:45,840 --> 00:11:52,640
If we solve our first equation for L by subtracting both sides by 2W and dividing everything by

164
00:11:52,640 --> 00:11:59,680
2, we get L equals 20 minus W. We can plug this into the expression for area and get

165
00:11:59,680 --> 00:12:08,760
W times the quantity 20 minus W and distribute this out to get 20 times W minus W squared.

166
00:12:08,760 --> 00:12:13,760
Finding the maximum area of the enclosure amounts to finding the maximum value of the

167
00:12:13,760 --> 00:12:19,240
function f of W equals 20 times W minus W squared.

168
00:12:19,240 --> 00:12:24,400
The first step in finding the maximum value is to find the derivative of this function.

169
00:12:24,400 --> 00:12:29,880
We can do this term by term, and we actually know what this derivative is already.

170
00:12:29,880 --> 00:12:35,580
The derivative of 20 times W with respect to W is just 20, because that's the slope

171
00:12:35,580 --> 00:12:41,320
of the function f of W equals 20 times W, and the derivative of W squared is just 2

172
00:12:41,320 --> 00:12:47,040
times W. So the derivative of the whole function is 20 minus 2W.

173
00:12:47,040 --> 00:12:52,600
Now the next step is to set this derivative equal to 0 and solve for W. So we subtract

174
00:12:52,600 --> 00:12:59,160
20 from both sides and divide by negative 2 to get W equals 10 feet. But since we had

175
00:12:59,160 --> 00:13:08,160
L equals 20 minus W, the corresponding length L is just 20 minus 10 equals 10 feet. So therefore,

176
00:13:08,160 --> 00:13:14,760
the rectangular shape that maximizes the enclosed area is just a square with side length 10

177
00:13:14,760 --> 00:13:16,920
feet, since all sides are equal.

178
00:13:16,920 --> 00:13:21,800
This is true regardless of how much fencing you have. Calculus has already been seen to

179
00:13:21,800 --> 00:13:26,800
be super useful in everyday life, and we've barely begun scratching the surface. Next

180
00:13:26,800 --> 00:13:56,640
time we'll talk about differential calculus's counterpart, integral calculus. See you then!

181
00:13:56,640 --> 00:14:55,920
The Magnificence of Mathematics was brought to you by Algid Productions LLC. Thank you for listening and don't forget to rate and share! 
