Deriving the formula for harmonic mean

<p>@ firelight: Thanks! Actually the same formula is used for both 1) and 2).</p>