Linear and nonlinear optical properties of carbon nanotubes from first-principles calculations | Synapse