Chapter 3

WAVES

Simulations / m-script
Beats / beats.m
Doppler Effect / doppler.m
Standing Waves in Air Columns / air_columns_m

3.? BEATS

Beats are heard when two sounds with slightly different frequencies f1 and f1 are sounded together. It is due to the interference between the two waves. Suppose that at a certain position the two waves are given by

(3.)

The resultant wave can be expressed as

(3.)

The cosine term varies with the average frequency of (f1 + f2)/2. The factor in front of the cosine term gives the envelope (or amplitude factor) which varies slowly with a frequency of |f1 - f2|/2. The ear responds to the intensity of the wave which varies as the square of the amplitude factor and goes through two maxima or minima per cycle, giving a beat frequency of

(3.)

M-scripting: beats.m

The m-script beats.m can be used to view the resultant wave produced by one wave with a frequency of 1000 Hz and the other of variable frequency and you can also listen to the sound of the beats.

M-script highlights

·  Graphical user interface.

·  Use of the Matlab sound command to listen to the beats.

Sample Results

The resultant wave for frequencies f1 = 1000 Hz and f2 = 1100 Hz are displayed in figure 3.x.

Figure 3.x Interference of two waves to produce a beat pattern.

Investigations and Questions

Inspect and run the m-script beats.m so that you are familiar with what the program and the code does. For a range of input parameters, view the plots and listen to the sounds. How does a plot relate to the sound?

1 Start with the two frequencies set at 1000 Hz. Increase the input frequency above 1000 Hz. Decrease the input frequency to values less than 1000 Hz. Observe the changes in the plots and the sounds.

2 Set the input frequency to f2 = 1100 Hz. Use the Data Cursor to measure the period of the rapid fluctuations and the period of the envelope. From the period measurements, calculate the frequencies of the rapidly varying fluctuations, the envelope and the beats. How well do your results agree with the theoretical results?

3.? DOPPLER EFFECT

When a source of sound and a listener are in relative motion to each other, the frequency heard by the listener is different to the source frequency. This phenomenon is called the Doppler Effect. The equation accounting for the change in the frequency observed by the listener due to the motion of the source and/or listener along the line joining them is

(3.x)

where fS is the frequency of the source, fL is the frequency observed by the listener, v is the velocity of sound in air, vS is the velocity of the source and vL is the velocity of the listener. Whether you use the + sign or – sign depends upon whether the frequency increases or decreases based upon: (1) If the listener moves towards the source the frequency increases (+vL) and when the listener moves away from the source the frequency decreases (–vL). (2) If the source moves towards the listener the frequency increases (–vS) and when the source moves away from the listener the frequency decrease (+–vL).

M-scripting: doppler.m

The m-script doppler.m is used for the simulation of a moving source and a stationary listener. The frequency of the source is fixed at fS = 1000 Hz and the speed of sound in air is vS = 340 m.s-1. The speed of the source is entered via the Command Window. The circles drawn on the plot represent the “wave crests” spreading out from the source. Each time the spacebar is pressed, the time is advanced with the source moving to the right and a new wave is generated. At the end of the simulation the frequency of the source is played followed by the sound heard by the listener directly in front of the source and then directly behind the source.

M-script highlights

·  Producing sounds at fixed frequencies using the Matlab sound command.

Sample Results

Figure 3.x shows the wave crests at the end of the simulation and the frequencies of the sounds played.

Fig. 3.x Doppler Effect for a moving source and a stationary observer.

Investigations and Questions

Inspect and run the m-script doppler.m so that you are familiar with what the program and the code does. For a range of input parameters, view the plots and listen to the sounds. How does a plot relate to the sound heard by a listener in front and at the rear of the moving source?

1 Start with a stationary source. Then increase the wave speed in increments of 50 m.s-1 up to 250 m.s-1. For each value of velocity use equation (3.x) to calculate the frequency fL heard by a listener directly in front and at the rear of the moving source and compare your results with those displayed in the plots.

2 Enter values of the speed of the source vS from 260 m.s-1 to 320 m.s-1 in steps of 20 m.s-1. Explain the experience of a sonic boom caused by an airplane flying overhead faster than the speed of sound. What is meant by a shock wave?

3 When vS > v, the source of sound is supersonic. Why is the Doppler Effect equation (3.x) is no longer valid?

4 Macn no.

5 wavlength

3.? STANDING WAVES IN AIR COLUMNS

The study into the vibrations of air columns is usually restricted to pipes of uniform cross-sectional area with the ends either opened or closed. However, using a numerical approach, the vibrations of the air inside wind instruments and the human vocal tract can be investigated which demonstrates many features of real musical instruments and the human voice. In a reed instrument such as the oboe, the air contained in a conical pipe is set into vibration by a pair of reeds beating. The beating frequency is determined by the interaction of the reeds with the normal modes of the air column. The pressure to drive the reeds is supplied by the player’s lips. The incoming air divides into two parts. One goes into the bore of the oboe and the other fills the space left after the deflection of the reeds. At any natural frequency of vibration, the maximum power can be transferred to the surrounding environment by the instrument.

In an electrical circuit, the current I through a circuit element depends upon the potential difference V across the element and its impedance Z or its admittance Y

(1) and

Using the analogy of an electric circuit, the motion of the vibrating air at a frequency f along the axis (X-axis) of a pipe with cross-sectional area S(x), the volume flow rate, V(x) depends upon the acoustic pressure p(x) and the acoustic impedance Z(x) or the acoustic admittance Y(x)

(2) and

where v is the speed of sound in air and r0 is the average air density and

(3) and

The simplest method to find the pressure p(x) along the pipe is by solving the two coupled first order difference equations given by equation (2) subject to the physical boundary conditions at the ends of the pipe. The boundary conditions at a closed end correspond to a pressure antinode (maximum) and a node for the volume flow rate (V = 0). The boundary conditions at an open end correspond to a pressure node (p = 0) and a antinode for the volume flow rate (maximum). The value assigned to the maximum value of p is not important, it only sets the amplitude of the standing wave.

In this simple model, all quantities are taken as real numbers, any dissipative and viscous effects are ignored and the phase remains constant in a plane perpendicular to the axis of the pipe. The steps in the numerical approach to find the natural frequencies of vibration (normal mode frequencies) and the pressure distributions are:

·  A frequency f is entered manually.

·  The Z and Y values are calculated for the frequency f.

·  The initial values for p and U are assigned at one end (x = 0) of the air column using the boundary conditions for either a closed or open end.

·  The difference equations, equation (2) are integrated step by step along the pipe to the other end using a second order Runga-Kutta procedure.

·  If the boundary conditions are satisfied at the far end of the pipe, the frequency f corresponds to one of the natural frequency of the pipe. If not, another valued of f is entered.

When a standing acoustic wave meets an open end of a pipe, the pressure to volume flow rate must match that of a spherical wave spreading out from a flat circular source. To meet this criteria, a rough rule of thumb is used for an end correction. When a pipe has an open end, it is stretch in length by the amount of 0.6 R, where R is the end radius of the pipe.

M-scripting: air_column.m

The m-script air_column.m can be used to model a number of musical instruments and the human voice tract for the sound”ah”. For an open end you can select to ignore or include the end correction.

M-script highlights

·  Graphical user interface.

·  A second order Runge-Kutta procedure is used to solve a coupled pair of first order differential equations:

for c = 2:num

phalf = p(c-1) + 0.5 * V(c-1) * Z(c-1) ;

Vhalf = V(c-1) - 0.5 * p(c-1) * Y(c-1);

p(c) = p(c-1) + Vhalf * Z(c-1);

V(c) = V(c-1) - phalf * Y(c-1);

end

·  A function is called to produce a sound at the frequency f that has been entered.

The data used for the trumpet and human voice track was taken from the paper by I. D. Johnston (Table xx). The numerical procedure used 2000 points for the calculations. To obtain 2000 points for the length and radius from the initial data, the following procedure using Matlab was done: (1) The trumpet data set was entered into two column vectors for the length and radius of the pipe. (2) The length (x) was plotted against the radius (y). (3) From the menu bar in the plot window: Tools / Basic Fitting / Shape preserving interpolant / 5 significant figures. (4) Find Y = f(X): define X range of values by linspace(min(L), Max(L), 2000). (5) Save data to Workspace as x_trumpet and y_trumpet. (6) Save variables to files: save x_trumpet and save y_trumpet. (7) The procedure was repeated for the human voice tract data with the data saved as x_voice and y_voice.

Sample Results

The sample results for a trumpet composed of a mouth piece (closed end), pipe and bell (open end) are given. The first five natural frequencies of vibration in hertz are

69.8 190.5 288.8 388.1 495.2

and the pressure distribution along the pipe for the frequency 388.1 Hz which corresponds to the 3rd overtone is shown in figure 1.

Figure 1. The shape of the trumpet and the pressure along the pipe for the 3rd overtone at the frequency f = 388.1 Hz.

Investigations and Questions

Inspect and run the m-script air_columns.m so that you are familiar with what the program and the code does. For a range of input parameters, view the output values and plots and identify how they relate to each other.

Cylindrical pipe: closed open

The clarinet is example of a musical instrument that is like a cylinder closed at the mouth end and open at the other end.

1 Find the first seven natural frequencies of vibration for an organ pipe of length L = 1.000 m and radius R = 0.100 m without the end correction. How are the natural frequencies of vibration related to the frequency of the fundamental (1st harmonic). From the shape of the pressure distribution, how can you tell which harmonic is excited in the pipe? How is the length of the pipe related to the wavelength for each harmonic?

2 Repeat investigation 1 with the end correction. How do your results change?

3 Investigate the changes in frequency and pressure as you change the length and radius of the organ pipe.

Cylindrical pipe: open open

4 Find the first seven natural frequencies of vibration for an organ pipe of length L = 1.000 m and radius R = 0.100 m without the end correction. How are the natural frequencies of vibration related to the frequency of the fundamental (1st harmonic). From the shape of the pressure distribution, how can you tell which harmonic is excited in the pipe? How is the length of the pipe related to the wavelength for each harmonic?

5 Repeat investigation 4 with the end correction. How do your results change?

6 Investigate the changes in frequency and pressure as you change the length and radius of the organ pipe.

Conical pipe (cone): open open

Many real wind instruments are conical in shape. Since the player has to blow into the narrow end, it is not completely closed.

7 Find the first seven natural frequencies of vibration for a conical pipe of length L = 1.000 m and radius R1 = 0.005 m and R2 = 0.100 m without the end correction. How are the natural frequencies of vibration related to the frequency of the fundamental (1st harmonic). From the shape of the pressure distribution, how can you tell which harmonic is excited in the pipe? How is the length of the pipe related to the wavelength for each harmonic?

8 Repeat investigation 7 with the end correction. How do your results change?

9 Investigate the changes in frequency and pressure as you change the dimensions of the pipe.

10 Show that the natural frequencies of the conical pipe are the same as a open / open organ pipe of uniform cross-section (cylinder) the same length.

11 Model a didjeridu, an instrument played by Australian aborigines.

Conical pipe (cone): closed open

In real instruments, the narrow end is always closed by a reed or the player’s lips, for example, the oboe and bassoon. A good musician can change from playing the first harmonic (fundamental) to the second harmonic by simply blowing differently. This is called overblowing to an octave.