In the prior video, I left you halfway up the mountain. I had asked you to take that ninth step, that ninth experiment on your own. Were you able to find the location of that next run? As we proceed, we will cover two diversions. We will look what happens if you have constraints in your experiment. By that, I mean, what happens if you want to take a step, and realize because of safety issues, or for other reasons that you can't quite go as far as you'd hoped. We will also look at mistakes. What if you, or your colleagues, run an experiment but use the wrong settings. We'll show that you can easily recover from that. And in the prior video, I ended by asking you to take a step size with delta xp=1.5. If you did that you would have found the associated delta xT equal to 0.718. Now let's convert these delta lower case x's to their upper case real world changes, using the formulas we introduced in the prior video. For throughput, this lower case delta xT corresponds to an increase of 2.87 parts per hour, which we round to 3 parts. For price it's a $0.27 increase that we would add to the baseline value. Now, we can go tell our employees or colleagues that the ninth experiment is at 337 parts per hour with a price of $1.45. Remember our colleagues don't speak in coded units. We have to talk with them in actual units even though we speak in coded units behind their backs when we deal with the least squares model. Now we should always go predict the outcome of the experiment before running it. In coded units, xp for the ninth experiment is at 1.5 because we selected that. You might presume that the xT value is 0.718 that you calculated but not quite. Because remember we rounded that value. So we should go recalculate what xT is for run nine. Using the usual formula that connects real world units to coded units. So that value of xT is equal to 0.75. When we go use the model, the prediction with these coded values give us a profit prediction of $731. Now if you go to the website and run the actual experiment, you might get a value close to 717. Our prediction was off by about 13 or $14. You should have been able to do all of the above after watching the prior videos. If not, go back to the prior video and recap with those calculations where they were shown in some detail. Now how bad is that prediction error of $13? One way to tell, is by comparing it to the value from the noise in the system, and to calculate the noise we need some replicated experiments which we haven't gone and done. But if we had the time and budget, we could certainly do that, and verify. But a rough way that we can get an estimate of that noise, is by comparing it to the coefficient of the main effects in the model. And it is about half the size of the smallest main effect. So that prediction error is not too bad. Now since the model's predictions are still adequate, we can keep going up this direction of steepest descent. This is new. In the prior factorial, we had to stop and rebuild after using its single step. But this time, our predictions are still okay, so we keep going. This is the general principle of response surface methods. Keep going up that path as long as the predictions are consistent with reality. Now we can try step to delta xp equals 2.5 away from the baseline. Pause the video and try to calculate these quantities at this new tenth experiment yourself. You'll soon become an expert at these calculations, but it will take you several minutes at first. Once you're done with your work, go compare your prediction to the actual experiments using the website. So these are the values you should have obtained. Delta xT equal to 1.2, delta T in real world units is a change of 4.8 parts per hour and we'll round that up to 5. Delta p is 0.45 or $0.45. T for the tenth experiment corresponds to 339 parts an hour and p is $1.63. XT encoded units is 1.25. Just a little bit different from the 1.2 that we had calculated earlier due to rounding. And xp is equal to 2.5. Using those coded values, we can predict a y value for the tenth experiment of $784.77 or 785. Now the actual experimental outcome is around 732. You won't get that exact figure from the website because we add some noise to the prediction just to make things realistic. That's about a $50 deviation though, and it's comparable to the main effect of the largest factor, the price. So it's probably time to rebuild this model, and the tenth experiment can form our baseline. Notice that when we do this, we reset our 0, 0 center point to this new location in real world units. We do not use the previous factorials coded units. We start fresh and build a new local model to approximate the surface in this region. What range should we use for the new factorial? I'm going to use a slightly smaller range for the throughput T of six parts per hour, for two reasons. First, we're coming close to our upper bound of 350 parts an hour. In case there's an optimum near this bound, we will see in the next video, we should have a bit of room to move outside the factorial bounds to fit a non-linear model. Secondly, we might suspect we're leveling off. And the way I can see this is by looking at the spread in the profit values in the first factorial. See how far apart they are over there. And here in the second factorial, they're closer together. That reduction indicates there might be a leveling off, and we don't want to overshoot the optimum by taking too large a step. For price, P, I'm going to take the same range as before. We are still far away from the extreme upper bound, but if you'd like to use a different range for the price, go ahead and try using perhaps $0.20 for example. You'll see that your direction to the optimum is not very different to the one I'm going to take with the $0.36 range. So let me have a small digression here. You might be wondering, if your choice of range will have a significant impact on the path of steepest descent. You notice that the direction of steepest descent is in proportion to the range of the factors chosen. If you were doing the experiments, it's quite likely you will pick a different range to the one that I will pick. Fortunately, and it has been shown in various statistical textbooks that these different range choices selected by different experimenters will lead to a different path up the mountain, but not radically different. There is this idea of a confidence interval of paths so to speak. So the bottom line is this. Don't be too concerned about the range choice as long as it is reasonable, and leaves your room to the left and the right of your extreme bounds to approach that mountain peak. Now back to the factorial. Here are experiments 11, 12, 13, and 14, and their corresponding profit values. Remember we run them in random order, but I report them here in standard order. If you write and run the R code, you can show you get the following linear model from the five experiments, including the baseline points at position ten. Pause the video, and fit the model from the data points. What interesting feature do you notice in the contour plot? You would've observed some curvature in the conduits. This is an indication that something has changed in the surface. Now you can happily skip on to the next video and see how to continue this analysis, but to end this video, I'm going to divert and talk a little bit about experimental mistakes. I'm going to show what happens when you hit into constraints. But feel free to come back to this topic later on, if you just want to jump ahead and see how the case study continues. So, to talk about mistakes. I will use run number 9 over here, and show how we could have used it a bit more effectively. Notice that run 9 and run 11 are close to each other. If I was planning this third factorial here, it runs 11, 12, 13, and 14, and if my experiments were really expensive, I would want to know if I can use experiment 9, and avoid running experiment 11. And the answer is yes, you definitely can. We use the concept of a botched design, which is just an English word for mistaken design. Mistakes happen all the time in experiments in two main ways. Firstly, imagine your employee wanted to actually run experiments 11, but made a mistake with the settings and run the experiment at position 9 by accident. Another way this could have happened is to imagine that if you are running experiments in random order, you might have run experiment 12 then 13 then 14, and then you want to come and run experiment 11 when you suddenly realize that condition would be unsafe or lead to totally different very unexpected operation. Someone in the course forums asked exactly that question. You might think that you'd have to shrink experiment 12 over to this location to line up with experiment nine and get back to regular factorial, but it is not necessary. The important insight is that you can get an adequate model with these four points even if they're not in perfect alignment with the minus one and plus one positions, they would normally occupy on the cube plots. But, if one or more of the experiments are shifted you must use the correct coded value for them. 4.9, for example, the correct coded value is -0.67 from this equation, not -1. So in our R code, instead of -1, -1, +1, +1 for the factor T, we use the mistaken values of -0.67, -1, +1, +1. And we enter the outcome value we got at that mistaken point. Now mistaken experiments, because they're not at these -1 and +1 positions are generally calculated with a computer and not by hand. When you rebuild the model, you get the following prediction equation and contour plot. Let me contrast that to the situation over here on the right. Where I had used experiments at position 11, 12, 13 and 14. And you can see that, that model is not very different to the model with the mistake. Now you do lose some of the useful properties we get when the design was run at the correct values. But if this small change means saving lots of money to avoid redoing an experiment, it's really worth the price. Notice that you definitely did not have to shrink in your range. So we have discussed what to do with constraints that relate to mistakes or botched designs. What about constraints that are imposed by the system? Constraints that you know about before the time? It is common for systems to have such constraints that prevent operation outside a certain region. I'm talking not just about constraints that align with the extreme vertical or horizontal edges of the factors outside which you cannot operate. But rather, I'm referring to constraints that cut entire regions out of consideration. For example, a constraint that runs along this direction shown in red, and anything beyond it, we cannot go and run over there. What if the path of steepest descent was showing a promising direction along here in green. Well then we modify our path to obey that constraint. But, we have to always obey safety requirements in our process. They're of primary importance and we have to find our optimum within those restrictions. And I'll end by saying, it is not uncommon to find your optimum right at the boundary of a constraint. We see that in engineering systems frequently, and it's likely to occur in other systems as well. So that's the end of this video. In the next video, we'll resume going back to the factorial with this baseline at point 10. Where would you run your next experiment? Use the tool on the website and try a few runs yourself before watching the next video.