# String Modeling

In this section, we investigate digital waveguide methods for modeling simple string instruments. We also look at ways of modeling the way traveling-wave components propagate through'' impedance discontinuities.

## Rigid and Free Terminations

• At a fixed end, the string's transverse displacement is zero. Consider the general traveling wave solution to the wave equation: y(t, x) = y+(ct - x) + y-(ct + x). If the string is fixed at x = 0, then y(t, 0) = 0 and y+(ct) = -y-(ct), which indicates that displacement traveling waves reflect from a fixed end with an inversion (or a reflection coefficient of -1).

• Since the displacement at a rigid termination is always zero, the physical velocity must also be zero for all time. Therefore, traveling-wave components of velocity will also reflect with a reflection coefficient of -1 at such a boundary.

• Force and velocity traveling-wave components are related by the wave impedance as f+ = Rv+, f- = -Rv-. At a rigid terminiation, v+ = -v- (from above). Thus, force wave components can be related at a rigid termination as:

f+ = R v+ = R (-v-) = -R v- = f-.

From this, we see that traveling-wave components of force are related by a reflection coefficient of +1 at a rigid termination.

• At a free end, because no transverse force is possible. At such a boundary, traveling-wave components of force must reflect with a coefficient of -1. To determine the reflection coefficient for displacement waves, we first note that force waves are proportional to the string slope. Differentiation of our general traveling-wave solution by x leads to (see this link):

After integrating this expression with respect to time, we have y+(t) = y-(t) at x = 0, indicating that displacement traveling waves reflect with a coefficient of +1.

## The Ideal Plucked String

• The simulation of displacement wave motion in a string rigidly terminated at both its ends (and without losses) is shown in the figure below.

• An ideal plucked string is defined as having an initial displacement and zero initial velocity. In the model, the delay lines should be initialized with displacement data corresponding to some arbitrary initial string shape (as illustrated in the figure above by the dashed lines).

• Because the physical displacement of a string is given by the superposition of left- and right-going traveling waves, the initial amplitude of each delay-line section should be half the amplitude of the initial, physical string displacement.

• The initial displacement shape must be bandlimited to have the discrete-time sample rate. Because sharp corners imply an infinite bandwidth, plucking points should be rounded to some extent. In fact, this is physical given the stiffness of real strings and the finite size of plectra.

• It is possible to use digital waveguide models to simulate other wave variables as well, such as velocity or acceleration waves. Note that an ideal pluck shape corresponds to an acceleration impulse.

• For the moment, we ignore the fact that the string vibrations are influenced and filtered by the body resonances before being transmitted into the air.

## The Ideal Struck String

• An ideal struck string involves zero initial displacement and a nonzero initial velocity distribution.

• For the struck string, simulation of velocity waves is possible. Alternately, the initial velocity distribution could be integrated with respect to x from x=0, divided by c, and negated in the upper rail to obtain the equivalent initial displacement (since , where R is the wave impedance of the string).

## The Damped Plucked String

• Ideal, lossless wave propagation does not occur in nature. As a first approximation to real propagation losses, we can make the substitution

in each delay line to obtain exponentially decaying traveling-wave propagation.

• Because the system is linear and time-invariant, these distributed loss factors (g) can be commuted or lumped together and implemented at discrete points. For a delay line of length N, the commuted factor would equal gN.

## Frequency-Dependent Damping & Stiffness

• A more accurate representation of propagation loss should be frequency-dependent. In general, damping will increase with frequency.

• Losses in strings have been investigated by Valette (1995), with the main mechanisms involving the viscous effect of the surrounding air, viscoelasticity and thermoelasticity of the string material, and internal friction representing both macroscopic rubbing (in multi-stranded and overwound strings) and inter-molecular effects (in monofilament strings).

• To implement frequency-dependent loss, each scale factor g of the previous section must be replaced by an appropriately designed digital filter. Because the system is still linear and time-invariant, these filter responses can also be commuted and implemented as a single string loop filter .

• In order to maintain stability (passivity), .

• A string fixed at both ends can be implemented with two delay lines, a discrete-time filter representing losses and inversion at the bridge, and an inversion representing reflection from the nut, as shown below. Additional simplifications are possible.

• String stiffness produces dispersion, or a variation of wave propagation speed with frequency. The use of an allpass filter in the string loop is effective in accurately simulating such dispersion.

## Commuted Waveguide Synthesis

Plucked string instruments are well modeled as linear systems and this allows great flexibility in the way they are implemented. Commuted synthesis takes advantage of this fact and provides a highly efficient way of producing high quality plucked-string sounds.

• The model components discussed thus far only account for vibrations of the string. In order to convincingly simulate a complete string instrument system, we must also account for the bridge and body response, as well as radiation patterns into the surrounding environment.

• Assuming we could develop representative filters for the various components of a string instrument, the output response of the complete system would be diagrammed and computed as shown below:

• For plucked or ideally struck strings, each component of the system is linear and time-invariant. Therefore, the system components can be rearranged without affecting the overall output.

• The body response of a string instrument is complex and generally requires a high-order digital filter to accurately simulate. However, by taking advantage of system commutativity, it is possible to record a body impulse response'' and use it as the string excitation. This technique is referred to as commuted waveguide synthesis. As shown, it is also possible to commute the radiation directivity response.

## Commuted Synthesis Extensions

• From string acoustics, we know that a string plucked at 1/nth the distance from one end will not have energy at the nth partial and its integer multiples.

• If we initialize the delay lines of a waveguide model with a particular plucked string shape, the pluck position filtering'' is automatically included (it's defined by the initial energy profile that is defined by the initial shape).

• In practice, however, the delay lines are either initialized with noise or driven with an external input signal (in which case they are initialized with zeros).

• For commuted synthesis, it is possible to pre-filter the input signal with a given pluck position filter. To maintain synthesis parameter flexibility, this is typically done during the synthesis computation.

• Pluck position filtering can be simulated with a feedforward comb filter, which creates notches in the frequency magnitude response at equal frequency intervals.

• For bM > 0, there are M peaks in the frequency response, centered about the frequencies . Between these peaks, there are M notches at intervals of fs/M Hz.

• When using commuted synthesis, body size can be roughly simulated with the body response playback rate, which shifts the body resonances higher or lower in frequency. This technique is demonstrated in the STK Mandolin class, implements commuted synthesis of a two string mandolin instrument.

## Wave Scattering

• When a traveling-wave component experiences a change in wave impedance, it will be partly reflected from and partly transmitted through the impedance discontinuity in such a way that energy is conserved. This is referred to as wave scattering.

• Figure 5 depicts a string density discontinuity and associated traveling force wave components on each side of the junction.

• At the junction, we must have continuity of the medium, or there must be a common transverse string velocity at that point. Similarly, the forces on each side of the junction must be balanced.

• These constraints can be written

• Let v denote the common transverse velocity of the string at the junction. Then the traveling-wave components of velocity can be written vi = v+i + v-i or v-i = v - v+i.

• We can then write

which implies

• Solving these expressions in terms of the outgoing traveling-wave components,

• It is standard to define the reflection coefficient

which then allows us to write

• Figure 6 provides a block diagram implementation of the equations above. This is equivalent to a Kelly-Lochbaum junction representation (Kelly and Lochbaum, 1962).

• The scattering equations can also be written

which requires only one multiplication and three additions (as diagrammed in Fig. 7).

## Coupled Strings

• Figure 8 depicts the case of two strings that terminate at a common, non-rigid bridge of impedance .

• The constraints at the junction are:

• The bridge impedance relates the force and velocity at the bridge as .

• Expanding the traveling wave components in the frequency domain,

or

where Ri is the impedance of string i and

• In the time-domain, we scale each incoming string velocity, sum them together, and filter according to the transfer function to obtain the velocity of the bridge.

• The subsequent outgoing velocities are then found by

• This analysis can be generalized to the case of N coupled strings without much difficulty.

## Coupled Dimensions of Vibration

• In real string instruments, wave motion is possible in at least four dimensions corresponding to horizontal and vertical transverse motion, longitudinal motion, and especially for bowed strings, torsional waves.

• If the string terminations were perfectly rigid, the horizontal and vertical transverse polarizations would be largely independent and we could model them with two identical, uncoupled, filtered delay loops, as shown in Fig. 9..

• For terminations that are yielding to some extent, there will be coupling between various planes of vibration. We can simulate linear coupling with digital filters that connect the two planes of vibration together (as shown in Fig. 10 below).

• If the coupling is symmetric, Hvh(z) = Hhv(z).