what causes square waves in the ocean