I think the dist function might be broken on wave-interference now, but I'm going to bed