covariance matrix calculated