Calculation of acceleration using Mean Value Theorem