Calculation of quadratic molecular potential constants by the method of damped least squares