This thesis studies carbon nanotubes using state-of-the-art computational methods. Using large-scale quantum-mechanical calculations, based on density-functional-theory, we investigate several important aspects of the physics and chemistry of single-walled-nanotubes. The focus is on the effect of defects, namely adparticles and vacancies, on the structural, electronic and dynmical properties of the nanotubes. We also present preliminary results of simulations exploring a possible route for the formation of SWNTs from graphene nanoflakes. Adparticles include atomic hydrogen, oxygen, sulfur at different concentrations as well as nitrogen--oxides. Chemisorption of hydrogen as well as oxygen and isoelectronic species results in the formation of clusters on the sidewall, with characteristic structures corresponding to characteristic signatures in the electronic spectra. Especially in the case of oxygen, we find that relatively high energy barriers separate different structures: this shows that not only thermodynamically favored configurations are relevant for the understanding of oxygen chemisorption but the presence of traps cannot be neglected. The fingerpint of these traps is confirmed by scanning-tunneling spectroscopy. Trends with size and chirality of the nanotubes and oxygen coverage are studied in detail and also explained in terms of simple chemical descriptors. The importance of large-scale atomistic models is also emphasized to obtain convergent results and thus reliable predictions, and comparison is made of results we obtain using different gradient-corrected exchange-correlation functionals and in part with hybrid functionals. The study of nitrogen-oxides faces the difficulty to correctly represent physisorption, also with empirically corrected gradient-corrected exchange-correlation and hybrid functionals. Still our calculations of vibrational frequencies of different molecules on the sidewall, once compared with experiment, are able to distinguish the specific species observed in infrared spectra. Part of our work is centered on the comparison of widely used classical potentials (reactive force fields) with DFT results. Specifically we use them to study hydrogen and oxygen chemisorption, and especially examine the validity of several different force-fields for the description of the structure and energetics of single and double vacancies. In all cases, we find rather limited agreement with DFT results, showing the intrinsic difficulty to represent the subtle and intrinsic quantum effects governing the physico-chemical behavior of carbon nanotubes. Still, the wealth of results we have obtained might be useful for an improvement of these classical schemes for a specific application or other semi-classical models.