EXAFS studies of lattice dynamics and thermal expansion