private function X_to_cov