Cross-count identity, distinctness, and the theory of internal and external relations