Piecewise Function Integration

Click For Summary

Homework Help Overview

The discussion revolves around finding formulas for the upper and lower sums of a piecewise function defined on the interval [0,1]. The function is given as f(x) = 0 for 0 ≤ x < 1/2 and f(x) = 1 for 1/2 ≤ x ≤ 1, with the goal of computing the integral of f over this interval using a partition P_n.

Discussion Character

  • Exploratory, Mathematical reasoning, Problem interpretation

Approaches and Questions Raised

  • Participants discuss the determination of the supremum and infimum of the function over various subintervals defined by the partition. There is an exploration of how to express the upper and lower sums based on the values of M_j(f) and m_j(f) for different cases of j relative to n. Some participants question the correctness of their expressions and the limits as n approaches infinity.

Discussion Status

Several participants have provided insights into the calculations for M_j(f) and m_j(f), and there is a progression towards establishing a general case for the sums. While some participants express uncertainty about their findings, others affirm the reasoning presented, indicating a productive exchange of ideas.

Contextual Notes

Participants are working under the constraints of homework rules, which may limit the amount of direct assistance they can receive. There is an ongoing discussion about the implications of odd and even values of n on the limits of the sums.

wany
Messages
72
Reaction score
0

Homework Statement


Find formulas for the upper and lower sums of [itex]f[/itex] on [itex]P_n[/itex], and use them to compute the value of [itex]\int_0^1f(x)dx[/itex].
[itex]P_n:=\{\frac{j}{n}:j=0,1,...,n\}[/itex] (a partition of [0,1])
[itex]\[<br /> f(x) = \left\{ \begin{array}{ccc} 0 & 0 \le x < 1/2 \\ 1 & 1/2 \le x \le 1 \end{array} \right. \][/itex]

Homework Equations


[itex]U(f,P)=\sum\limits_{j=1}^{n} M_j(f)\Delta x_j[/itex] and
[itex]L(f,P)=\sum\limits_{j=1}^{n} M_j(f)\Delta x_j[/itex]
where [itex]M_j=sup f([x_{j-1},x_j])[/itex] and [itex]m_j=inf f([x_{j-1},x_j])[/itex]
if [itex]\lim_{n \rightarrow \infty} L(f,P_n)=\lim_{n \rightarrow \infty} U(f,P_n)[/itex] then this equals [itex]\int_0^1f(x)dx[/itex]

The Attempt at a Solution


So it is easy to see that this function is bounded on [0,1]. So now we can break this up into the different partitions, but now is where I run into a problem. It is finding the inf and the sup of each interval:
so obviously if both [itex]x_j, x_{j-1}[/itex] are < 1/2 then both inf and sup are 0;
if both [itex]x_j, x_{j-1}[/itex] are >= 1/2 then both inf and sup are 1;
so now it is possible for one case to be [itex]x_j \ge 1/2, x_{j-1} < 1/2[/itex]
in which case sup =1/2 and inf =0.

I am stuck from this point. Any help would be appreciated.
 
Physics news on Phys.org
Can you tell us how exactly you are stuck?
It seems that you have found the good expression for the [tex]M_j(f)[/tex], i.e.

[tex]M_j(f)=\left\{\begin{array}{ccc}<br /> 0 & \text{if} & j< n/2\\<br /> 1 & \text{if} & j\geq n/2<br /> \end{array}\right.[/tex]

and something analogous for [tex]m_j(f)[/tex]. Now you just need to plug those things in in U(f,P) and L(f,P)...
 
so [itex] m_j(f)=\left\{\begin{array}{ccc}<br /> 0 & \text{if} & j \leq n/2\\<br /> 1 & \text{if} & j > n/2<br /> \end{array}\right.[/itex]
So now
[itex]U(f,P)=\left\{\begin{array}{ccc}<br /> \sum\limits_{j=1}^{n} (0)(j/n)=0 & \text{if} & j< n/2\\<br /> \sum\limits_{j=1}^{n} (1)(j/n)= & \text{if} & j\geq n/2<br /> \end{array}\right.[/itex]
and
[itex]L(f,P)=\left\{\begin{array}{ccc}<br /> \sum\limits_{j=1}^{n} (0)(j/n)=0 & \text{if} & j \le n/2\\<br /> \sum\limits_{j=1}^{n} (1)(j/n)= & \text{if} & j > n/2<br /> \end{array}\right.[/itex]

So now solving I am not sure if I am correct. Are the sums not supposed to be taken from j=1 to n in such cases?
 
wait so would it actually be:
[itex] U(f,P)=\left\{\begin{array}{ccc}<br /> \sum\limits_{j=1}^{n} (0)(1/n)=0 & \text{if} & j< n/2\\<br /> \sum\limits_{j=1}^{n} (1)(1/2n)= & \text{if} & j\geq n/2<br /> \end{array}\right.[/itex]
and
[itex] L(f,P)=\left\{\begin{array}{ccc}<br /> \sum\limits_{j=1}^{n} (0)(1/n)=0 & \text{if} & j \le n/2\\<br /> \sum\limits_{j=1}^{n} (1)(1/2n+1)= & \text{if} & j > n/2<br /> \end{array}\right.[/itex]
So now viewing as the limit goes to infinity, [itex]\lim_{n \rightarrow \infty}\sum\limits_{j=1}^{n} (1)(1/2n+1)=0[/itex]
and [itex]\lim_{n \rightarrow \infty}\sum\limits_{j=1}^{n} (1)(1/2n)=0[/itex]
 
No, what you wrote is incorrect.
You have the sum

[tex]\sum_{j=1}^n{M_j(f)\Delta x_j[/tex]

and you are supposed to plug in the values for [tex]M_j(f)[/tex]. But for every [tex]M_j(f)[/tex] you have a different value.

Lets take the example with n=3, then we got

[tex]M_1(f)\Delta x_1+M_2(f)\Delta x_2+M_3(f)\Delta x_3[/tex]

We got that [tex]M_1(f)=0[/tex] and [tex]M_2(f)=M_3(f)=1[/tex], thus the above expression yields:

[tex]\Delta x_2+\Delta x_3=2/3[/tex]

Now you just need to do the same thing with n arbitrary (I strongly suggest you do the cases n=4 and n=5 first, then you will see the general case).
 
Ok so I think I got the general case, but I am not certain. So I did it for n=4,n=5,n=6, and got 3/4,3/5, and 2/3 respectively. So basically I think that depending on n, there will be
[itex]\lceil \frac{n+1}{2} \rceil[/itex] values that have the sup of 1.

So case 1: n is odd: so we have [itex]\frac{n+1}{2}*\frac{1}{n}=\frac{n+1}{2n}=\frac{1}{2}+\frac{1}{2n}[/itex]
so taking this limit as n goes to infinity we get that it is 1/2.
So case 2: n is even: so we have that [itex]\frac{n+1+1}{2}*\frac{1}{n}=\frac{n+2}{2n}=\frac{1}{2}+\frac{2}{2n}[/itex]
so taking this limit as n goes to infinity we get that it is 1/2.

Now for the lower bound, it is [itex]\lfloor \frac{n-1}{2} \rfloor[/itex]

So case 1: n is odd: so we have [itex]\frac{n-1}{2}*\frac{1}{n}=\frac{n-1}{2n}=\frac{1}{2}-\frac{1}{2n}[/itex]
so taking this limit as n goes to infinity we get that it is 1/2.
So case 2: n is even: so we have that [itex]\frac{n-1-1}{2}*\frac{1}{n}=\frac{n-2}{2n}=\frac{1}{2}-\frac{2}{2n}[/itex]
so taking this limit as n goes to infinity we get that it is 1/2.

Is this correct?
 
That seems to be good! :approve:
 
Thanks a lot, this was very helpful.
 

Similar threads

Replies
8
Views
2K
Replies
3
Views
2K
  • · Replies 4 ·
Replies
4
Views
1K
  • · Replies 6 ·
Replies
6
Views
3K
  • · Replies 5 ·
Replies
5
Views
2K
  • · Replies 13 ·
Replies
13
Views
2K
Replies
6
Views
3K
Replies
10
Views
2K
  • · Replies 3 ·
Replies
3
Views
2K
  • · Replies 105 ·
4
Replies
105
Views
11K