Carbon nanotube functionalization with carboxylic derivatives: a DFT study