ΔStotal = ΔSsystem + ΔSsurrounding > 0
Now check the spontaneity of the formation of rust.
4Fe (s) + 3O2 (g) ⟶ 2Fe2O3 (s) ..... ΔrHө = -1648 kJ mol-1
rust formation is a spontaneous reaction even though entropy change given for this reaction is -549.4 JK-1mol-1 at 298K.
For spontaneity total entropy must be greater than zero. How can this reaction be spontaneous when the entropy of the system is negative? Well, we did forget something, didn't we? Let’s work out the entropy change of the surrounding. This reaction is exothermic which means 1648 kJ mol-1 amount of heat is absorbed by the surrounding.
ΔSsurr = ΔrHө / T
ΔSsurr = 1648 kJ mol-1/ 298K
ΔSsurr = 5.53 kJ mol-1K-1 = 5530 Jmol-1K-1
Now calculate the change in total entropy
ΔStotal = ΔSsystem + ΔSsurrounding
ΔStotal = -549.4 JK-1mol-1 + 5530 Jmol-1K-1
ΔStotal = 4980.6 JK-1mol-1
The total entropy increases by the rusting which favours spontaneity. This is in accordance with the Second Law of Thermodynamics which tells us that on the transformation of energy from one form to another form entropy always increases and energy always decreases.
You have seen that enthalpy alone isn’t the deciding factor for a process to be spontaneous; you have to consider the entropy as well. As we saw in the example of rusting, it is quite confusing to decide the spontaneity of the reaction by just seeing the enthalpy and entropy of the system