Mary was worried because her baby seemed restless while sleeping, moving his arms and legs, grimacing, and his eyes were darting beneath his eyelids. Mary's doctor is likely to tell her that the baby is experiencing: