implemented clark distance and their test