Upper, lower sums: How are g(x), h(x) obtained, and their intervals? How do sums relate to function?

KFS

New member
Joined
Jun 15, 2018
Messages
34
Hello. The problem says I have to find the area of f(x) =x on [0,1] using upper and lower sums. My problem is that, according to what book provides, I do understand how the interval is divided into smaller partitions, what I don't understand is: 1. How g(x) and h(x) are obtained and their intervals. 2. Where it says "Each of the n boxes has area (1/n)*(1/n)=1/n^2, so their total area is n*(1/n^2)=1/n", I do understand how the calculations are done, what I don't understand is where do they get this from?
3. How the process of upper and lower sums are related to the given function? I mean, I don't understand how the upper and lower sums depend on f(x)=x or f(x)=x^2, or f(x)=x+5 or any other function, how the function affects the result of the upper and lower sums?
Thank you for your help. Screenshot_20190330-215801.png
 
First, notice that we are approximating the area with the sum of the area of n rectangles, each with an equal width. We could use trapezoids, but rectangles have a really simple formula for area, namely width times height.

So, if I am dividing the x-axis into n equal intervals from from a to b, the width will be

[MATH]\dfrac{b - a}{n}.[/MATH]
In the special case, where b = 1 and a = 0, this simplifies to

[MATH]\dfrac{1}{n}.[/MATH]
Any problem now with where the 1/n comes from?

So how do we compute the height of the rectangles that are consistently below f(x)? Well, if f'(x) [MATH]\ge[/MATH] 0 in the interval, then, in any sub-interval interval from c to c + [MATH]\Delta[/MATH], f(c) will give us the height of a rectangle with an area that is NOT larger than the area below f(x) from c to c + [MATH]\Delta[/MATH]. If you do not see this, just draw f(x) generically, just making sure that f(x) does not have has a falling slope from c to c + [MATH]\Delta.[/MATH]
Similarly, f(c + [MATH]\Delta[/MATH]) will give us the height of a rectangle with an area NOT smaller than the area below f(x) from c to c + [MATH]\Delta[/MATH].

For the smaller rectangles then, the heights we choose will be generically

[MATH]f \left (a + \dfrac{0(b - a)}{n} \right ),\ f \left (a + \dfrac{1(b - a)}{n} \right ),\ ... \ f \left (a + \dfrac{(n - 1)(a - b)}{n} \right).[/MATH]
Notice that the fractions are the same except for a factor in the numerators that runs from 0 to n - 1.

This simplifies to:

[MATH]f(0), \ f \left ( \dfrac{1}{n} \right), \ ... \ f \left ( \dfrac{n - 1}{n} \right ) \text { when } b = 1 \text { and } a = 0.[/MATH]
For the larger rectangles then, the heights we choose will be

[MATH]f \left (a + \dfrac{1(b - a)}{n} \right ),\ f \left (a + \dfrac{2(a - b)}{n} \right ),\ ... \ f \left (a + \dfrac{n(b - a)}{n} \right ).[/MATH]
Notice that the fractions are the same except for a factor in the numerators that runs from 1 to n.

This simplifies to:

[MATH]f \left (a + \dfrac{1}{n} \right), \ f \left (a + \dfrac{2}{n} \right), \ ... \ f(1) \text { when } b = 1 \text { and } a = 0.[/MATH]
Let A equal the area that we are looking for. Then it will be not smaller than the sum of the areas of the smaller triangles and not larger than the sum of the areas of the larger triangles. In other words, for generic f(x), we get this ugly looking thing:

[MATH]\left (\sum_{k=1}^n f \left (a + \dfrac{(k - 1)(b - a)}{n} \right) * \dfrac{1}{n} \right ) \le A \le \left ( \sum_{k=1}^n f \left (a + \dfrac{k(b - a)}{n} \right) * \dfrac{1}{n} \right ).[/MATH]
But with b = 1 and a = 0, it simplifies to

[MATH]\dfrac{1}{n} * \sum_{k=1}^n f \left (a + \dfrac{k - 1}{n} \right)< A < \dfrac{1}{n} * \sum_{k=1}^n f \left (a + \dfrac{k}{n} \right) .[/MATH]
Does this help?
 
Last edited:
I notice that I did not address your concern about where A = 1/2 comes from.

There are two answers to this. One is intuitive

[MATH]\dfrac{1}{2} - \dfrac{1}{2n} \approx \dfrac{1}{2} \text { as n becomes very large.}[/MATH]
Try it on your calculator with n = 1 billion. Similarly,

[MATH]\dfrac{1}{2} + \dfrac{1}{2n} \approx \dfrac{1}{2} \text { as n becomes very large.}[/MATH]
In standard analysis, this can be rigorously formalized into the squeeze theorem, but I hate analysis so I'll let pka do the formal proof.
 
Last edited:
I notice that I did not address your concern about where A = 1/2 comes from.

There are two answers to this. One is intuitive

[MATH]\dfrac{1}{2} - \dfrac{1}{2n} \approx \dfrac{1}{2} \text { as n becomes very large.}[/MATH]
Try it on your calculator with n = 1 billion. Similarly,

[MATH]\dfrac{1}{2} + \dfrac{1}{2n} \approx \dfrac{1}{2} \text { as n becomes very large.}[/MATH]
In standard analysis, this can be rigorously formalized into the squeeze theorem, but I hate analysis so I'll let pka do the formal proof.
Thank you for your help JeffM. It helped me. But how does any f(x) affect the result of the sums?
 
Sorry if I'm a little "slow", I find this particular problem quite hard.
 
[MATH]\dfrac{1}{2} + \dfrac{1}{2n} \approx \dfrac{1}{2} \text { as n becomes very large.}[/MATH]In standard analysis, this can be rigorously formalized into the squeeze theorem, but I hate analysis so I'll let pka do the formal proof.
Here is a pictorial proof.
Can we all agree that \(\displaystyle \tfrac{1}{2}\in\left(\tfrac{1}{2}-1,\tfrac{1}{2}+1\right)~?\)
Define \(\displaystyle (\forall n\in\mathbb{Z}^+)\mathcal{O}_n=\left(\tfrac{1}{2}-\tfrac{1}{n},\tfrac{1}{2}+\tfrac{1}{n}\right)\)
Surely it is clear that \(\displaystyle (\forall n\in\mathbb{Z}^+)\tfrac{1}{2}\in\mathcal{O}_n\)
Now just a bit of set theory: \(\displaystyle \tfrac{1}{2} \in \bigcap\limits_{n = 0}^\infty {{O_n}}\). If one-half is in each then it is in the common part.
Is this true \(\displaystyle \bigcap\limits_{n = 0}^\infty {{O_n}} =\left\{\tfrac{1}{2}\right\}~?\)
Well YES, because \(\displaystyle \mathop {\lim }\limits_{n \to \infty } \left( {\tfrac{1}{n}} \right) = 0\)
 
I tried to calculate the area of another exercise, f(x)=x on [1,2] and I got 1/2, and it is A=3/2. Could anyone please show me the procedure of f(x)=x on [0,1] so I can apply it to [1,2]? I don't want you to solve it for me I just want you to show me how you get A=1/2 so I can get A=3/2 for [1,2]. And how do they get g(x) and h(x)? Thank you.
 
Last edited:
Thank you for your help JeffM. It helped me. But how does any f(x) affect the result of the sums?
Because you are using f(x) at the end points of the sub-interval to calculate the height of the n rectangles. Therefore n values of the function f(x) are used in the process of approximation, which makes intuitive sense.
 
I tried to calculate the area of another exercise, f(x)=x on [1,2] and I got 1/2, and it is A=3/2. Could anyone please show me the procedure of f(x)=x on [0,1] so I can apply it to [1,2]? I don't want you to solve it for me I just want you to show me how you get A=1/2 so I can get A=3/2 for [1,2]. And how do they get g(x) and h(x)? Thank you.
Let's start with the general procedure.

We have an interval, [a, b] with a < b. The length of that interval is b - a. With me so far?

We divide it into n equal sub-intervals so the width of each sub-interval is

[MATH]\dfrac{b - a)}{n.}[/MATH]
Make sense so far?

We assume [MATH]f'(x) \ge 0 \text { in } [a,\ b].[/MATH]
(Obviously, to make the argument completely general we must also consider the case where

[MATH]f'(x) \le 0 \text { in } [a,\ b].[/MATH])

So we are going to create n rectangles, each with width (b - a).

Going left to right, the kth rectangle's base will have a left starting point of

[MATH]c \ge a +(k - 1) * \dfrac{b - a}{n}, \text { with } k = 1,\ 2,\ ...\ n.[/MATH]
If you do not understand this step, we need to talk further. Got this firmly in your head?
 
Let's start with the general procedure.

We have an interval, [a, b] with a < b. The length of that interval is b - a. With me so far?

We divide it into n equal sub-intervals so the width of each sub-interval is

[MATH]\dfrac{b - a)}{n.}[/MATH]
Make sense so far?

We assume [MATH]f'(x) \ge 0 \text { in } [a,\ b].[/MATH]
(Obviously, to make the argument completely general we must also consider the case where

[MATH]f'(x) \le 0 \text { in } [a,\ b].[/MATH])

So we are going to create n rectangles, each with width (b - a).

Going left to right, the kth rectangle's base will have a left starting point of

[MATH]c \ge a +(k - 1) * \dfrac{b - a}{n}, \text { with } k = 1,\ 2,\ ...\ n.[/MATH]
If you do not understand this step, we need to talk further. Got this firmly in your head?
I do understand.
 
Great.

So we are going to construct a rectangle on each sub-interval. The width of each rectangle will be

[MATH]\dfrac{b - a}{n} = w.[/MATH]
What will be the LEFTMOST point on the x-axis for each the sub-interval? Well, for the first sub-interval on the left, it will be

[MATH](a,\ 0)[/MATH]; for the next, it will be [MATH](a + w,\ 0)[/MATH]; for the third

it will be [MATH]a + 2w,\ 0)[/MATH]; and for the nth sub-interval, it will be [MATH](a + (n - 1)w,\ 0).[/MATH]
In general, the LEFTMOST point of the kth sub-interval on the x- axis will be [MATH](a + (k - 1)w, \ 0).[/MATH]
Still making sense?

OK. Now i want you to draw physically in real life f(x) in exactly one sub-interval such that

[MATH]f(x) > 0 \text { and } f'(x) > 0[/MATH]
and, to keep our notation simple, label the left endpoint on the x-axis (c, 0) and the right one (c + w, 0).

Any difficulty drawing f(x) in the sub-interval? It should

alway be above the x-axis and always be rising from left to right.

OK then. We construct our rectangle as follows. Raise a perpendicular upward from (c, 0) to where it intersects f(x). That will be at the point (c, f(c)), correct?

Now construct a perpendicular upward from (c + w, 0) to where it intersects f(x) at (c + w, f(c + w)). The area defined by the two perpendiculars, f(x), and the x-axis is the area to be approximated, right?

Now join the two perpendiculars by a line running parallel to the x-axis through (c, f(c)).

We now have constructed a rectangle with corners at (c, 0), (c, f(c)), (c + w, f(c)), and (c + w, 0).

Is that what you got from your drawing? If so, notice that the area of the rectangle is strictly less than the area that we are interested in.

Are you still with me?[/MATH]

EDIT: If we relax the constraint [MATH]f(x) > 0[/MATH] to [MATH]f(x) \ge 0[/MATH]
we may get the defective "rectangle" with corners at (c, 0), (c, 0), (c + w, 0) and (c + w, 0),
which is just a straight line and has no area at all. But it still does not exceed the area that we are trying to approximate.

Similarly, if we relax the constraint [MATH]f'(x) > 0[/MATH] to

[MATH]f'(x) \ge 0[/MATH], it may turn out that our rectangle has an area exactly equal to the area that we are trying to approximate. But, again, that means that it is still true that the area of the constructed rectangle does not exceed the area that we are trying to approximate.

So [MATH]f(x) \ge 0 \text { and } f'(x) \ge 0[/MATH]
are the key constraints and ensure that the area of the rectangle is less than or equal to the area being approximated.

I did not bother to work with the special cases of f(c) = 0 or f'(x) = 0 because they do not result in such clear diagrams.
 
Last edited:
I appreciate your explanation and the time you took. Thank you.
 
Top