Prediction of postoperative pulmonary function following thoracic operations