WorksPhysics and Astronomy
The Stochastic Guitar
Abstract
Stochastic physics is a central pillar of modern research in many fields, but is rarely presented to undergrad students in a hands-on experiment. Here, we demonstrate how a human-scale, simple, and affordable experimental setup can be used to fill this gap, and to illustrate many advanced concepts in a step-by-step approach. Based on a metal wire (such as a guitar string), our setup facilitates the observation of fluctuating dynamics in the time domain, the frequency spectrum, and in the rotating phase space. The latter allows introducing time-dependent cross-correlations between the sine and cosine quadratures of the stochastic motion, which feature deterministic order even in the absence of any deterministic forces.
Introduction
The driven and damped harmonic oscillator is a textbook model equation that every physics student is familiar with. Application of this model can be found in every field of physics, from quantum optics to particle physics, biophysics, and astronomy. For that reason, the harmonic oscillator is also a popular experiment on display in many student labs and practical lecture experiments. Students typically learn about the oscillator’s resonance frequency , the rate of energy loss to the environment , and the corresponding quality factor . In the vast majority of student experiments, the harmonic oscillator is treated as a deterministic system without any noise.
The physics of the harmonic oscillator becomes much richer when a stochastic driving force is added. In this case, the oscillation has no definite amplitude and phase , but explores different values thereof as a function of time in a stochastic random walk. It is therefore generally impossible to predict and at any point in time in the future, and only statistical probabilities can be calculated. Such a scenario is immensely difficult to grasp for many undergraduate students for several reasons: (i) Dealing with probabilities instead of deterministic equations of motion requires very abstract thinking. (ii) Stochastic physics is not common, or at least not obvious, in our everyday lives. The systems that offer themselves for such studies, such as nanomechanical resonators, usually operate on scales of amplitudes and frequencies that are far from our intuition and hard to measure. (iii) Due to the stringent requirements for observing e.g. the Brownian motion of molecules, student labs rarely offer experiments to explore stochastic physics. Most students therefore only come into contact with this important aspect of physics when they perform projects in research groups. This is deplorable, as stochastic physics is not only a crucial element in many contemporary fields of physics, but also offers an excellent preparation for the stochastic phenomena encountered in quantum mechanics.
In this work, we describe a student lab experiment that allows observing the harmonic oscillator with a stochastic driving force. The experiment is based on a metal string whose fundamental resonance frequency is around 30 Hz and whose oscillation can be visible to the naked eye. In spite of these “human” scales, the string can be driven in a stochastic manner, and its displacement can be measured digitally with high precision. This results in rich measurement data and complex concepts, such as the rotating phase space, the power spectral density of different types of noise, the Parseval theorem, and the equivalent of under- or overdamped oscillations around the stationary solutions of an out-of-equilibrium system. The experiment offers motivated students a hands-on approach to many fascinating concepts, and a bridge to advanced experiments in research labs. In addition, the experiment is ideally suited for public demonstrations thanks to its accessible character: everybody loves a guitar!
Experimental Setup
The heart of our experiment is a metal string with a cross section of 0.15 × 0.9 mm made out of stainless steel, as inspired by previous experiments [1, 2]. The string is suspended between two clamping points with a separation of 275 mm, see Figure 1. The tension applied to the string can be used to tune its resonance frequencies. For our demonstration, we selected a relatively low tension, which results in low resonance frequencies and low frequency drift in response to temperature changes in the room. In the center of the string, we place a neodymium magnet. This allows us to apply a force to the string by running a current through a coil below the magnet. The displacement of the string is recorded through a piezo-electric crystal embedded in one of the clamping points. In this crystal, the pressure that the string exerts onto the clamping point is transduced into a voltage that we measure with a Zurich Instruments MFLI lock-in amplifier (any analog-digital converter would do).
Figure 1. Sketch of the setup
Deterministic Response
To probe the basic properties of our string, we apply an oscillating current to the coil. The current generates a force with amplitude and frequency . For fixed forcing parameters, the string “rings up” until it responds with stable oscillations at the driving frequency. This behaviour can be understood from the well-know equation of motion of a single harmonic resonator
where is the displacement of the string and is its effective mass. With the Ansatz , we can solve Eq. (1) and obtain for the long-time limit the amplitude
and the phase
In Figure 2, we show the result of such a measurement together with those of analytical expressions in Eqs. (2) and (3) for the fit values and .

Figure 2. Amplitude and phase of a measured frequency sweep (light blue) plotted versus the results of Eq. (2) and (3) (dark blue), using , , and a global phase offset of as free parameters. The measurement used 15 second waiting time between each point and steps of 10 mHz.
In the following, we will characterize and analyze our resonator in terms of the phase space quadratures and , which fulfill and [3]. These quadratures are the amplitudes of the two independent, fundamental solutions of the harmonic oscillator, . Via the averaging method [4, 5], we can transform Eq. (1) into so-called slow-flow equations, which are coupled first-order differential equations of the form
The slow-flow variables and correspond to the in-phase and out-of-phase channels of a lock-in amplifier and are therefore directly accessible in many experiments.
Stochastic Response
In order to observe stochastic physics, we replace the sinusoidal oscillating force by a fluctuating force of the form , which has the properties
where denotes the average in the long-time limit, is a time delay, is the delta function that is 1 for and 0 otherwise, and has the meaning of a force noise power spectral density [3].
The slow-flow Eqs. (4) and (5) are correspondingly modified to read
where the are fluctuating force terms whose standard deviation can be calculated from an integration of over one oscillation period [3]. These fluctuating force terms are still white and random on timescales , which is sufficient for all practical purposes.
The white force effectively drives the string at all frequencies simultaneously, producing the oscillation spectrum shown in Figure 3. In the frequency range between 0 and 100 Hz, we observe four peaks. The mode at 50 Hz is assigned to purely electrical noise induced by the local power grid, while a peak below 60 Hz may belong to the second vibrational mode of the string. The lowest mode at 28.5 Hz is our vibration mode of interest. Using the known value for and , we can reproduce its spectral signature with Eq. (2), using only the effective amplitude as a free parameter.

Figure 3. Frequency spectrum of the string driven by a fluctuating force with a standard deviation of 500 mV over a bandwidth of 30 MHz. We clearly see the resonance frequency at 28.5 Hz, the 50 Hz noise of the power grid, and a higher mode at roughly . A dark blue line is shows the result of Eq. (2) with the same parameters as in Figure 2.
The time response of the lowest oscillator mode to a stochastic force is shown in Figure 4. In this measurement, the quadratures and are directly measured with a lock-in amplifier with a local oscillator (a reference clock) at 28.5 Hz. Selecting a bandpass filter of 4.5 Hz ensures that signals from higher modes are rejected, even though they are driven by the white noise as well. We find that the resonator no longer rings up to a fixed solution as in the deterministic case discussed earlier. Instead, the quadratures slowly fluctuate in time around the mean values with a Gaussian profile.
Figure 4. The two quadrature signals in response to a fluctuating force term, measured as a function of time with a lock-in amplifier whose local oscillator matches .
To study the dynamics of the stochastically driven oscillator in more detail, we plot as a function of in
Figure 5. This representation is known as “phase space” and plays an important role in the visualization of classical and quantum oscillation states. In our classical case, the system can be located at a single point in phase space at any given time, and a stable solution appears as a single fixed point. For instance, setting and in Eqs. (4) and (5) results in two simple equations and .
Figure 5. Phase space representation of the string oscillations driven by fluctuating force terms. The quadratures and are measured with in a frame rotating a the local oscillator frequency of the lock-in, set as (a) 28.5 Hz and (b) 28.4 Hz (b). The starting point of the measurement is marked as a red dot, and the first 30 points are connected with a line to demonstrate a random walk for and counter-clockwise rotation for .
We plot the stochastic data similar to that in Figure 4 in phase space, see Figure 5(a). The system explores phase space in a random walk over time, leading to Gaussian probability distributions in both coordinates. As we selected for this measurement, the terms become zero in Eqs. (8) and (9) and the random trajectories in both coordinates are decoupled. Setting , the equations can be individually simplified to and . The trajectory of the system over time follows a random walk in both and independently.
Our observations become more intricate when we introduce a detuning of the measurement clock from the resonator’s eigenfrequency, . At first glance, the phase space representation in Figure 5(b) closely resembles the one in Figure 5(a). However, when we follow a short part of the trajectory, we find it to revolve around the origin with a defined orientation. This feature, which is absent in Figure 5(a), clearly stems from the terms in Eqs. (8) and (9), which create a correlation between and with a time delay. We can directly see this delayed correlation in Eqs. (8) and (9) by inserting and , which leads to the simple equations and with . When initialized at and , this system rotates around the origin with an angular frequency , such that a correlation between and appears after a quarter period (when and ). The sign of the correlation at this delay depends on the sign of , i.e., whether the rotation proceeds in clockwise or anti-clockwise direction.
To quantitatively analyze the effect of a detuned rotating frame in our data, we employ the delay-dependent covariance
where is the total number of data points in a measurement, runs over all measurement points that are separated in time by the increment , and is a time delay. Equation (10) is a covariance between and with a variable time delay . We expect to see maxima in whenever and values are correlated over a well-defined timescale , indicating a rotation with a well-defined period.
The results of Eq. (10) for measurements with different are shown in Figure 6, together with a heuristic theory line corresponding to , that is, an exponentially decaying oscillating correlation. Even though the full dependency of the covariance on is more complicated, this simple form reproduces our measurements qualitatively: detuning the measurement clock from the eigenfrequency leads to a periodic pattern in the measured time-dependent covariance , which decays under the influence of the dissipation term . The detuning therefore acts like a adjustable oscillation frequency in the rotating frame by generating correlations between and . For a given value of , we observe the rotating-frame analogue to an underdamped-to-overdamped transition between (red and blue traces in Figure 6) and (light orange to light blue traces). We have thus identified deterministic correlations in a system driven purely by fluctuating force terms.

Figure 6. Time-dependent covariance measured as a function of the time shift for different detuning . The data sets are offset vertically for better visibility, with dashed horizontal lines indicating in all cases. Solid lines correspond to the function with fitted for each curve individually.
Summary and outlook
In this work, we show how a simple and affordable guitar string setup can be used to demonstrate intricate physical phenomena. We start from the driven and damped harmonic oscillator, the most widely used model in physics, to describe the string oscillation to an external force. Building on this model, we introduce stochastic driving terms and observe the string’s spectral response. We also study the stochastic dynamics of the string as a function of time and in phase space, which allows us to appreciate the notion of a Gaussian amplitude distribution in both quadratures and the influence of the selected rotating frame. Finally, we manipulate the rotating frame rate to obtain a rotating-frame analogue to an underdamped-to-overdamped transition in the quadrature correlations.
In our opinion, such a demonstration has high didactic value, as it provides hands-on experience with the driven and damped harmonic oscillator, deterministic versus stochastic physics, temporal versus spectral information, the rotating frame, and phase space representation. These topics are relevant for many fields of modern physics, such as quantum optics, nanomechanics, radio-frequency and microwave electronics, and gravitation wave experiments. From a teaching perspective, introducing these concepts with an experiment is a valuable supplement to traditional lectures. In particular, the intuitive mechanics and macroscopic scale of the string resonator is beneficial to illustrate complex concepts in an accessible way.
Looking forward, we propose that the same string setup is also suitable to instruct students in nonlinear and parametric dynamics, especially the Duffing resonator, as well as parametric driving and squeezing [1]. These complex topics are often neglected in the experimental education of undergraduate students for lack of an affordable and easily maintainable experimental setup. Our guitar string offers a solution for this problem, and can serve as a catalyst to introduce students to a range of fascinating experimental techniques at an early stage in their curriculum.
List of student tasks:
Apply an oscillating drive voltage to the coil and measure the response voltage from the piezo with an oscilloscope. Look at the frequencies within the response by Fourier transforming it.
Change the frequency of the drive voltage and observe the change in the amplitude when this drive frequency is close to .
Measure both the drive voltage and the response voltage at the same time with the oscilloscope. How can you measure the phase in this way?
Measure the amplitude and the phase with a lock-in amplifier and plot it as a function of the driving frequency (a free software lock-in module is available here). Add matching lines corresponding to Eq. (2) and (3) and extract and in this way.
Replace the oscillating driving voltage with a white noise voltage and check that your noise is indeed white and has a Gaussian distribution in voltage. Measure the response of the resonator as a frequency spectrum. Fit Eq. (2) to your spectrum and extract and . Compare the spectrum of the resonator response to that of the white noise itself.
Measure and with a lock-in amplifier for different local oscillator frequencies, that is, detunings . Plot the results in a rotating phase space as in Figure 5 and determine the histograms in both quadratures. Pay attention to the sampling rate relative to . What is an ideal sampling rate, and why? Does impact the histograms?
Use Eq. (10) to obtain a delay-dependent covariance for every measurement and extract the true in each case. What is the origin of the deterministic order you find here?
The authors have no conflicts to disclose.
Acknowledgements: the authors thank Oded Zilberberg for useful discussions. Oliver Schwager and the mechanical workshop at the Physics Department of ETH Zurich contributed to the development of the setup.
References
References
- [1]Anina Leuch, Luca Papariello, Oded Zilberberg, Christian L. Degen, R. Chitra, and Alexander Eichler, “Parametric symmetry breaking in a nonlinear resonator,” Phys. Rev. Lett. 117, 214101 (2016).DOI
- [2]Alexander Eichler, Toni L. Heugel, Anina Leuch, Christian L. Degen, Ramasubramanian Chitra, and Oded Zilberberg, “A parametric symmetry breaking transducer,” Applied Physics Letters 112, 233105 (2018).DOI
- [3]Alexander Eichler and Oded Zilberberg, Classical and Quantum Parametric Phenomena (Oxford University Press, 2023).DOI
- [4]C. Holmes and P. Holmes, “Second order averaging and bifurcations to subharmonics in duffing’s equation,” Journal of Sound and Vibration 78, 161 – 174 (1981).DOI
- [5]Luca Papariello, Oded Zilberberg, Alexander Eichler, and R. Chitra, “Ultrasensitive hysteretic force sensing with parametric nonlinear oscillators,” Phys. Rev. E 94, 022201 (2016).DOI


