proving that an interval I = [a,b] has length |b-a|

prove that an interval I = [a,b] has length |b-a|.

so this is an example in my book. So for the proof they use the indicator function on the interval I so that if the intervals we split up the interval I into are completely within the interval I then the value of the function at those points is 1 and if their are intervals where they are completely outside the interval I then the value of the function at those points is 0. Because of this the book argues that the difference between the upper and lower sums is at most twice the volume of a single cube (or the length of an interval in this case).

Un(I) - Ln(I) </= 2(1/2^N) where 1/2^N is the length of a side of a cube or in this case an interval. My book defines integrals using dyadic pavings with the dyadic cubes C(k,N) being the set of all x in R^n such that k_i/2^N </= x_i < (k_i + 1)/2^N for 1 </= i </= n. N is the level of the paving where larger N means smaller cubes.

now my book says that as N approaches infinite, the upper and lower sums converge to the same limit and therefore the indicator function over I is integrable and the interval I has a volume or length. My book leaves the computation of the length of I as an exercise.

i could not figure out how to compute this so i checked the student solutions manual whose solution i did not understand. they said that (1/2^N) ((2^N)|b-a| - 2) </= Ln(I) </= Volume (I) </= Un(I) </= (1/2^N) ((2^N)|b-a| +2) and when N approaches infinite both sides become just |b-a| proving that the length of the interval I is |b-a|.

what i'm confused about is how did they calculate (1/2^N) ((2^N)|b-a| - 2) and (1/2^N) ((2^N)|b-a| +2) in the first place and how did they know that they were smaller than Ln and large than Un respectively? It seems very arbitrary to me. It seems to me that i could stick in anything else instead of |b-a| let's say |b^3 - a^5| and letting N approach infinite i could "prove" that the length of I will be |b^3 - a^5|. i know this is definitely not the case so i am missing something here. my solution manual just presents those sets of inequalities above and does not explain at all how they arrived at them. if anyone could help explain how the book came up with that i would be very grateful!