Many partial differential equation models arising in applications generate complex patterns evolving with time which are hard to quantify due to the lack of any underlying regular structure. Such models often include some element of stochasticity which leads to variations in the detail structure of the patterns and forces one to concentrate on rougher common geometric features. From a mathematical point of view, algebraic topology suggests itself as a natural quantification tool. In this talk I will present some recent results for both the deterministic and the stochastic Cahn-Hilliard equation, both of which describe phase separation in alloys. In this situation one is interested in the geometry of time-varying sub-level sets of a function. I will present theoretical results on the pattern formation and dynamics, show how computational homology can be used to quantify the geometry of the patterns, and will assess the accuracy of the homology computations using probabilistic methods.