Part one of the ditch logic

Ditch calculation is now ok, busu writing the code to draw the ditch