LAB 2: SPEED OF SOUND 1 Lab 2: Speed of Sound XXX Lab Partner: XXX XXX Date of Experiment: 12 February 2024 LAB 2: SPEED OF SOUND 2 Abstract This experiment aims to experimentally measure the speed of sound using an acoustic waveguide setup, then to determine the accuracy of the experimental results through error analysis and uncertainty analysis. The general procedure involved using the materials provided to take measurements of the time delay between two signals from microphones, use the time delay and the set frequency to approximate the experimental phase angle, and finally measure the speed of sound based on the measured distance between the two microphones and the slope from the least squares fit line of the frequency and phase angle plot. Sources of error arose during the experiment such as unexpected negative slope in the data, and a less than ideal correlation coefficient, but adjustments were made to ensure accuracy. The experiment resulted in the experimentally measured speed of sound to be πππ₯π = 323. 48 π/π , compared against a theoretical value of ππππ = 344 π/π yields a 5.96% error. The uncertainty analysis revealed that the calculated uncertainty was higher than expected, yet after finding the confidence interval of the experimental value, it was confirmed that the true value for the speed of sound lies within the confidence interval, indicating a successful uncertainty analysis. This experiment was important because being able to determine the speed of sound is crucial to many fields, such as the hypersonics industry, and by being able to experimentally determine the confidence interval for the true value allows general calculations to be used when deciding design characteristics. LAB 2: SPEED OF SOUND 3 Table of Contents Abstract...........................................................................................................................................2 Table of Contents........................................................................................................................... 3 Nomenclature................................................................................................................................. 4 Experiment 2: Speed of Sound..................................................................................................... 5 Required Equations....................................................................................................................... 5 Equations: Measuring Speed of Sound...................................................................................... 5 Equations: Uncertainty Analysis................................................................................................6 Experimental Apparatus and Procedure.....................................................................................7 Measuring Speed of Sound:....................................................................................................... 8 Uncertainty analysis.................................................................................................................10 Results and Discussion.................................................................................................................10 Results: Measuring the Speed of Sound.................................................................................. 10 Discussion: Measuring the Speed of Sound.............................................................................13 Results: Uncertainty Analysis..................................................................................................14 Discussion: Uncertainty Analysis............................................................................................ 16 Conclusion.................................................................................................................................... 18 References..................................................................................................................................... 20 Appendix.......................................................................................................................................21 LAB 2: SPEED OF SOUND 4 Nomenclature c Speed of Sound (General) τ Time Delay (General) Ο Phase Difference/Phase Angle (General) π Frequency x Measured Distance Between the Microphones πΟπ Standard Error of the Fit π‘π£,95% Student t-distribution π’π Statistical Uncertainty from the Slope ππ Precision Estimate N (K) Number of Measurements v Number of Measurements - 2 π’π₯ Uncertainty of Distance Between Microphones π’π Uncertainty in the Speed of Sound LAB 2: SPEED OF SOUND 5 Experiment 2: Speed of Sound The primary objective behind this lab is to evaluate the acoustic waveguide as a way of measuring the speed of sound in the air, in other words, to measure the speed of sound from the phase delay between two microphones. In addition to measuring the speed of sound, based on the results from the experiment, an uncertainty analysis is to be conducted to determine the confidence interval of the least squares fit, statistical uncertainty from the slope of the fitted curve, and relative uncertainty in the measurement of the speed of sound. Per the lab manual provided during the experiment, a speaker is driven by a function generator through a power amplifier, the speaker then produces a sound wave that travels through the acoustic waveguide assembly at the speed of sound. Then, two microphones that the experiment uses measure the acoustic wavelength from the sound, and by finding the time delay between the two microphones, a phase difference between the signals is found, allowing the speed of sound to be approximated. Required Equations Equations: Measuring Speed of Sound This experiment is split into two parts: the estimate of the speed of sound, c, and then the uncertainty of analysis. The main value that was measured from this lab was τ, known as the time delay between the signals, which is measured in µπ (with the signals being the two microphones), and the value that the experimenter set was the frequency, which is measured in Hz. The time delay produces a phase difference, Ο, between the two signals, and this phase difference is used to approximate c, which is the speed of sound. Using the definition of the time delay, τ: τ = π₯ , where x is measured as the distance between the two microphones. π The definition of phase difference, Ο, is defined as : (1) Ο = 2πτ π = 2ππτ, where T is the period, so 1/T = the frequency, The definition for the phase difference can be rewritten as: LAB 2: SPEED OF SOUND 6 Ο= 2ππ₯π π By isolating the speed of sound and noting that the phase angle is measured at different frequencies, the speed of sound can be experimentally determined as: 2ππ₯ (2) c = πΟ/ππ where πΟ/ππ is the slope of the frequency vs the phase angle, which can be found by plotting the linear line of best fit of the experimentally collected values. Equations: Uncertainty Analysis The confidence interval of the least squares fit using the standard error of the fit, πΟπ, is defined as: (3) Ο = (Οπ + π · π) ± π‘π£,95% · πΟπ(95%), where (Οπ + π · π) is found from the fitted line from the experimental data, π‘π£,95% is the student t distribution value found in the appendix (A-3), ν is defined as the number of data points (N) - 2, ± π‘π£,95% · πΟπ(95%) is the confidence interval, πΟπ is the standard error of the fit, defined as: πΎ (4) πΟπ = 2 ∑ [Οπ−(Οπ+π·ππ)] π=1 π£ , using the same definitions as (3). Secondly, the statistical uncertainty from the slope of the least squares fit, (the linear line of best fit from the experimental data), π’π, defined from the precision estimate, ππ, is: (5) π’π = π‘π£,95 · ππ, where π‘π£,95 is the same as the calculated value from the confidence interval analysis. NOTE: K is just an index to account for each test, K=N) ππ used in (5) is the precision estimate of the least squares fit, defined as: (6) π = πΟπ · π π πΎ 2 πΎ 2 π ∑ ππ −[ ∑ ππ] π=1 π=1 , which use the same definitions (3) LAB 2: SPEED OF SOUND 7 Lastly, the relative uncertainty of the calculated speed of sound, π’π, is calculated by using the uncertainty in the slope, π’π, and the uncertainty in the measurement between the two microphones, π’π₯. Since the speed of sound is dependent upon two independent factors from each other, x, the distance between the two microphones, and πΟ/ππ, which is the slope of the fitted line, the uncertainty of the speed of sound would only be dependent on the uncertainty in the slope and the uncertainty of the measurement between the two microphones. Relative uncertainty, by definition, is defined as the calculated uncertainty divided by the measured value. It is important to note that π’π₯ is found from the actual equipment, which is from a caliper that was used. The particular caliper that was used in this experiment had an uncertainty of ± 0. 001ππ. By using the root-sum-squared method, and the relative uncertainty of both π’π and π’π₯, defined as π’π π’ and π₯π₯ , respectively, the relative uncertainty of the speed of sound is π found by: π’ (7) ππ = π’ π’ 2 2 [ π₯π₯ ] + [ ππ ] , where all values π’π are previously computed/experimentally calculated. To solve for the uncertainty in the measurement of the speed of sound, simplify equation (7) to: (8) π’ = π · π π’ 2 π’ 2 [ π₯π₯ ] + [ ππ ] Experimental Apparatus and Procedure In addition to the Lab Manual, the following experiment was used in this lab: Acoustic Wave Guide 1 - Caliper Oscilloscope-Hitachi VC-6020 2 - microphones Function Generator-HP 33120A 1 - feed through terminator 50β¦ Power Amplifier The final experimental set up is shown below: LAB 2: SPEED OF SOUND 8 Figure 1: Final Experimental Setup Measuring Speed of Sound: The following steps were taken to experimentally measure the speed of sound, c. 1) Before installing the two microphones, measure the distance between the two microphone ports on the waveguide. a) After obtaining the distance, the uncertainty of this measurement was found using the caliper's specifications. 2) Insert the microphones into the waveguide. 3) As seen in Figure 1, connect the function generator to the TAPE/TUNER input of the power amplifier, ensuring that the 50β¦ feed through terminator is connected in-line between the function generator and the power amplifier. Then, connect the speaker on the waveguide to the SPEAKERS output of the power amplifier. Lastly, connect the microphones to the oscilloscope. a) Verify that the speaker is on the channel to which the function generator is attached b) The microphone closest to the speaker should be connected to CH1, and the microphone closest to the damper should be connected to CH2 LAB 2: SPEED OF SOUND 9 4) On the function generator, first select a 1-kHz, 100mVPP sine wave and take note of the microphone signals on the oscilloscope, click auto-range to automatically scale the waves. 5) This next step requires the time delay to be measured. On the oscilloscope, click the measure button, and then select time delay. Then, vary the frequency from 1kHz to 3.0kHz in increments of 10Hz (using the function generator) a) The result will most likely be in microseconds, so be sure to take note of that and convert the time delay from microseconds to seconds before doing calculations 6) Measure the time delay at each frequency, and then compute the phase angle for each frequency using equation (1). a) As previously mentioned, it is very important to compute the phase angle using the time delay in SECONDS, not microseconds. b) Additionally, if the time delay is a negative value, add a period to the time delay (in seconds). This is done by adding 1/f, or 1/frequency (Hz), to the time delay (s) 7) Input all of the collected data into Excel and plot the phase angle versus the frequency (with the phase angle on the y-axis and the frequency on the x-axis) a) Whatever spreadsheet software that can create plots and provide data from the plots can be used, however, the following steps use Excel. b) Ideally, the data should fall on a straight line of best fit, in reality, this most likely is not the case. 8) On the plot, select the “+” sign, click Trendline > More Options > Linear > Display Equation on chart > Display R-squared value on chart. a) The equation that is displayed on the chart for the line of best fit (otherwise known as the least squares fit of a straight line) must be of the form “y = mx+b”, which correlates to the (Οπ + π · π) portion of equation (3). Where m is the slope of the least squares fit., which is πΟ/ππ for equation (2) 2 b) The π value that is displayed is the correlation coefficient between Ο & π, the closer to 1, the the more linear the data is LAB 2: SPEED OF SOUND 10 9) After step 8, the experiment itself is done. Use the measured value for the distance between the microphones, x, and the slope of the least squares fit, m, and equation (2) to calculate the experimental for the speed of sound, c. Compare the experimental value for c to the theoretical value, which ideally is Uncertainty analysis The equations that were listed in the “Equations: Uncertainty Analysis” were all computed for the uncertainty. NOTE: All of the following calculations can be done in Excel, however, the () section will show the order of the equations used during the analysis. 10) To obtain a confidence interval of the least squares fit, the π‘π£,95% · πΟπ(95%) portion of equation (3), use equation (4) to first find πΟπ and then the student t distribution table in the appendix as well as v = N-2 = 20-2 = 18 to find π‘π£,95%. 11) To obtain the statistical uncertainty of the slope using the precision estimate, first use equation (6) to find the precision estimate, π , using the same πΟπ found in 10), and π then, use equation (5) using the same π‘π£,95% found in 10) to find the statistical uncertainty. a) Plot the precision error on the chart as an error bar. On Excel, this is done by clicking the chart > “+” sign > Error Bars > More Options > Fixed Value, and then typing in the found statistical uncertainty. 12) Lastly, to obtain the uncertainty in the measurement of the speed of sound, equation (8) is used, utilizing the experimentally measured/calculated values of c, m, and x, as well as the uncertainty value found from 11) and the uncertainty of the caliper (± 0. 001ππ) Results and Discussion Results: Measuring the Speed of Sound Starting with the experimental results from Measuring the Speed of Sound, the distance between the two microphones was first calculated, where: π₯ = 139. 025ππ = 0. 139π Additionally, the caliper used indicated an uncertainty of ± 0. 0010ππ, so: LAB 2: SPEED OF SOUND 11 π’π₯ = 0. 0010mm Next, the following chart was generated in Excel, showing the experimentally calculated values for the Frequency in Hz (set by the experimenter), Time Delay in both microseconds and seconds (measured), and the Phase Angle in radians (calculated from the frequency and the time delay): Figure 2: Experimentally Collected Values. In the chart above (Figure (2)), the frequency and time delay in SECONDS were both used to calculate the phase angle, in radians, using equation (1). The three highlighted rows have a time delay that has an unexpectedly low value. As mentioned in the procedure, to account for these errors, the period for that particular frequency is added to the time delay. For example, in Row 1: τ = τπ’πππ₯π + 1 π −6 1 = (− 428 × 10 ) + 1000 = 0. 000572 π −6 where τπ’πππ₯π is the unexpected value for the time delay, (− 428 × 10 ) is the conversion of 1 1 the time delay from microseconds to seconds, and 1000 is the the period for this test, π . LAB 2: SPEED OF SOUND 12 The experimental values generated were used to generate the frequency versus the phase angle graph, seen below: Figure 3: Phase Angle (Radians) vs. Frequency (Hz). The data points that were collected are shown by the big blue dots on the solid curved line. The dotted blue line going through the data is the line of best fit, or the least squares fit, for this data set. In the upper right hand 2 corner, the equation for the line of best fit is shown, as well as the π value. 2 In the highlighted box in the above image (Figure(3)), the π value is displayed, as well as the 2 line of best fit. The π value is the coefficient of correlation between Ο & π , and it was found that: 2 π = 0.9908 2 In addition to the π value, the equation for the line of best fit is displayed, where: Fit: π¦πππ‘ = − 0. 0027π₯πππ‘ + 6. 3429 The equation of the line of best fit is also known as the least squares fit of a straight line to the data. Rewriting the equation in terms of the phase angle and the frequency, the following equation is generated: Ο = (Οπ + π · π) => π¦πππ‘ = − 0. 0027π₯πππ‘ + 6. 3429 LAB 2: SPEED OF SOUND 13 => Οππ₯π = (6. 3429 + (− 0. 0027) · π) Where Οππ₯π corresponds to π¦πππ‘, π corresponds to π₯πππ‘, Οπ corresponds to the y-intercept, 6.3429, and m corresponds to the slope, -0.0027. The slope of Οππ₯π can be rewritten as πΟ/ππ, so to experimentally determine the speed of sound, use equation (2) with the experimental slope and measured distance between the microphones (0.139m), where: 2ππ₯ 2π(0.139) c = πΟ/ππ = |−0.0027| = 323. 48 π/π This experimental value for the speed of sound can be compared against the theoretical value for the speed of sound. For a perfect gas c = 344m/s. So the error analysis follows as: πβππππ¦ − πΈπ₯ππππππππ‘ | | 344−323.48 | × 100 = 5. 96% % πππππ = || | × 100 = | | πβππππ¦ 344 Discussion: Measuring the Speed of Sound The experimental measurement of the speed of sound was calculated to be 323.48 m/s and was compared against a theoretical value of c = 344 m/s, yielding a percent error of 5.96%. Across the duration of this experiment, there were a few indicators that could have been a source of error during the experiment. First, the acoustic waveguide was not completely insulated inside of a sound proof box. Since there were other sounds in the lab such as other people talking as well as other people conducting the experiment, there is a chance that our microphones could have picked up some unwanted sounds, thus causing an incorrect reading for the time delay, in turn causing an incorrect calculation for the speed of sound. This incorrect reading may have been a possible reason why there was a flatter line around a phase angle of 1 radian from 1800 to 2200 Hz. LAB 2: SPEED OF SOUND 14 Another source of error during the experiment was that the original slope for the line of best fit was found to be negative, which goes along with the data. This negative sign was not expected, as the derived equation for the speed of sound, equation (2), only called for the slope as measured. However, if the measured slope was used in equation (2) as is, the speed of sound would be calculated as a negative value, which is not possible as speed cannot be negative. As a result, it was determined that the absolute value of equation (2) would yield the correct experimental value for the speed of sound, which only required taking the absolute value of the slope. A final error that was seen after plotting the data was that the correlation between the 2 phase angle and frequency was not 1, instead being π = 0.9908. This value indicates that the data itself was not completely linear, which is the theoretical trend. Despite this correlation value not being 1, with a percent error of 0.92%, calculated as: % πππππ = || πβππππ¦ − πΈπ₯ππππππππ‘ | | × 100 πβππππ¦ = || 1−0.9908 | | × 100 1 = 0. 92% The line of best fit was still a pretty accurate fit for the nonlinear data values that were experimentally generated. Overall, the experiment yielded an equation for the phase angle in terms of frequency with a correlation coefficient proving that the line of best fit is 99.08% accurate. Results: Uncertainty Analysis To obtain the confidence interval from the standard fit, equation (3) was primarily used. It is important to note that the equation for the phase angle in terms of the frequency is required, but this was previously calculated as: Οππ₯π = (6. 3429 + (− 0. 0027) · π) LAB 2: SPEED OF SOUND 15 What first needs to be calculated to use equation (3) is π‘π£,95%, the student t distribution, which can be found using the table in the appendix (A-3). With a total of 20 measurements that were taken, v is now found, where: ν = πππππ π’ππππππ‘π − 2 = 20 − 2 = 18 So taking the value of ν and plugging that into the student t distribution equation, it can be seen that the value needed from the table and the respective answer is: π‘18,95% = 2.101 In addition to the student t distribution, the standard error, πΟπ, is required, computed below as: πΎ πΟπ = 2 ∑ [Οπ−(Οπ+π·ππ)] π=1 π£ = 0.52252 18 = 0. 170 NOTE: Standard Error Analysis computed in Excel is added in the appendix, A-4 Taking the standard error and the student t distribution values, the confidence interval for equation (3) can be found, as: Ο = (Οπ + π · π) ± π‘π£,95% · πΟπ(95%) => Οππ₯π = (6. 3429 + (− 0. 0027) · π) ± 2. 101 · 0. 170 => Οππ₯π = (6. 3429 + (− 0. 0027) · π) ± 0. 35717 In interval format: − 0. 35717 ≤ Οππ₯π = (6. 3429 + (− 0. 0027) · π) ≤ 0. 35717 LAB 2: SPEED OF SOUND 16 To obtain the statistical uncertainty of the slope, equation (5) is primarily used. Before using this equation, the previously calculated value for the student t distribution, π‘18,95% = 2.101, and the precision estimate for the least squares fit, ππ is required. Note that ππ uses the previously calculated value for the standard error, πΟπ= 0.170. The precision error is calculated below: ππ = πΟπ · π πΎ πΎ 2 2 = 0. 170 · π ∑ ππ −[ ∑ ππ] π=1 −5 20 5 2 20(917*10 )−(42000) = 9. 086 * 10 π=1 NOTE: Standard Error Analysis computed in Excel is added in the appendix, A-5 Using the precision estimate and the student t distribution, equation (5) yields: −5 −4 π’π = π‘π£,95 · ππ = 2. 101 · (9. 086 * 10 ) = 1. 909 * 10 This uncertainty generally makes sense due to how small the slope is. Finally, to find the total uncertainty in the measurement of the speed of sound, equation (8) is used with all of the previously calculated and experimentally collected values, as: π’π = π · π’ 2 π’ 2 [ π₯π₯ ] + [ ππ ] = 323. 48 · −4 2 0.0010 2 1.909*10 β€ β‘ β‘ 0.139 β€ + β’ −0.0027 β₯ = 32. 6 π/π β£ β¦ β£ β¦ NOTE: The relative uncertainty for π’π using equation (7) is π’π = 0.100. Discussion: Uncertainty Analysis Two more graphs were generated from the uncertainty analysis, both derivations from Figure (3). First, is the graph of the phase angle versus the frequency showing the confidence interval using the error bars. The general idea behind adding errors to the data is to show the uncertainty of each data point, indicating that the true value is within an interval of the experimentally measured value. ()The error bars are depictions of the confidence interval applied to each data point, seen below: LAB 2: SPEED OF SOUND 17 Figure 4: Uncertainty in the Line of Best Fit using Error Bars Second, the graph of the phase angle versus the frequency shows the confidence interval using two other linear fit lines, one adding the uncertainty to the line of best fit (the orange/top line) and one subtracting the uncertainty from the line of best fit (the green/bottom line). The chart with the data used to graph the uncertainty lines is included in the appendix, A-8, as: LAB 2: SPEED OF SOUND 18 Figure 5: Uncertainty in the Line of Best Fit using Parallel LInes It can be seen that the uncertainty lines enclose all of the data, therefore, the correct confidence interval for the line of best fit was calculated. Despite the correct confidence interval being calculated, the uncertainty for the speed of sound has an unexpectedly high value. Ideally, the uncertainty would be smaller, indicating that the experimental value is closer to the theoretical value, however, since the experimental value is further away, the uncertainty is higher, which could indicate an incorrectly measured value during the experiment. However, using the idea that the true value will be within the confidence interval, it can be found that: πππ₯π − π’π ≤ ππ‘ππ’π ≤ πππ₯π + π’π => 290. 88 ≤ 344 ≤ 356. 80 Since the above statement is true, it can be seen that the true value for the speed of sound lies within the confidence interval calculated, indicating that the experimental uncertainty for the speed of sound is accurate. Conclusion This lab was focused on experimentally determining the speed of sound in the air using an acoustic waveguide setup and then conducting an uncertainty analysis to determine the confidence intervals of the experimentally collected values. It was found that experimentally, the LAB 2: SPEED OF SOUND 19 speed of sound was found to be πππ₯π = 323. 48 π/π , and when compared against a theoretical value of ππππ = 344 π/π , the relative percent error was found to be 5.96%, a respectably low error, indicating that the experiment yielded relatively accurate data. However, some errors were noticed in the experiment, ranging from needing to adjust equations due to receiving an impossible measure of speed to having a less-than-ideal value for the measurement of the correlation coefficient (with a percent error of 0.92%). Despite these errors, uncertainty analysis proved that the experimentally found that the −4 uncertainty for the slope was π’π = 1. 909 * 10 , the uncertainty for the caliper was π’π₯ = 0. 0010ππ, and the uncertainty for the speed of sound was found to be π’π=32.6 m/s. After analyzing the confidence interval for the speed of sound, π’π, it was found that the true value for the speed of sound lies within the confidence interval, indicating that the calculated value is correct. Additionally, it was found that after plotting the line of best fit Οππ₯π = (6. 3429 + (− 0. 0027) · π) ± 0.35717 with the confidence interval (Figure ()) , it was deemed that with the uncertainty interval, all of the experimentally collected data values were between the interval, validating the accuracy using uncertainty analysis. This analysis proves that despite the experimental errors that arose, overall, the experiment was successful. LAB 2: SPEED OF SOUND 20 References Figliola, R. S., & Beasley, D. E. (2010). Theory and Design for Mechanical Measurements (5th ed.). Wiley. Lab Manual 2: Speed of Sound LAB 2: SPEED OF SOUND 21 Appendix A-1 - Figure 1: Final Experimental Setup, setup notes and required measurements to be collected will be explained in the following sections. Additionally, the “Dampening Material '' is only added to ensure that the generated sound does not reverberate back towards the microphones, which would cause incorrect signals to be projected on the oscilloscope, thus affecting the time delay. LAB 2: SPEED OF SOUND 22 A-2: Figure 2: Experimentally Collected Values. The Frequency was set by the experimenter (column 1), the oscilloscope captured the time delay in microseconds (second column), the time delay was the converted from microseconds to seconds (third column), and the phase angle was calculated from the frequency and the time delay in seconds by using equation (1) (fourth column). LAB 2: SPEED OF SOUND 23 A-3: Student t-distribution table, used to calculate the t value required for the calculations for the uncertainty LAB 2: SPEED OF SOUND 24 A-4: Standard Error Analysis performed in Excel. The data values on the left is the experimental values for the phase angle, and the computations on the left sums Οπ − (Οπ + π · ππ) for the whole experiment, finds the value for v, and the computes the standard error using equation (4) LAB 2: SPEED OF SOUND 25 A-5: Precision Estimate Analysis performed in Excel. The data values on the left are the frequency values used in the experiment, and the values on the right complete the rest of the required values to properly use equation (6) such as the (sum of the frequency)^2, the sum of the (frequency^2), and the standard error. LAB 2: SPEED OF SOUND 26 A-6: Figure (4): Error bars applied to each data point of Figure 3, depicting the confidence interval being applied to each data point. The true value of the phase angle at each set frequency is within the interval shown by the red bars. LAB 2: SPEED OF SOUND 27 A-7 Figure (5): This image depicts the uncertainty of the line of best fit for the Phase Angle vs. Frequency data set. The upper line shows the line of best fit with adding the uncertainty (labeled “Phase Angle + uc”) and the lower line shows the line of best fit with subtracting the uncertainty (labeled “Phase Angle - uc”). The blue dotted line is the same line of best fit shown in Figure 3 (labeled Linear (Recorded Values)) LAB 2: SPEED OF SOUND 28 A-8: Data used to graph the uncertainty lines. LAB 2: SPEED OF SOUND 29 A-9: Data Collected in Lab with TA Signature