Renamed and fixed extmath to work with regular variance to make batch update more general