====== Differences ====== This shows you the differences between two versions of the page.
Next revision | Previous revision | ||
gibson:teaching:spring-2015:math445:lab5 [2015/02/09 10:16] gibson created |
gibson:teaching:spring-2015:math445:lab5 [2015/02/09 10:19] (current) gibson |
||
---|---|---|---|
Line 9: | Line 9: | ||
- Extract the two columns of the loaded data into two appropriately named vectors, e.g. //R// and //N// for problem 1. For the remaining generic instructions I'll use the names ''x'' and ''y''. | - Extract the two columns of the loaded data into two appropriately named vectors, e.g. //R// and //N// for problem 1. For the remaining generic instructions I'll use the names ''x'' and ''y''. | ||
- Experiment with ''plot'', ''semilogy'', ''semilogx'', and ''loglog'' to determine the functional relationship between ''y'' and ''x''. | - Experiment with ''plot'', ''semilogy'', ''semilogx'', and ''loglog'' to determine the functional relationship between ''y'' and ''x''. | ||
- | - Estimate the constants in the log-linear relationship graphically to determine the function. | + | - Estimate the constants in the log-linear relationship graphically to determine the specific functional relation between ''y'' and ''x''. |
- | - Plot the estimated function and the data together, and fine-tune your function by adjusting the constants until there is a good fit between the function and the data. | + | - Plot the estimated function and the data together, and fine-tune your function by adjusting the constants until there is a good fit between the estimated function and the data. |
Once you have good fit between the data and the function, make a plot that shows | Once you have good fit between the data and the function, make a plot that shows | ||
Line 42: | Line 42: | ||
Using Matlab plotting commands, deduce the form of the functional relationship //N(M)//. Estimate the constants in the relationship by estimating the slope and the //y//-intercept, and then fine-tuning by matching the plot of your estimate against the plot of the data. | Using Matlab plotting commands, deduce the form of the functional relationship //N(M)//. Estimate the constants in the relationship by estimating the slope and the //y//-intercept, and then fine-tuning by matching the plot of your estimate against the plot of the data. | ||
- | **Problem 2: The distribution of earthquake magnitudes, by energy.** The moment magnitude scale is logarithmic, in that an earthquake of magnitude //M+1// releases about 32 times energy than an earthquake of magnitude //M//. The following data | + | **Problem 2: The distribution of earthquake magnitudes, by energy.** The moment magnitude scale is logarithmic, in that an earthquake of magnitude //M+1// releases about 32 times more energy than an earthquake of magnitude //M//. The following data |
set gives the number //N// of earthquakes in a given year of energy //E// measured in Joules. | set gives the number //N// of earthquakes in a given year of energy //E// measured in Joules. | ||
<code> | <code> |