# Why does Clausius inequality exist if entropy is a state function?

In Atkin's Chemical Principles: The Quest for Insight, the Clausius inequality is said to be

$$\Delta S \geq \frac qT$$ where equality applies to a reversible process.

Why would the change in entropy be different for a reversible process compared to an irreversible process if entropy is a state function, and the initial and final properties of the system remain the same?

The variation of the entropy for a reversible process is indeed $$\Delta S_{rev} = \frac{\Delta Q_{rev}}{T}$$, which is a trivial thermodynamic fact. During the process, even if the initial and final elements are conserved, the number of microstates of the system can change. If the initial state has $$\Omega_1$$ microstates and the final state has $$\Omega_2$$ microstates, the variation in entropy will be $$\Delta S_{irr} = k_b \log \frac{\Delta_2}{\Delta_1}$$. The latter is crucial, if there is no microstate created $$\Omega_2 = \Omega_1$$, the process is reversible so that $$\Delta S = \Delta S_{rev}$$. However, when microstates are created, $$\Delta S > \Delta S_{rev} = \frac{\Delta Q_{rev}}{T}$$, the process is irreversible, because $$\Delta S_{irr} > 0$$ cannot be destroyed because it contributes to the free energy.
At $$T=0\text{ K}$$, the increase in entropy has no noticeable effect $$\Delta S_{irr}$$, there is no need to create new microstates, some processes are reversible but at a finite temperature $$T>0$$ the increase in entropy reduces the free energy more or less considerably with $$-T\Delta S$$, a disordered system is more favorable and the processes are less reversible.
An example will be identical polarized dipoles (either electric or magnetic) at $$T=0\text{ K}$$, some will flip to form antiparallel configuration at $$T>0 \text{ K}$$, creating more information and reducing the free energy.