by counting or integrating cycles of oscillations