half ready optimal variance calculation