Heart sounds, the acoustic vibrations produced by the mechanical processes of the cardiac cycle, are modulated by respiratory activity. We have used computational techniques of cluster analysis and classification to study the effects of the respiratory phase and the respiratory resistive load on the temporal and morphological properties of the first (S1) and second heart sounds (S2), acquired from 12 healthy volunteers. Heart sounds exhibited strong morphological variability during normal respiration and nearly no variability during apnea. The variability was shown to be periodic, with its estimated period in good agreement with the measured duration of the respiratory cycle. Significant differences were observed between properties of S1 and S2 occurring during inspiration and expiration. S1 was commonly attenuated and slightly delayed during inspiration, whereas S2 was accentuated and its aortic component occurred earlier at late inspiration and early expiration. Typical split morphology was observed for S1 and S2 during inspiration. At high-breathing load, these changes became more prominent and occurred earlier in the respiratory cycle. Unsupervised cluster analysis was able to automatically identify the distinct morphologies associated with different respiratory phases and load. Classification of the respiration phase (inspiration or expiration) from the morphology of S1 achieved an average accuracy of 87 +/- 7%, and classification of the breathing load was accurate in 82 +/- 7%. These results suggest that quantitative heart sound analysis can shed light on the relation between respiration and cardiovascular mechanics and may be applied to continuous cardiopulmonary monitoring.