Section.7 Fitting Eponential Models to Data 289 Section.7 Fitting Eponential Models to Data In the previous section, we saw number lines using logarithmic scales. It is also common to see two dimensional graphs with one or both aes using a logarithmic scale. One common use of a logarithmic scale on the vertical ais is to graph quantities that are changing eponentially, since it helps reveal relative differences. This is commonly used in stock charts, since values historically have grown eponentially over time. Both stock charts below show the Dow Jones Industrial Average, from 928 to 2. Both charts have a linear horizontal scale, but the first graph has a linear vertical scale, while the second has a logarithmic vertical scale. The first scale is the one we are more familiar with, and shows what appears to be a strong eponential trend, at least up until the year 2.
29 Chapter Eample There were stock market drops in 929 and 28. Which was larger? In the first graph, the stock market drop around 28 looks very large, and in terms of dollar values, it was indeed a large drop. However the second graph shows relative changes, and the drop in 29 seems less major on this graph, and in fact the drop starting in 929 was, percentage-wise, much more significant. Specifically, in 28, the Dow value dropped from about, to 8,, a drop of 6,. This is obviously a large value drop, and amounts to about a % drop. In 929, the Dow value dropped from a high of around 8 to a low of 2 by July of 92. While value-wise this drop of 8 is much smaller than the 28 drop, it corresponds to a 89% drop, a much larger relative drop than in 28. The logarithmic scale shows these relative changes. The second graph above, in which one ais uses a linear scale and the other ais uses a logarithmic scale, is an eample of a semi-log graph. Semi-log and Log-log Graphs A semi-log graph is a graph with one ais using a linear scale and one ais using a logarithmic scale. A log-log graph is a graph with both aes using logarithmic scales. Eample 2 Plot 5 points on the graph of on the vertical ais. f ) ( ) = (2 on a semi-log graph with a logarithmic scale To do this, we need to find 5 points on the graph, then calculate the logarithm of the output value. Arbitrarily choosing 5 input values, f() log(f()) - (2) = 8 -.26 - (2) = 2.76 (2) =.77 2 (2) 2 = 2.79 5 (2) 5 = 96.982
Section.7 Fitting Eponential Models to Data 29 Plotting these values on a semi-log graph, log(f()) 2 - - -2-2 5 6 - Notice that on this semi-log scale, values from the eponential function appear linear. We can show this behavior is epected by utilizing logarithmic properties. For the function f ( ) = ab, finding log(f()) gives ( f ( ) ) log( ab ) ( f ( ) ) log( a) log( b ) log = Utilizing the sum property of logs, log = + Now utilizing the eponent property, log f ( ) = log a + log b ( ) ( ) ( ) This relationship is linear, with log(a) as the vertical intercept, and log(b) as the slope. This relationship can also be utilized in reverse. Eample An eponential graph is plotted on a semi-log graph below. Find a formula for the eponential function g() that generated this graph. log(g()) 5 2 - - -2 - - 2-2 - The graph is linear, with vertical intercept at (, ). Looking at the change between the points (, ) and (, ), we can determine the slope of the line is. Since the output is =. log(g()), this leads to the equation log ( g( ) ) +
292 Chapter We can solve this formula for g() by rewriting in eponential form and simplifying: log ( g( ) ) = + Rewriting as an eponential, + g( ) = Breaking this apart using eponent rules, g( ) = Using eponent rules to group the second factor, g ( ) = Evaluating the powers of, ( 5. ) g( ) = 62 Try it Now. An eponential graph is plotted on a semi-log graph below. Find a formula for the eponential function g() that generated this graph. log(g()) 5 2 - - -2 - - 2 Fitting Eponential Functions to Data Some technology options provide dedicated functions for finding eponential functions that fit data, but many only provide functions for fitting linear functions to data. The semi-log scale provides us with a method to fit an eponential function to data by building upon the techniques we have for fitting linear functions to data. To fit an eponential function to a set of data using linearization. Find the log of the data output values 2. Find the linear equation that fits the (input, log(output)) pairs. This equation will be of the form log(f()) = b + m. Solve this equation for the eponential function f()
Section.7 Fitting Eponential Models to Data 29 Eample The table below shows the cost in dollars per megabyte of storage space on computer hard drives from 98 to 2 6, and the data is shown on a standard graph to the right, with the input changed to years after 98 Year Cost per MB 98 92. 98 87.86 988 5.98 992 996.7 2.689 2.9 This data appears to be decreasing eponentially. To find a function that models this decay, we would start by finding the log of the costs. Year Cost per MB log(cost) 98 92. 2.282 98 87.86.979 988 5.98.2577 992.626 996.7 -.7695 2.689-2.67 2.9-2.9952 As epected, the graph of the log of costs appears fairly linear, suggesting an eponential function will fit the original data will fit reasonably well. Using technology, we can find a linear equation to fit the log(cost) values. Using t as years after 98, linear regression gives the equation: log( C( t)) = 2.79. 2t Solving for C(t), 2.79 C( t) = C( t) = C( t) = 2.79 2.79.2t.2t.2 ( ) t (. ) t C( t) = 622 5877 8 2 6 2 2 This equation suggests that the cost per megabyte for storage on computer hard drives is decreasing by about % each year. 25 2 5-2 - - 5 2-8 2 6 2 2 6 Selected values from http://www.swivel.com/workbooks/269-cost-per-megabyte-of-hard-drive- Space, retrieved Aug 26, 2
29 Chapter Using this function, we could predict the cost of storage in the future. Predicting the cost in the year 22 (t = ): C() = 622 (.5877). 6 dollars per megabyte, a really small number. That is equivalent to $.6 per terabyte of hard drive storage. Comparing the values predicted by this model to the actual data, we see the model matches the original data in order of magnitude, but the specific values appear quite different. This is, unfortunately, the best eponential model that can fit the data. It is possible that a non-eponential model would fit the data better, or there could just be wide enough variability in the data that no relatively simple model would fit the data any better. Year Actual Cost per MB Cost predicted by model 98 92. 622. 98 87.86 7. 988 5.98 8.9 992. 996.7. 2.689.5 2.9.8 Try it Now 2. The table below shows the value V, in billions of dollars, of US imports from China t years after 2. year 2 2 22 2 2 25 t 2 5 V 2. 25.2 52. 96.7 2.5 This data appears to be growing eponentially. Linearize this data and build a model to predict how many billions of dollars of imports were epected in 2. Important Topics of this Section Semi-log graph Log-log graph Linearizing eponential functions Fitting an eponential equation to data Try it Now Answers. f ( ) = (.62) t 2. V ( t) = 9.55(.278). Predicting in 2, V ( ) = 722. 5billion dollars
Section.7 Fitting Eponential Models to Data 295 Section.7 Eercises Graph each function on a semi-log scale, then find a formula for the linearized function in the log f = m + b. ( ) form ( ). f ( ) = (.) 2. f ( ) = 2(.5). f ( ) = (.2). f ( ) = ( ).7 The graph below is on a semi-log scale, as indicated. Find a formula for the eponential function y. ( ) 5. 6. 7. 8. Use regression to find an eponential function that best fits the data given. 9. 2 5 6 y 25 95 2 29 65 66. 2 5 6 y 6 829 92 7 6. 2 5 6 y 555 8 7 2 58 22
296 Chapter 2. 2 5 6 y 699 7 695 668 68 72. Total ependitures (in billions of dollars) in the US for nursing home care are shown below. Use regression to find an eponential function that models the data. What does the model predict ependitures will be in 25? Year 99 995 2 2 25 28 Ependiture 5 7 95 2 8. Light intensity as it passes through water decreases eponentially with depth. The data below shows the light intensity (in lumens) at various depths. Use regression to find an function that models the data. What does the model predict the intensity will be at 25 feet? Depth (ft) 6 9 2 5 8 Lumen.5 8.6 6.7 5.2.8 2.9 5. The average price of electricity (in cents per kilowatt hour) from 99 through 28 is given below. Determine if a linear or eponential model better fits the data, and use the better model to predict the price of electricity in 2. Year 99 992 99 996 998 2 22 2 26 28 Cost 7.8 8.2 8.8 8.6 8.26 8.2 8. 8.95..26 6. The average cost of a loaf of white bread from 986 through 28 is given below. Determine if a linear or eponential model better fits the data, and use the better model to predict the price of a loaf of bread in 26. Year 986 988 99 995 997 2 22 2 26 28 Cost.57.66.7.8.88.99..97..2