Simulation of the nucleation and growth of clay minerals coupled with cation exchange