Density functional study of adsorption of atoms and molecules on single-walled BN nanotubes