Classify the coordinate data
Calcualte distance?

Distance = data2 - data1 = [(1,0), (2,0), (3, 7), (4, 7), (5, 7), (6, 0)]

And what will you treat as the same wave?

Any three (or more) nearby points that have the same distance...