Counting the number of homonyms in dynamic networks