Is there a natural way to define the 'distance' between two Boolean algebra homomorphisms $f, g: B \rightarrow B'$? I'm thinking of something like the Kullback leibeler divergence for probability functions. More specifically, if I have a Boolean algebra homomorphism $h: B \rightarrow B'$, what's the natural way to find the 'closest'/'most similar' homomorphism to $h$ that satisfies some extra constraint $c$ that is not satisfied by $h$? For example, if $x, y \in B$ and $\neg(h(x) \leq h(y))$, is there a natural choice of $g$ such that $g$ is the closest homomorphism to $h$ that satisfies $g(x) \leq g(y)$?