Thứ Bảy, 4 tháng 6, 2016

Fundamentals of Quantitative Modeling-Chapter 2

2.1 Introduction to Linear Models and Optimization


I'd always get started by calculating some illustrative values. So if q is equal to 0, then you'd put 0 in the equation, and you're going to get a 100 plus 30 times 0 which is just 100. Working down through the table, if you were to put q equal to 10 in, you going to get 100 plus 300, give you 400. Q equal 20 will give you 700, so there's some illustrative values associated with this cost model. A picture is certainly worth a thousand words. So, here's a picture of this linear function, the cost model. And you can see, it's a straight line model. We have quantity on the horizontal axis and total cost, the variable that we are trying to understand on the vertical axis. And that's pretty much how it's always going to happen. The inputs on the x-axis, the outputs from the model on the y-axis. I've written the equation here where C equals 100 plus 30q onto the graph. And you should confirm as you look at this graph that the intercept, so that means follow quantity, all the way down to zero and eyeball what the value is, it's about 100 there. And you could also by choosing a couple values, say, q equals 10 and 20, look to see how much the graph is gone up by. And it should go up by x is going by 10 units, then y goes up by 30 units if it's a linear function here. And so you could confirm the coefficients simply by, the reasonableness of the coefficients simply by looking at the graph. Now, the two coefficients in the equation, the intercept and the slope, which we write as b and m in general, 100 and 30 in this particular instance, have interpretations. And one of the activities that one typically goes through with, in terms of a quantitative model, is to try and interpret features of that model. What are they capturing? What aspect of the business process are they encoding? So, interpretation is, in fact, a critical skill when it comes to modeling. And it's important, because at some point, remember the end point of the modeling is implementation. Some people say that implementation is the sincerest form of flattery. So you would like your models to be implemented. But for them to be implemented, you need to convince other people that they are useful and helpful. Now that process of convincing other people tends not to happen by you showing them the formula behind the model, because most people don't understand formula, they don't do math. What it involves is if you're discussing in language that they can understand what the model is capturing, and that language is all about interpretation. So I believe that interpretation is absolutely critical when it comes to modelling. If you want to convince other people that your model is reasonable, and ultimately, to get it implemented. So let's do some interpretation for this example. So let's look at the intercept, which is b. Now formally, you can say that the intercept b is a value of y when x is equal to zero, the cost of producing zero units. But it doesn't really make a lot of sense that there's some cost in producing zero units. A better understanding of that coefficient is to think of it as the part of total cost that doesn't depend on the quantity produced, and that's the definition of fixed cost. So every time you produce some of this particular product, there's a cost that is independent of the number of units that you are producing. And we call that one of the fixed costs. So the intercept has the interpretation of fixed cost. And m, the slope of the line, well, that's as quantity goes up by one unit, we anticipate the total cost to go up by m units. That is known as the variable cost. So the equation in this particular instance has a nice interpretations of the intercept and the slope as fixed and variable costs. 
All right, so that's our first linear function. Let's have a look at a second linear function. Again, talk about interpretation of coefficients. So here, I'm thinking about a production process, and I'm interested in modeling the time to produce as a function of the number or the quantity of units that I'm producing. So obviously, such a function would be very helpful if you had a customer who gave you an order, one of the first things a customer is going to say to you is when is it going to be ready? Well, how long does it take to produce? That's the idea here. And so, it certainly answers some practical questions, the time to produce function. So in the example that I'm looking at, we're given some information. The information as it takes two hours to set up a production run. And each incremental unit produced, every extra unit, always takes an additional 15 minutes. 15 minutes is a quarter, 0.25, of an hour. Now, in terms of modeling this, there's a key word here, and that's the word always. And what that is telling you is that the time to produce goes up by 15 minutes, regardless of the number of units being produced. So that's the constant slope statement coming in that is associated with the linear function or straight line function. So it's that always there that it's telling me that we're looking at a straight line function. So if we were to write down these words in terms of a quantitative model, then we need to start defining variables. So let's call T, the time to produce q units. Then, what we're told is that the time to produce q units always starts off with two hours. There's a two-hour setup time. And then, once we've set the machine up, it's quarter of an hour, 0.25 of an hour to produce each additional unit. And so in this example, the interpretation of b is the setup time, and m, I might call the work rate, which is 15 minutes per additional item. I certainly like to use the word rate here when we're talking about a slope, because a slope is a rate of change. And so in this example, we were given the words associated with the process, and it's really up to us to turn it into a mathematical or modelling formulation. So the first bullet point is the description of the process. The second bullet point is the articulation of the process in terms of a quantitative model. So there's a second example. So once again, we've got interpretations in the first example where we had the linear cost function. Our intercept and slope were fixed and variable cost. This time around in the time-to-produce function, they are setup time and, as I've termed it here, the work rate. So, with this function at hand, I'm going to be able to predict how long it takes to produce a job of any particular size. And so, let's just check out the graph here quickly. We should confirm by looking at the axis, and once again, we've got the input to the model, that's the quantity on the x-axis, and the output, the time to produce, on the y-axis. We've called them T and q here. We look at the line and look to see where it intercepts the point X equal to zero. By just looking at the scale, we can say, yes, that's about two. And we could confirm for ourselves, for example, by looking to see how much the graph goes up between 20 and 30, that's a 10 unit change in X. For 10 unit change in x, we're getting 2.5 extra hours to produce. So I'm just eyeballing this graph to confirm that it is consistent with the equation that I've written down. And it's always a good idea to do that, because mistakes happen. And it's good to have in place some kind of checks as we go along the way. So there's our equation and the graphical representation of it, so a model for a time-to-produce. I want to briefly talk about a topic that uses linear functions as an essential input. Now, in this particular course, I'm not going to show you the implementation, but I just want you to know that this technique is out there. It solves a set of problems, and it is totally focused on linear functions. And that technique is known as linear programming. It's one of the work horses of operations research, it often goes by the acronym LP. And it is used to solve a certain set of optimization problems. And those are optimization problems where all the features of the underlying process can be captured in linear, with a linear construct, basically lots of lines. One of the interesting things about these linear programs is that they explicitly incorporate what we term as constraints. So when we try to optimize processes that really means doing the best that we can, it's often important to recognize that we work within constraints. So there's no point coming up with an optimal solution that we can't achieve, because we don't have enough workers, or we don't have enough of a certain product on hand to achieve that optimization. And so, constraints are ideas that we can incorporate in our modeling process to try and make sure that our models really do correspond to the world that we're trying to describe. And as I say linear programming really does think carefully about incorporating those constraints. They just happen to be linear constraints in linear programming. So, if you come across problems that are to do with optimization, and most of all of the underlying features of the process can be captured through a linear representation, then linear programming might be the thing for you. And you can often find linear programming implemented in spreadsheets sometimes with add-ins. And so, Excel has a solver which can be used for doing linear programming. So this is one of the big uses of linear models for optimization. Again, it's not a part of this particular course, but I want you to know that it's out there, and it's one of the, as I say, big uses of linear models. 

2.2 Growth in Discrete Time




And it might be how an investment is growing over time, you know you have money, you choose to invest it, how is that investment growing? You're planning for retirement for example, so hopefully your retirement savings is growing. We want to have models for growth, now it's possible that a linear model could be helpful for growth. There's no reason why something couldn't grow in a linear fashion, but there are some alternatives to linear models for growth processes. Now I would call a linear model an additive one because we're adding on the same amount of the output for each one unit increment in the input or the x value, so they're additive. Now an alternative for things growing in an additive fashion, when we add on an absolute amount in each time period, is a proportionate one. And a proportionate increase, I really mean a percent increase, so from each period we don't go up by an absolute amount; we go up by a proportionate amount. So I might say every year our savings grows by 5%, not by $5 thousand or 5 thousand rupees, but rather by 5%. In terms of a salary, you might want to describe your salary changes not in an absolute sense, you know my salary went up by a thousand dollars, but in a percent way, for example, my salary went up by 3% this year. And so we often think of changes in terms of percentages, and if we change by a constant percent increase from one time period to another then for now I'll call that proportionate growth, and that's to be contrasted to additive growth. So to compare the two sorts of growth processes, a linear versus a proportional one, I'm going to talk about interest for a little while. Now interest is ideally what happens when you invest some money, but interest comes in two flavors. It is sometimes called simple and other times compound interest. And so let's see what happens to money when it grows according to a simple interest model. So let's say you start off with $100, that's often termed the principal, principal investment, and at the end of every single year you're going to earn 10% simple interest on the initial $100. Now 10% of 100 is 10 so that means after year one you've got an extra $10, and so if you have a look in the table, you start off year zero is now the principal of 100, after the first year you got $110. Now because it's simple interest, in the second year you're only going to earn interest on the principal, which 10% of 100 is still 10, so you go up by another $10 in year two, and likewise in year three, another $10, so 130, 140. And I went out to 10 years, by which time your 100 will have grown to 200. So every year the investment grows by exactly the same amount, that is $10, so that's additive, it's the same amount in each period. I'm going to contrast that now to what we term compound interest. So with compound interest, we're going to start off with the same amount of money, in this example $100, we'll still call it the principal, but we're going to now earn compound interest. And what compound interest means is that the interest itself earns interest in subsequent years. Simple interest was when the interest was only on the principal, compound interest is when you're earning interest on the interest. Now this gives rise to a very different growth process because now every year we're going to go up by 10%, not of just the initial amount, but of the current amount. So in year one were in the same place, we go up 10% of 100, and that's $10, so we've got $110 in year one. Here's the key idea though, that in year two we're going to earn 10% on the $110, not on the 100, so 10% of 110 is 11, and if we add 11 to 110, we get 121. So notice now in year two, we got $121 rather than $120. In year three, because we're earning 10% interest on $121 it turns out that we have got an investment valued $133.10, which is more than $130. And if we go all the way out to year ten we end up with $259.37, as compared to the $200, had we been earning only simple interest. So you can see that when the interest itself is earning interest, we're looking at a different sort of process. Now as we go from one period to the next, we're not going up by the same absolute amount, $10, rather we're going up by the same relative or proportionate amount, we're going up by 10% each time. So you're getting one cell in the table by multiplying the previous cell just by 1.1, so you could implement such growth process very easily within a spreadsheet, the sort of thing that spreadsheets are ideal for. But that's compound interest versus simple interest. Now I've drawn the growth of these two investments on a graph so you can contrast them. The brown step function at the bottom is what happens to your $100 when it's earning simple interest, and so we really thought of these as steps, as in physical steps. What's going on is that each step is of the same width and exactly the same height, that's sort of how we make stairs typically. When we compound the interest, you can see how the growth function is, we're growing in a different fashion with the compound interest, the blue step function. If you were to try to walk up those steps you would find that the width of each step is the same, but the height is increasing because it's going up by 10% from the previous height every time. So that would be a pretty tricky sequence or set of steps to walk up eventually, because the steps are going to get higher and higher and higher each time. Because we are going proportionality rather than in an additive or linear fashion, so you can see the differences, and in fact, the blue curve is an exponential function, and the brown is linear. 


2.3 Constant Proportionate Growth


We were told that the catch was going to fall by 5%, constant 5%, each year. That means that our multiplier is 0.95. because to fall by 5% means to multiply .5 by 0.95. If you take 100, and you make it 5% smaller, you're essentially going to multiply that 100 by 0.95 to get 95 which is what it means to make it 5% smaller. Now in general, if our process is changing by R%, I've got a capital R% in each time period, then the appropriate multiplier is theta equals one plus R over 100. And that over 100 is going with that percentage, which means out of 100. So that's how you get the multiplier. So, I put in a five for the R, and if my process was increasing, it would be a positive five that I put in there, and my theta would be 1.05. And if it were decreasing by 5% each year, then I'd put in capital R as minus 5. And I will get theta equal to 0.95. So increasing positive R. Decreasing negative R. And so we go from the percent change to the constant multiplier. So what we're being told in the setup to this particular instance, is that we've got a multiplier of .95. That was was meant by each year, a catch is going to fall by 5%. Now we've got the problem set up, we could implement within a spreadsheet and simply work out what the fish catch is going to be. So think of the table here as a snap hot from a spread sheet. So we start off with P0. Before I'd use that to refer to how much money we started off with, but now it's how many fish we're catching right now which is 200,000. And we've got theta equal to 0.95. And so using the formula that is associated with this model. In five years the catch is going to be 200,000 times 0.95 to the power 5. Now you can do that calculation with a calculator. You could certainly do it in a spreadsheet. And if you'll do that, you'll find that your projected catch in five years time is 154,756. And so that's using the model. 
Now a little bit about rounding. When you do the calculations, if you're doing them in a spreadsheet or a calculator, you will start to get places of decimals occurring. And so in year four, the actual number is 162,901.25. So it's the .25. Of course, you can't really catch a core of a fish. So, practically, if we were presenting these numbers to somebody, we would certainly, round them to a whole number. And we might eve round to thousands. And why would we be very happy rounding? Well, first of all, as I say you can't have place decimals. And remember, all models are wrong, but some are useful. And so we're really not losing anything by some rounding of those numbers. But, formally, according to this model, I'm expecting to catch a little over 8 million tons over the next five years. So that's our geometric series model for growth in discreet time. Now here's a graph of the fish catch. Remember a picture is worth a thousand words. It's never a bad idea to present what is going on graphically and if you have a look at the height of each of these lines, the first one is at 200,000. The second line goes up to 190,000, which is 5% less than the first one. And then we keep going down by 5% from one period to the next time period. So, there's a graphical representation of our fish catch for each of those five years in addition to the current catch. And all that I was doing when I was saying what was the total fish catch is basically add up the heights of these six lines that I've got here. 
Now, one thing you should be aware of is that the step size on these lines is not the same. So we think of it as going downstairs now. It's not a linear model, it's not additive. In fact, as we go down from step to step the absolute difference is getting a little smaller each time from step to step. So this would be a sort of easy staircase to go down. The steps are getting smaller and smaller as we go down from one to the next. The same distance between the steps because our unit of analysis is time zero, one, two, three, but if you have a look at the difference in height, it's getting smaller each time because it's a proportionate growth as opposed to a linear or additive growth type model. In the additive then the distance from the top of one step to the bottom, would always have been the same. It turns out, that this particular quantitative model we have, the geometric series has some rather nice properties about it and I want to introduce here what we called the sum of the geometric series. So, the fish catch was projected to be a geometric series. And one of the questions was, how many fish have we caught over the first five years including the current year? So, that's a sum. Now, it turns out that there's a neat little formula that captures the sum of a geometric series. So, I'm just going to present it to you and make a couple comments about it. So, we need some notation, as ever, and we often write time in modeling. Parlance with the letter T, make sense? And we're going to write the sum up to time T, and including as S of T. So S of T denotes our sum. 
It turns out that if we've got a geometric series, then S of T is equal to T0, which is the initial amount or principle financial language times and then that's 1 minus theta to the power T plus 1 over 1 minus theta. And so now you can see why you need to know about these power functions if you're going to become useful in this quantitative modeling. You certainly need a certain set of mathematical skills, and I did present the functions that I think you you absolutely need to feel comfortable with. So, here's the panel function coming in. Now with a formula like this, I don't have to go through the process of working out each individual year's catch. I can just plug straight in to the formula. And if I do that for this particular geometric series where P0 is equal to 200,000 and theta was equal to .95, T I'm summing up to, in the fisheries example year five, so T is equal to 5, I have to put in 5 plus 1 and I get exactly the same number out as I got before, 1,059,632. So it's encouraging that it's the same. It has to be the same. But what you can see here is that one of the advantages of a quantitative model is it can potentially provide a much more efficient way of doing calculations than if you looked at things on a time by time period in the spreadsheet type world view. Where yes, you can do this in a spreadsheet and add it up. But imagine we have a situation where we wanted to go out a time period that was more rows than you could put in a spreadsheet. Your spreadsheet approach just wouldn't work anymore, but you've always got the formula to use. And so there are situations where taking the time to formalize the business process through a quantitative model will give you much more efficient ways of computation than through a spreadsheet. So I'm not knocking spreadsheets. I'm not saying there's no use for them. But I'm saying that there are certain sorts of problems that can be very efficiently solved through the formulae that we're able to generate through having taken the time to create a quantitative model. And here's an example of such a formula. So the sum of a geometric series. 



2.4 Present and Future Value




One of the places that these models for growth come in really useful, is in the ideas of present and future values. So the present or future value of key ideas in business, and I'm going to illustrate them through an example here. So, lets imagine that there's no inflation in the economy and there's a prevailing interest rate of 4%. By which I mean, that if you have some money, you can invest it, and be sure of receiving a 4% return on it, annually. Here are two investment options. Number one, $1000 today, or number two, $1500 in ten years. Now, given that that $1000 is going to grow by 4%. Each year, and I'm thinking here of compound, so we're going to grow according to a multiplicative or proportional growth type model, which would you prefer? Thousands a day, or $1500 in 10 years? And the key feature of this question, is that you are comparing values at two different time points. 1000 today or 1500 in ten years. And it's believed that there's a time value of money. And, so in order to decide between which of these two investments, I would prefer I can do one of two things. I could take the 1,000 and see how it grows by 10 years. If it's compounded at 4%. Or, alternatively, I could take the 1500 and back track it to today, and, basically, ask the question. How much would I have to have invested today to get 1,500 dollars in ten years time? So that idea of taking a value in the future, 1500, and bringing it back today is the idea of calculating a present value of a future quantity. So, could do these comparison, one of the approaches is to find the present value of the $1,500 and so that's what I'm going to do. 
Let's have a look now, at the present value calculation. So our formula for growth, our model for growth is that at time Pt in the future. We're going to have the principle P0, times theta to the power t. Now, that tells us how the future depends on the present value. What we would like to do now, is make P0 the subject of the formula. If we do that, we can restate this equation as P0 equals Pt, times theta to the power minus t. That's what happens if you go through and make P0 the subject of the formula. And now this formula tells you how you can take a value in the future, Pt. And discount it back to today's value. How much is that worth now? By multiplying through by theta to the power minus t. Remember, theta is the constant proportional growth factor. So, using this formula, we can see that $1500 in ten years time in a 4% interest rate environment is going to be worth, in today's money 1500 times 1 plus 0.04, that's 1.04, that's the multiplier, if you've got 4% interest. So that's our theta, and now to the power of -10, because we're discounting it back, 10 time periods. So that's how much it's worth in today's money. If we work that out, again you can do that on your calculator or using a spreadsheet, you're going to see that this equals $1,013, just a little bit over. Now, $1,013 is worth more than $1,000 which was your alternative, to get $1,000 today. So a typical person, or a rational person would prefer the second investment of $1500 received in ten years time, because it's present value is greater than the $1000, the other option on offer. And so, the great thing out of this simple, this straightforward quantitative model for growth, the proportionate model for growth. And it gives us a really simple discounting formula, and discounting is one of the activities that businesses go through, as they think about quantitative modeling. because we'll often think about a value in the future and make comparisons between objects at different points in time. And we need to create a time baseline to do those comparisons, and that's what the discounting is going to allow you to do. To take a future value and bring it back to a current value, so we can create a common baseline, typically to compare investments and do valuations. So let me tell you of a couple places, where you can see this idea of present value being used. 
Now, the nice thing about thinking of the continuous time version of the quantitative model is that there's a very straightforward, somewhat elegant formula that tells you exactly how much your money is going to, over a time period, t. So if your money is growing at a nominal annual interest rate of R%, I'm using the letter capital R there, then it turns out that the amount of money you've got at time t, Pt, is just equal to P0, your principle, times e, that's the exponential function coming in there. To the power RT. Now, note that's a little r there, because I've taken the interest rate, capital R, and turned it into an out of a hundred. I've divided through by a hundred. And so, for example, if your interest rate, the nominal interest rate is 4%, that little r would be .04, so there's a very nice formula for continuous compounding. So that's an alternative way of modeling a growth or decline process rather than doing it in discrete time, we could do it in continuous time and we end up with a very neat formula that, interestingly, involves the exponential function. That was one of the reasons why I said, in the introductory module, it was one of the functions you needed to know. It comes up naturally here. I'm going to do a quick example with continuous compounding, show you, how you would do a calculation. The important thing to note though with continuous compounding is that the value T, now can aptly take on any value. Remember when we were talking about discreet? It could only take on specific values. The end of each year or the end of each month. Now that we're in continuous time, T can take on any value, inside an interval. So let's have a look what happened, if we were to continuously compound $1,000 at a nominal annual interest rate of 4% after one year. Make the calculation easy. T you put a one in. 
Then, what you're going to end up with is a thousand times, e to the power of 0.04. Again, you do a calculation like e to the power of 0.04 on your calculator or using a spreadsheet, it turns out that if you do that calculation, you'll end up with a $1040 and 80 cents after one year. And notice that, that's a little bit different from the $1,040, if you just compound it at a single point in time at the end of the year. 4% of 1,000 gives you 40. But if we continuously compound, then we end up with $1,040.80. So it's a little bit different, the end result of continuously compounding rather than discretely compounded. And I talk about a nominal annual interest rate of 4%, because of course at the end of the year, if it was continuously compounded, you earned a little bit more than 4%. So 4% is just called nominal. You earn 4.08% to be more precise. So. That's the effected interest rate. So there's a little bit about continuous compounding. Now, I'm going to apply this exponential growth model, now back to the epidemic we were talking about. Sure, I introduced the continuous compounding in an investment context, but these exponential models that they give rise to are much more general, than just talking about money. And at least in the early stages of an epidemic, it's not unreasonable to think of an exponential model as a starting model. So Let's consider modeling the epidemic with an exponential function. So when we have these exponential models, here I'm writing Pt=P0, that's a starting amount or starting number of infections, starting number of cases times e to the power rt. We call that exponential growth or decay. And if the letter r, the number in practice is greater than zero. Then, it's a growth process. And if it's less than zero, if r is negative, then it's a decay process. So these models can capture growth or decay. Increasing or decreasing. Functions. 
Let's do the calculation now. So we'll calculate the expected number of cases at week 7.5. Remember half way through week 7 is equal to 7.5. I simply take my quantitative model 15 times e. To the power 0.15 now times t, but t is 7.5. Comes to be 46.2. Reasonable rounding takes that to 46. So, at the beginning of the epidemic, I'm expecting 15. I have 15 cases, by 7 and a half weeks. Halfway through week 7, I'm able to expect about 46 cases. And of course, one could calculate this for any value of T that you wanted to, and practically speaking this sort of forecast would enable someone to do some resource planning, if you were in charge of trying to cope with that epidemic, how many physicians do I need, how many medical centers do I need to put in place? You need a projection. You need a model to be able to do that. So there's a continuous time growth model. Going back to the the interpretation of the 0.15, here it is. There's a approximant 15% weekly growth rate. And I say weekly, because time T was measured in weeks. And a reminder of the difference between continuous time and discrete time modules, the graph on the left are reproduced from the fishing example. Where we were talking about how many fish would be caught on any particular year. And on the right-hand side we've got our continuous time model. Notice, how that's that smooth function. It fills in all the gaps for the discrete model. You've got specific instances that you're evaluating the function. So that's the difference between discrete and continues, again just remember the two source of waters you can choose to have a digital watch, that's when you want to have a discrete version of time. Or you could choose to have of an analog watch with hands on it, and then you're going to be looking at a continuous version of time. Its your choice, it's not typically that one is right or one is wrong, but they are both used in practice. 


2.5 Optimization



And revenue can be written as the price that you sell the object at times the quantity that you sell. So if you're selling candy bars, they cost $2 for someone to purchase, I mean the price is $2 and you sell ten of them, then your revenue is $20, right? Two times 10, so that's what's going on there. We write that more generally as p x q, price times quantity. Now, the profit is the revenue- cost. So, the profit equals pq which is the revenue. Now what is the cost of producing q units? Each unit costs c dollars to produce, and I'm going to produce q of them. So the total cost according to this model is c times q. So I can simplify that equation into q(p-c). So that's the profit that we're going to make. But we've got a model for q in terms of price and that model says quantity = 60,000 Price to the power -2.5. So putting it together, we can see that our profit is equal to 60,000 p to the negative 2.5, that's the quantity, times (p- c) and in this particular example, I'm taking the cost of production at $2.00 per unit so that's p- 2. So now you're looking at an equation that has come out of the quantitative model for quantity. And I am now going to ask at what value of p is the profit maximized? So choose profit p to maximize this equation. So this is what we mean by an optimization. As I said before, optimization is one of the things that we tend to do with our quantitative models. So how we going to do it? Well there is a brute force approach to this. We've got a function for profit. 
Let's just choose different values of price, which I'm writing as a little p, and plug them into the function and see what the profit looks like. And so in the table on this slide you can see I've plugged in different values for price. It's in the price column and I've used the equation, the model to figure out what the profit is. So if I charge $1.75 for this product I actually don't make any profit off of it at all. There's a negative profit, otherwise known as a loss, and of course, that makes perfect sense, because 1.75 is less than the cost of production, which is $2. If I were to price it $2, then I don't make any profit whatsoever because my price is exactly equal to my cost. So you get 0 for the second one and then the subsequent numbers in there are just coming out of the profit equation. Now if I look down through that table, that optimization just corresponds to finding the biggest number in there. And I've drawn a graph that shows you the profit as a function of price. And you're already trying to figure out at which value of PDX axis is the profit the highest. Where's the top of that graph in other words? So, this is a brute force approach because I haven't actually tried every value of p. If I'm implementing this in a spreadsheet, spreadsheets have cells and each cell you can only put in one number. And so it's a discrete approach to solving this problem, and it looks to me that the best value of price is somewhere sitting between 3 and 4, but I don't know exactly where between 3 and 4 it is right? So, this gives me a sense of where the answer is. And it might be fit for you, say it might be enough for you to say, I just want to set the price between 3 and 4, but optimization does give us the potential to be a bit more precise about it, so that's what I'm going to do now. So, the calculus approached to these problems involves the mathematical technique of differentiation and what we need to be able to do is to find the derivative, which means the rate of change of a function, with of the profit with respect to price, and we need to see where that derivative equals to zero. So optimization, the actual mathematics of optimization, is not the goal of this course. The goal of this course is to talk about modeling, and this is one of the places that models are used. And so I'm not actually going to do that, I'm going to present you with the results. If you're interested in calculus one you can, and its use in business you can certainly find other courses that will address that. So I'm just going to skip to the answer here, it turns out that by applying calculus to this problem you can obtain the optimal price. And the optimal price which I'll write as Popt, opt for optimal, is qual to c b / 1 + b, where c is the production cost and b is the exponent in the power function. So with this neat little mathematical model that we had for quantity demanded as a function of price I'm able to leverage that equation, leverage that model, and come up with an answer to the question. What's the best price to set in order to maximize my profits? Now, going back to this example, c was equal to 2, that was the cost of production, and b was equal to negative 2.5. If I plug in those numbers to the equation, you can convince yourself that the optimal value for p, for the profit, is about equal to 3.33, it's already three and a third is the best value for price. So that is solution to the problem. And by creating, or using a simple model for the quantity for the demand I'm able to end up with a simple model, you can even call it a rule of thumb if you want, a simple formula for pricing. 
Now, in terms of interpretation again, well, we know what c is, that was the cost, that coefficient the minus 2.5 in the power function model that we're looking at, remember this model for demand is a power function model. It was 60,000 times price to the power negative 2.5. That's a special quantity, the exponent b in this situation and it gets called the price elasticity of demand. And so, oftentimes economists will put a negative in front of that because the coefficient is negative 2.5. And one might say the price elasticity of demand is 2.5 for this particular product. What that negative 2.5 means in terms of the business process is that as you increase price by 1%, you can anticipate a fall in quantity demanded of 2.5%. So the coefficient relates percent change in x to percent change in y, and the negative 2.5 means that as x is going up, y is going down, so a one percent increase in price is associated with a 2.5% fall in quantity demanded and that proportionate relationship, proportional change in x to proportional change in y is true for any value of x. That's what's very special about the power functions that that proportionate change between x and y is a constant and in this case, it's negative 2.5. And, as I say, people might call the price elasticity of demand here, 2.5. So that's the calculus approach. And I'll finish this off with a slide that shows you what the calculus approach is doing. The blue curve is the demand equation. That is the curve 60,000 times price to the negative 2.5. So that shows how price and quantity demanded are related. Now for any value of the price, so fix the price, stop the box moving, means fix the price. 
For any value of the price you can go up to the curve and record what that point is. That will define a box. And that box that's the light grey shaded area in the graph here actually is the profit that's associated with that price. And you know it's the profit because the width of the box is p minus z, that was price minus cost and the height of the box is q, the quantity demanded. Remember, that was how we were able to write our profit here as q times p minus c. So q is the height of the box, p minus c is the width of the box, the product of those two numbers is the profit, and the product of those two numbers is the area of the box. So what the calculus approach does is take your quantitative model, which is the blue curve here, that's what we contribute with the modeling, and then we do the optimization which is simply to find the value of p at which the area of the grey shaded box is largest. If I can find that value of p, I've solved the optimization problem. And so again, one of the nice things about these quantitative models is they can help you visualize the solution to a problem. And without this visual here it's hard to kind of see in the same way as to what we're really trying to achieve, and as I say, what we're trying to achieve when we maximize the profit is essentially to find the value of price of which this grey shaded box is maximized. And we know from having gone through the calculus approach that it's at p equal to three and a third, 3.33. 
deterministic models. Remember, deterministic was the antithesis of probabilistic or stochastic. Deterministic models has no uncertainty anywhere. 


We talked about today linear models, a building block for all modeling, the simplest function that we can use to relate an input to an output and we saw some uses of linear models. We saw a total cost function and we saw a time to produce function. I also briefly talked about linear programming, an optimization technique that is suitable when you have linear models. We talked about growth and decay. Remember, growth is such a fundamental construct business or staying in business. And we talked about grow and decay. First, the in discrete time that was the idea of a geometric series. And we talked about growth and decay in continuous time. We saw when we looked at the geometric series that by creating this quantitative model, we were able to leverage that model in a number of ways and one of the neat things we could do with that model was to work out the sum of a geometric series. We had a nice little formula for that. So that's one of the things that modeling will do for you, it will give you potentially some handy formula that can be used to do speed up calculations. So we did growth and decay in discrete and continuous time. We talked about present and future value. Once you've got a model for growth, you're going to be able to essentially reverse engineer that growth process to say, how much do I need now to obtain a certain amount in the future? And so, given that future amount, what is it worth right now? And so, the reverse engineering of the growth model is essentially what it means to do. A present value calculation. Taking a value in the future and discounting it to the present value. Our models made that straightforward. There are lots of uses for present value in a business setting. One of them, for example, is in valuing an annuity. And another one that I talked about was in lifetime customer value calculations. A lifetime means over a period of time, you're going to have to discount some of those future time periods to understand the current or present value of the customer. And we finished off today by looking at optimization. What I would call classical optimization using calculus and derivatives and that is some times one of the most useful outcomes of having put a quantitative model into place. Yes, we want to understand that business process, but if I have a reasonable model for that business process, I can then exploit that model through the use of optimization to really fine tune, and optimize how my business is working. 



Không có nhận xét nào:

Đăng nhận xét

Tìm kiếm Blog này

Lưu trữ Blog