Nanocomposites of polyaniline and titania nanoparticles for gas sensors