Phase transitions and nucleation processes