implemented Dice similarity, distance and their test