Question: You have been given cooling data for many different spheres in an Excel workbook named CoolingData.xlsx . The two worksheets are Information which contains the

You have been given cooling data for many different spheres in an Excel workbook named CoolingData.xlsx. The two worksheets are Information which contains the material name of the sphereand a formatting code, and Data which contains pairs of rows where the first row is the cooling timein minutes [min] and the second row is the difference in temperature between the object and theroom in degrees Celsius [\deg C]. The order of the paired rows of data match the order of the materialnames in the other worksheet.You should write a program that will read in the data from the workbook and give the user twooptions (1) create a summary plot that contains all the experimental data or (2) create a detail plot ofan individual data set with the experimental data, theoretical trendline, and trendline equation. Theexperimental data should be plotted in a user defined function. At the end of the program, the usershould be asked if they want to create a new summary plot, detail plot, or end the program. Detailsfor each of these steps is given below.2.1 Importing Data. Read both worksheets from the Excel workbook into MATLAB storing theInformation worksheet as a table, and the numeric data in the Data worksheet as a matrix.2.2 First Choice. The user should be presented with thefollowing dialog box. If the user does not select one of thetwo options, a warning should appear to tell the user theydid not make a valid selection and the dialog box shouldreappear. This should happen as many times asnecessary until a selection is made by the user.2.3 Summary Plot. Call the function L3_Fn_username (see Section 2.6 for more information) andpass in the entire Data matrix and Information as a cell array when the user selects the summaryplot in the dialog box to plot all experimental data. After the figure has been created by the function alegend should be included to identify all the data sets by their material name and a title should beincluded to identify the figure as a summary plot.2.4 Detail Plot. If the user selects the detail plot, the program should allow the user to select amaterial corresponding to the list of materials in a list. If the user does not make a selection, displayan error message and terminate the program.For the material selected by the user, call the function L3_Fn_username (see Section 2.6 for moreinformation) and pass in only the rows of the matrix and cell array corresponding to the materialselected to plot the experimental data for only the selected material. After the figure has beencreated by the function, then add the trendline, and trendline equation for an exponential model. Thecolor of the trendline and the border color of the equation should match the experimental markercolor (Note: color will always be the first letter in the format pair).The figure should include a title which should be the name of the material selected.Page 2 of 22.5 Choice to Repeat. After the selected plot has beencreated, the user should be presented with the followingdialog box (note that it is different than the original dialogbox). If the user does not select one of the three options,a warning should appear to tell the user they did not makea valid selection and the dialog box should reappear. Thisshould happen as many times as necessary until the usermakes a selection. If they select Summary or Detail the program should repeat and if they selectStop the program should end.2.6 Plotting Experimental Data Create a function which accepts one or more experimental datasets and corresponding format information and plots them on a single figure using a definite loop. Allthe experimental data sets should be passed into to the function as a single matrix, and the formatinformation as a single cell array. Save the script for the function as L3_Fn_username.m whereusername is replaced with the first part of your Clemson email address. The function should plot onlythe experimental data, do not add trendlines or a legend. Each data set passed into the functionshould be formatted using the corresponding format codes passed into the function. The figureshould include all axis labels and gridlines. The x axis should be displayed from 0 to 10 minutes andthe y axis should be displayed from 0100\deg C.

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Programming Questions!