ChaosPlot by Jason Regier What is ChaosPlot? ChaosPlot is a simple program which plots the chaotic behavior of a damped, driven anharmonic oscillator. This program, intended to be used for educational purposes, allows the user to change parameters in the differential equation describing the oscillator and to modify various plotting parameters. How Does It Work? ChaosPlot evaluates the following differential equation: d^2x/dt^2 = F_0 sin(wt) - kx -qx^3 -b dx/dt for various values of the parameters F0, w, k, q, and b and the initial conditions x0 and v0. F0 is the amplitude of the driving force and w controls its frequency. k is the spring constant for the ideal spring portion of our spring potential. q represents the amplitude of the anharmonic term of the spring potential which makes our spring vary from one which follows HookeÕs law. b is the amplitude of the drag term, which depends on the velocity of the springÕs motion. To plot this complex equation, ChaosPlot splits the second order differential equation into two first order differential equations and solves them simultaneously using a fourth-order Runge-Kutta algorithm: dx/dt = v and dv/dt = f(x,v) = F_0 sin(wt) -kx -qx^3 -bv The results of this algorithm are passed to a plotting routine which plots the points on either the x vs. t, v vs. t, or v vs. x axes. The input parameters, including equation constants, scale of the plot, step size, and time length, can be controlled from the Change Plot Parameters menu item under the File menu. To change between each of the 3 plots listed above, one need merely select the desired plot from the Plot menu. As usual, to change the printing parameters, select Page SetupÉ from the File menu. To Print the plot currently displayed on screen, select PrintÉ from the File menu. The current plot parameters will be printed below the current plot. To quit the program, click in the close box in the upper left of the Plot window or select Quit from the File menu. Notes... Here are some physical interpretations of various input equation parameters: F0 = b = q = 0, k > 0 Simple harmonic oscillator F0 = k = q = 0, b > 0 Nonoscillatory damped motion F0 = q = 0, k and b > 0 Damped simple harmonic oscillator F0 = 0, k < 0, and q, b > 0 Damped anharmonic oscillator q = 0 and F0, w, k, b > 0 Damped, driven harmonic oscillator k < 0 and F0, w, q, b > 0 Damped, driven, anharmonic oscillator (table omitted) Remember, using excessively small step sizes will lead to a very accurate solution of the differential equation, but can take a VERY long time to execute and to print. You might notice some small wobbles in the plots produced by ChaosPlot. These tiny wobbles are most likely not real, but are rather a result of connecting successive data points. The finite step size in the Runge-Kutta algorithm means that curves are not truly smooth; they are formed by connecting successive data points with straight lines. I have found that a smaller step size does not necessarily remove the wobbles. In fact, sometimes the wobbles may be more noticeable because of severe overplotting using small increments. If you really care whether a wobble is truly there or is a figment of the algorithm, change the plot parameters to zoom in on that portion of the plot. Legalese... ChaosPlot is wholly the work and a fully owner product of Jason Regier, all rights reserved. In addition, regardless of whether ChaosPlot fails of its essential purpose, in no event will Jason Regier be liable to you for any special, consequential, indirect or similar damages, including any lost profits or lost data arising out of the use or inability to use the software. Execution of the ChaosPlot program is tacit agreement to the above statements. ChaosPlot is distributed as Shareware and may not be sold in any way without the express written consent of the author, Jason Regier. I hope you have fun with ChaosPlot and learn a little about the fundamentals of chaos! Experiment with this program and send me some interesting parameter settings. If you think ChaosPlot is worth keeping, please send me $5-$10 as a reimbursement for the time I spent working on this project. I can be reached at: Jason Regier Platt Campus Center Harvey Mudd College Claremont, CA 91711 or via email: Jason_Regier@hmc.edu