We're gonna start our exploration of the field of nonlinear dynamics by studying maps - systems that operate in discrete time. And then we'll move to the study of flows - continuous time systems. This distinction may not be something you've come across before. A flow is something like my pendulum, dynamics that operate continuously in time and space. Imagine, though, if you shone a strobe light at the pendulum. Every tenth of a second, that strobe light would illuminate where the pendulum was. That is a map. Time only exists in that dynamical system at discrete intervals. In other words, it doesn't make sense to ask what the state of the system is in between the samples. Monthly economic indicators are like this as are old-fashioned movies which were shot at twenty-four frames per second. There was no picture of the state of the system in between those frames. Here's a slide that summarizes that distinction. The reason to study maps first, by the way, their dynamics are representative. A good example of what can happen in nonlinear dynamical systems, but the math is a lot easier. Most nonlinear dynamics courses take this path for that reason: introducing the ideas and examples in the context of maps and then circling back around through those ideas in the context of flows. The map in that previous slide is a mathematical operator that advances the state one-time click. That is, it takes the current state of the system and tells you what the next state will be. Mathematically, we describe this using what's called a difference equation. Here, n is time, x is the state of the system, f is the map that takes the current state x_n, and moves it one time-click forward, giving you x_n+1. Difference equations are very different than differential equations which we will get to in Unit 3 of this course. Here's an example of a difference equation. This is, for obvious reasons, called the cosine map, and the way that you would implement it is with the cosine key on a calculator. For a simple code loop, it takes the cosine repeatedly. If, for example, you plugged in forty-eight degrees to your calculator or the corresponding number of radiance, and then you hit the cosine key three times, what you would see if you were using my calculator, is this value in the display. And then if I hit the cosine key a fourth fifth and sixth time that value would not change. Now let's imagine plotting the progressions of the iterates of this map as a function of n (time). This is what you'd see. The red arrows on the bottom plot are the action of the cosine map on the previous point . Now, your mileage may vary. You may get 0.9936957. It depends on how your calculator or your computer implements the cosine operator. We'll get back to that as well. One very important notion here is that the iterates of the map converged to a fixed value, and then don't change. That's called a fixed point of the map. Here's another difference equation, it's called the logistic map. Many of you may have seen this especially if you took Melanie's course on complexity. Here again x is the state of the system, n is time, and the map has a parameter It's called R, and the map will do very different things for different values of R, as we will play with over the next couple of segments. This map, by the way, is a very very simple population model. Again, this is covered in far more detail in Melanie's course. You can think of x as something like the ratio of foxes to rabbits in my backyard, and R is something like the ratio of the number of rabbits a fox eats per year and the number of babies a rabbit has per year. That is not a direct correspondence. Again, you can see Melanie's course for a lot better treatment for that model. For the purposes of this course, this is mostly just an example to play with. Now in this equation, x runs from 0 to 1. Those are all equivalent mathematical statements that go with the words I just said. N, again, is time, it is discrete, it is integer valued, and R can range from 0 to 4 before the map blows up. The logistic map has one state variable, so, framed mathematically, the logistic map maps the unit interval to itself, like this. We'll get back to what I mean by mapping an interval to itself a little bit later on. In the mean time, let's plug in a few x's and see what happens. Let's say that the first x is 0.2, and let's say that we're gonna try out R=2. Let's see what happens. How I get x_1 is by plugging in, and what I get when I do that is 0.32. To get x_2, I plug x_1 back into the logistic map, like this. And I can keep doing this and something interesting happens. As we iterate this map, the iterates of x_n approach, again, a fixed point. Let's plot this behavior as we did with the cosine map. Again, you can see that the behavior has converged to a fixed point at 0.5, after going through what is called a transient phase. Here's an app you can use to explore this. At the top left, you can see the webpage link. That link is also on the quiz that follows this video, so don't worry about writing it down. Now this app has a lot of functionality that we'll use this unit and next unit. This week, what you need to pay attention to is the right-hand plot, right here. This box, this box, and this box, and this button. This tells you how many points you wanna iterate the map. This tells you where you wanna start, and this tells you what R value to use. Say, you enter in, let's see, I think we started from 0.2 before and we used an R of 2, And I think I did five iterates, so I'm gonna restart this simulation and I'm gonna get back a nice computer version of the plot that I did very badly by hand. Let's try plotting a few more points to see if that fixed point holds still. Looks like it does. Let's try a different initial condition and see if it goes to the same fixed point. Looks like it does. Let's try changing R a little bit and see what happens. Oops, looks like the fixed point is not the same place. First of all, look at this, fixed point's at 0.5. Fixed point's up a little higher. So the fixed point moves under the influence of the parameter, R. And you can imagine this as a population that stabilizes as a certain ratio of foxes to rabbits in my backyard, as we change the birth rate of rabbits, and the hunger of foxes. It makes sense that that fixed point would raise and lower as I change these parameters. Next time we'll explore a little further out the R x's and see what happens there.