Three Dimensional Variational data assimilation or analysis (3DVAR) is one of most classical methods for providing the initial values for numerical models. In this method, the dimensions of the background error covariance and the observational error covariance matrices are large. Therefore, it is difficult to get the inverse of the covariance matrices and to reduce the orders of these matrices without information loss. With the use of the Sylvester Equation, on the basis of a new linear regression, a new cost function for 3DVAR was given. For the first-guess m×n field, there is an approximate 1−(m2+n2)/(mn×mn) reduction with m>1 & n>1 by using the cost function. The results of the numerical experiments show that the effect of this algorithm is no worse than that of the old cost function for 3DVAR.