Magnetic transition and anomalous thermal expansion in R 2 Fe 17 compounds