Phase transition in perovskites