lot of things

especially worked on effective_distance function...
not able to implement it with more then one node between...