As much as anything else, it's the frequency of the waves that's important.
If you see a flotilla of anchored or moored yachts where the breeze is from one direction and the waves coming from side-on, some will be rolling like crazy and others relatively steady.
On another occasion, in apparently similar circumstances, the roles may be reversed.
The difference will be that the distance between wavecrests (which governs the frequency of their encounter with a fixed object) has changed.
Each vessel will have a natural frequency of rolling, which can be discovered by heaving once on a rope
attached to the mast
, led out sideways, in flatwater conditions. The yacht will then do several rolls at its natural frequency.
If the waves are arriving from the side at that frequency (or a frequency which is a small even multiple, or divides evenly into the natural frequency) the rolling tendency will be greatly accentuated, increasing with each roll until a maximum is reached.
One way to alleviate this is to align the boat with the waves, possibly with a bridle
. Another is to change the natural frequency, possibly by hauling something reasonably heavy up the rig. Like a child who persists in asking questions for reasons other than genuine curiosity.