Time Weighted Average Formula