Prove that average of n numbers is greater than equal to the lowest number and less than or equal to the greatest number.

Printable View

- 07-16-2008anirbanAverage of n numbers
Prove that average of n numbers is greater than equal to the lowest number and less than or equal to the greatest number.

- 07-16-2008Thantos
Since this smells of homework I'm not gonna do a full proof and/or proper proof.

Assume you have two numbers A and B which have the average n. So the proof needs to show that

MIN(A,B) <= n <= MAX(A,B)

Now with two numbers you have three situations:

1) A = B

2) A > B

3) A < B

However, we really only need to prove 2 or 3 as it can cover both cases.

1) If A=B then MIN(A,B) = A and MAX(A,B) = A. n = 2A/2 = A. So A <= A <= A is true

2) If A>B then MIN(A,B) = B and MAX(A,B) = A. Additionally: A = B + x, where x > 0. So n = (A + B)/2 = (B + x + B) / 2 = (2B + x)/2 = 2B/2 + x/2 = B + x/2. So we are left with: B <= B + x/2 <= A. B <= B + x/2 -> 0 <= x/2 and since x>0 it is true. B+x/2 <= A -> B + x/2 <= B + x -> x/2 <= x and since x>0 it is true. - 07-16-2008Salem