Let B ("black") and W ("white") be disjoint compact test sets in Rd and consider the volume of all its simultaneous shifts keeping B inside and W outside a compact set A⊂Rd. If the union B∪W is rescaled by a factor tending to zero, then the rescaled volume converges to a value determined by the surface area measure of A and the support functions of B and W, provided that A is regular enough (e.g. polyconvex). An analogous formula is obtained for the case when the conditions B⊂A and W⊂AC are replaced with prescribed threshold volumes of B in A and W in AC.
Applications in stochastic geometry are discussed. Firstly, the hit distribution function of a random set with an arbitrary compact structuring element B is considered. Its derivative at 0 is expressed in terms of the rose of directions and B. An analogue result holds for the hit-or-miss function. Secondly, in a desing based setting, different random digitizations of a deterministic set A are treated. It is shown how the number of configurations in such a digitization is related to the surface area measure of A as the lattice distance converges to zero.