Solvent Effect on Functional Groups Attached to Edges of Carbon Nanotubes