cs249 lecture notes, Fall 2001 Week 9, Monday No class on Thursday. Get together to work on the assignment if you like. Chaos ----- A dynamical law is one that predicts the future behavior of a system based on the current or initial conditions. Classic example is Newton's three laws of motion. Success of Newtonian mechanics led to the Principle of Determinism, which is that all physical systems are deterministic: given the current state of the system, we can predict the future state, for any length of time. More specifically, the Principle of Determinism assumes that the accuracy of the answer depends on the accuracy of the initial conditions. Even more specifically, it was commonly assumed that doubling the accuracy of the initial estimates would double the accuracy of the predictions. This turns out to be FALSE (at least some of the time). For many systems, the error in the prediction increases quickly (exponentially) with time. 1) short-term predictions can be accurate 2) long-term predictions are no better than chance 3) better initial conditions might give the ability to predict SLIGHTLY longer into the future, but they do not improve the accuracy of the prediction after that point. These systems are said to be "dynamically unstable" or CHAOTIC. Warning: this is a specific, technical definition of "chaotic". It does NOT mean disorderly or apparently random. Some chaotic systems are apparently orderly, and they are all deterministic, but they cannot be predicted accurately. Why not just measure initial conditions perfectly? 1) as an experimental matter, that's impossible 2) as a modeling matter, it's irrelevant even if the measurement were exact, there is always SOMETHING in the model that you left out. Why did you leave it out? Because you assumed that it would have a small effect on the outcome. In chaotic systems, even the smallest perturbation can have a wild effect on the result: "Butterfly effect" 3) In numerical computations, we are constantly perturbing the system with roundoff errors and truncation errors (as in Euler's method). Chaos is a trendy topic in mathematics, and has been written up in several popular treatments, including most notably Chaos : Making a New Science, by James Gleick Predator-prey model ------------------- What does all this have to do with us? Predator-prey model is an example of a non-linear dynamical system. It is a particularly interesting one because it is sometimes chaotic and sometimes not, depending on the parameter r. For some values of r, the population converges on an stable fixed point. For some values, it converges on a stable periodic fixed point. If the system converges to a stable fixed point, is it chaotic? For some values of r the system is chaotic, which means that future values are very sensitive to initial conditions. A quick MATLAB hint ------------------- To draw a column of points at location r: // red is a vector of population values // r is the parameter that generated red rvec = r * ones (1, length(red)); h = plot (rvec, red, 'r.'); set (h, 'MarkerSize', 3);