Temperature Dependence of XANES Spectra for ATiO3, A2TiO4 and TiO2 Compounds with Structural Phase Transitions