The Cavendish Balance equipment is comonly available from places such as PASCO, and are used to meassure the gravitaional constant. The data are taken as a light spot location as a function of time. This can be used to compute G. The experiment is suitable for Sophomore level technical course and lower level courses.
The experiment is done by having one student read the light spot location by using a two-meter stick and a timer. Another student records this information into the Microsoft Excel spreadsheet. So, these data are the first three columns of Excel. In the first row and fifth colmn of this Excel sheet, the distance from the Cavendish Balance to the white board (where the spot is) is entered the in meters.
This function reads a Microsoft Excel file where the data are stored. The first two columns of Excel are time where the first column is a column of minutes and the second column is time in seconds. The third column is the corresponding position of the light spot in centimeters. The distnace (in meters) from the balance to the white board is entered in the first row and fifth column.
The experiment is time consuming, but this function allows the student the complete the experiment by taken about 30 minutes of data. It takes more than an hour for the equipment to come to an equilibrium.
The output of this function is information useful for the instructor to have as the students are reducing their data. The function output includes:
1. Name of Excel file read
2. Distance from balance to board
3. Number of data points
4. Average time between data points
5. Total time data were taken
6. Index number for extrema (peaks and valleys) of the data
7. Time of the extremum points
8. Magnitude of these extremum points
9. Interpolated time for the extremum
10. Interpolated magnitued of extremum
11. System damping coefficient
12. Estimated final location of spot
13. Measured oscillating period
14. The undamped period
15. The gravitational constant, G
16. Percent error
17. Name of file where all of this data are written
The calculation is repeated by fitting the data to a damped sinsusiod by using the MATLAB function "lsqcurvfit."