perpPt function

Internal method for plotting. Finds a point d distance from x, y