# On calculation weighted average of two positive numbers

1. Dec 2, 2013

### drittel_regel

1. The problem statement, all variables and given/known data
Given two positive numbers calculate their weighted average(Note: This is not actually a homework question, but silly me have doubts, so I put it in this category)

2. Relevant equations

Two given positive numbers a,b. No separate weights are available to weigh each numbers

3. The attempt at a solution
Can I do the following by considering the weight as the number as a fraction of the sum of two numbers?

weighted average = a*(a/a+b) + b*(b/a+b) =( a^2 + b^2) /(a+b)
So, for two numbers 9 and 11, the arithmetic mean will be 10, and weighted mean will be,
9*(9/20) + 11 *(11/20) = 9*0.45 + 11 * 0.55 = 10.1

Thank you

2. Dec 2, 2013

### Staff: Mentor

Looks OK to me, but a more realistic example would be, say test scores that have different weights. For example, suppose a class is graded on the results of a midterm (weight = 35%) and a final exam (weight = 65%). If a student received a midterm grade of 78 points and a final exam grade of 90 points, what would be the weighted average of these two scores?