Numerical treatment of the dynamics of a conserved order parameter in the presence of walls.
We discuss how the diffusive dynamics of a conserved order parameter should be numerically treated when impenetrable wall surfaces are present and interact with the degrees of freedom characterized by the order parameter. We derive the discretization scheme for the dynamics, paying particular attention to the conservation of the order parameter in the strict numerical sense. The discretized chemical potential, or the functional derivative of the free energy, contains a surface contribution inversely proportional to the grid spacing Delta z, which was proposed heuristically in a recent paper of Henderson and Clarke [Macromol. Theory Simul. 14, 435 (2005)]. Although apparently that surface contribution diverges in the continuum limit Delta z --> 0, we can show, by an analytic argument and numerical calculations, that this divergence does not yield any anomalies, and that our discretization scheme is well defined in this limit. We also discuss the correspondence of our treatment to the model proposed by Puri and Binder [Phys. Rev. A 46, R4487 (1992)] extensively used for the present problem.