canonical ensemble. The free energy functional is first defined on the original KMC lattice. How- ever, after re-writing the interaction terms employing gradient operators [78] one finally obtains the free energy functional for a continuous system where Since the liquid may evaporate from the surface into the vapour above the surface, µ is the (true) chemical potential of this reservoir and determines the rate of evaporation [condensation] from [to] the surface. Note that normally a free energy of the form in Eq. (4) is obtained by making a gradient expansion of the free energy functional of a continuous system [84]. However, here we have made the mapping from the free energy of the lattice KMC system. The chemical potential for the nanoparticles may be determined from the functional derivative µ$_{n}$ = δF [ ρ$_{n}$, ρ$_{l}$ ] /δρ$_{n}$ ( r ) . In equilibrium it is constant throughout the system, but it may vary spatially in a non-equilibrium system, i.e., µ$_{n}$ = µ$_{n}$ ( r , t ) . We assume that the dynamics of the nanoparticles is governed by the thermodynamic force ∇ µ$_{n}$ – i.e. that the nanoparticle current is j = − M$_{n}$ρ$_{n}$ ∇ µ$_{n}$ , where M$_{n}$ ( ρ$_{l}$ ) is a mobility coefficient that depends on the local density of the liquid. Combining this expression for the current with the continuity equation, we obtain the following evolution equation for the nanoparticle density profile Note that this equation of motion may also be obtained by assuming that the nanoparticles have over-damped stochastic equations of motion [80–83]. Here, we assume that M$_{n}$ ( ρ$_{l}$ ) = α Θ$_{s}$( ρ$_{l}$ − 0 . 5) , where Θ$_{s}$( x ) is a continuous function that switches smoothly from the value 0 to the value 1 at x = 0 (i.e. it is essentially a smooth analogue of the Heaviside function). This ensures that the nanoparticles are immobile when the local liquid density is small (dry substrate) and have a mobility coefficient α when ρ$_{l}$ is high (wet substrate). For the evolution of the liquid density distribution we assume that the liquid is able to evaporate from the surface into the vapour (reservoir) above the surface (non-conserved dynamics) and may 15 ∂ρ$_{n}$ ∂t = ∇ · [ M$_{n}$ρ$_{n}$ ∇ δF [ ρ$_{n}$, ρ$_{l}$ ] δρ$_{n}$ ] . (6) F [ ρ$_{l}$, ρ$_{n}$ ] = ∫ d r $^{[}$f ( ρ$_{l}$, ρ$_{n}$ ) + ε$_{ll}$ 2 ( ∇ ρ$_{l}$ ) 2 + ε$_{nn}$ 2 ( ∇ ρ$_{n}$ ) 2 + ε$_{nl}$ ( ∇ ρ$_{n}$ ) · ( ∇ ρ$_{l}$ ) − µρ$_{l}$ $^{]}$, (4) f ( ρ$_{l}$, ρ$_{n}$ ) = kT [ ρ$_{l}$ ln ρ$_{l}$ + (1 − ρ$_{l}$ ) ln(1 − ρ$_{l}$ )] + kT [ ρ$_{n}$ ln ρ$_{n}$ + (1 − ρ$_{n}$ ) ln(1 − ρ$_{n}$ )] − 2 ε$_{ll}$ρ 2 l − 2 ε$_{nn}$ρ 2 n − 4 ε$_{nl}$ρ$_{n}$ρ$_{l}$. (5)