5 Lab1 Numerical Methods handout PDF

Title 5 Lab1 Numerical Methods handout
Course Instrumentation and Measurement Laboratory
Institution University of Massachusetts Lowell
Pages 4
File Size 171.8 KB
File Type PDF
Total Downloads 9
Total Views 158

Summary

Lab 1 Summary ...


Description

22.302 Experiment #1 Numerical Methods Using Excel Introduction Excel is a spreadsheet software package that can be used for data reduction, analysis, and presentation. Throughout the mechanical engineering laboratory course sequence, Excel can be used to perform least squares curve fitting, numerical differentiation, numerical integration, and experimental data analysis. The purpose of this experiment is to perform linear regression analysis on experimental calibration data. Numerical differentiation will be performed on displacement and time data obtained from a free falling weight; this will result in the determination of the object's acceleration. The rectangular or trapezoidal rule of numerical integration will be used to determine the root mean square value of a computer generated sinusoidal wave. Integration of the acceleration of a vibrating structure, resulting in the determination of the object's displacement as a function of time, will be accomplished using the trapezoidal rule. Pre-Lab Assignment Pre-Lab assignments are to be done in your lab notebook following normal lab notebook documentation procedures. The Pre-Labs are not to be handed in but will be checked in the lab to assure that they have been completed. Read Section 6.6, 6.7, 6.8 in the Wheeler and Ganji text 2nd edition, and solve problems 6.61 and 6.62 listed below. This pre-lab assignment needs to be in your lab notebook for your reference. 6.61 rd ion) The rmocoup les es (temper ature -sensingg devic es) are usua lly ly a pproximately linea r d evice s i n a (6. 79 in 3 e ditio limi mited ed ra ngee ooff temp era t ure. A man ufa fa ct ure rer of a b rand o f the he rmo mocoupl pl e s has as obtained ed the f ollll owi win g d ataa fo for a pai r of the rmoc ouple wires:

T (°C) V (m (m V))

200 1.02

300 1.53

40 2.0 .05

50 2.5 .55

60 3.0 7

75 3.5 .56

100 4.0 .0 5

Deter m ine e lat ettwee ne the he lin inea r co cor rre ationn coe ffffici cien t bbe een T and V.. rd ion) Forr t hee dat ataa of PPrrobl ble m 6.61 61,, 6.62 (6. 80 in 3 e ditio ) de uaar es-fit lili n e b etwe minee the he le lea ssttsq squ ween T an d V.. de t e rmi ( aa) ( bb)) pl arre es fitt nea r gr gr aph ph pa pape r, andd show ow thee e xpe pe rime me nta tall da t a poin ints an and thee le le a stt-squ q ua i liline. pl o t t hee da taa onn a line

Copy the three files (lab1-A.xls, lab1-B.xls, lab1-C.xls) needed for this "experiment" from the hard drive of the ME Lab computers, webpage or CD. Microsoft Excel will be used for processing data. Note that the Excel Analysis TookPak may need to be “Added In” when first starting Excel. (see notes on webpage for instructions to load ToolPak)

ME 22.302 Numerical Methods Lab

1

Rev 122614

Assignment #1: Least Squares Regression Least squares regression is a statistical means of determining the relationship between independent and dependent variables. In this assignment, data obtained from the calibration of a turbine flow meter will be analyzed. An equation of the form y = mx + b will be determined, compared, and plotted against experimental data. (NOTE: some differences may exist due to different versions of Excel that may be available on UML computers, lab computers or home personal computers) Procedure 1. Retrieve the file lab1-A.xls by clicking on File and then Open in Excel. 2. There should be two columns of data. Range D5 through D15 and E5 through E15 correspond to the flow rate in cubic feet per second and output voltage in volts respectively. Perform a regression analysis on the original data with flow rate as the dependent variable (y) and voltage output as the independent variable (x). In Excel, click on Data Analysis, Regression, OK. In the Regression box, put D4:D15 in the Y range box, put E4:E15 in the X range box. Check the labels box and the Line Fit Plot box. In the Output box have the display of the results of the regression analysis in the output range beginning in cell G15. A linear fit to the data can be expressed mathematically as y = mx + b, where: m = x coefficient(s) x = the independent variable (voltage) b = constant Move the plot in the worksheet so that it will printed along with the results of the regression. Name, and save the graph and the worksheet.

Assignment #2: Root Mean Square Determination of a Sine Wave The root mean square value or effective voltage of an alternating sinusoidal wave is defined as a voltage which has the same heating effect as an equal value of DC voltage. The RMS value of a sinusoidal wave can be determined by numerically integrating the waveform using the following equation: 1 T 2 RMS = y ( t ) dt T ∫0 where T = the period of the signal and y(t) is the amplitude of the waveform which varies with time. In this assignment, a sinusoidal wave will be generated with the computer and numerically integrated using the rectangular or trapezoidal rule. Procedure 1. Clear the Excel worksheet by clicking on File, New, General, OK. 2. Generate a sine wave by performing the following operations: In cells A3 through A103 generate time values from 0 to 2*pi. One method is to enter a zero in cell A2, the formula ME 22.302 Numerical Methods Lab

2

Rev 122614

"=2*@pi()/100" in cell A3, and the formula "=A3 + $A$3" in cell A4. Then copy the contents of cell A4 into cells A5 through A103 by clicking on cell A4, clicking on Edit, Copy, and then dragging the mouse over cells A5 through A103. 3. In cell B3 type =@SIN(A3). This is the first y-axis value in units of volts. Copy this formula from cell B3 to cells B4 through B103. Plot the sinusoidal data. With the rectangular or trapezoidal rule, integrate the square of the sinewave and determine the root mean square value. Save the worksheet on your disk. Assignment #3: Numerical Differentiation Numerical differentiation can be used to determine the velocity and acceleration of an object from experimentally measured displacement data. The true derivative of a function is obtained by determining the slope of the tangent at a point on a curve. Numerically differentiating displacement data with respect to time is an approximation of the slope. Because numerical differentiation is conducted with a discrete number of data points, the derivative of the function is taken between two data points and therefore has an inherent error. As the resolution of the measured displacement data increases over a fixed period of time, the error associated with an approximated derivative decreases. The objective of this assignment is to determine the velocity and acceleration of an object by numerically differentiating measured displacement data. Use your basic undertanding of free falling objects to assist in interpreting the results obtained. Procedure 1. Retrieve the Excel worksheet file named LAB1-B from the data input disk. This file contains experimental measurements of the distance traveled by an object falling freely under gravity. 2. Determine the velocity and acceleration of the object by numerically differentiating the displacement data. 3. Generate three separate plots of displacement, velocity, and acceleration. 4. Consider smoothing the data using regression techniques to allow for improved processing of the data set.

Assignment #4 "Numerical Integration" The determination of the velocity and displacement of an object can be approximated by numerically integrating acceleration data. The integral of a function between two discrete data points is equal to the area under the function defined by those two data points. A mathematical approximation of the integral can be determined by simply calculating the area under the curve. As with numerical differentiation, the accuracy of approximating the integral can be increased by increasing the resolution of the measured data. Unlike numerical differentiation, numerical integration requires initial conditions to obtain meaningful results. The objective of this assignment is to determine the displacement of a point on a vibrating structure by numerically integrating acceleration data. The results will then be compared to simultaneously measured displacement at the same point on the structure.

ME 22.302 Numerical Methods Lab

3

Rev 122614

Procedure 1. Retrieve the worksheet file named LAB1-C.xls from the data input disk. There are three columns of data that represent the time, displacement, and acceleration of a point vibrating on a structure. The displacement was measured with an LVDT (linear variable differential transformer) and the acceleration was measured with an accelerometer. 2. With the given initial conditions (i.e., the first data points), numerically integrate the acceleration data twice and determine the displacement of the point as a function of time. 3. Plot the measured and calculated displacement data of the point on the same graph. Use legends to distinguish the measured data from the calculated data.

Post-Lab Analysis NOTE: Be brief, concise and to the point in all responses. Provide clear, concise answers to questions. Lengthy responses that ramble will not be graded and may lose additional points. 1. How well did the least squares data fit the originally measured data in assignment #1? Support conclusions for this question with two separate approaches. 2. Make a proper engineering plot of the flow meter calibration data including legends for both measured and least squares fit data. 3. What is the RMS value of the sine wave generated in assignment #2 compared to the theoretical expected value? Why do differences exist? 4. Make a proper engineering plot of the sine wave with appropriate titles. 5. Discuss the method used to determine the velocity and acceleration from displacement data in assignment #3. What errors are associated with numerical differentiation and how may they be reduced? What effects did smoothing have on the results? 6. Generate separate, proper engineering plots of displacement, velocity, and acceleration data determined in assignment #3. 7. Discuss the method used to determine the displacement of the vibrating point of a structure in assignment #4. How well did the integrated acceleration data correlate with the measured displacement data? What are the likely causes of differences? 8. Make a proper engineering plot of the LVDT data and displacement data obtained from the integration of acceleration measurement. 9. Is numerical integration less subject to the effects of random noise than numerical differentiation, based on your results in assignments #3 and #4? Justify your answer.

ME 22.302 Numerical Methods Lab

4

Rev 122614...


Similar Free PDFs