added variance adjustment for mutost and re-wrote mutost in C