(*^ ::[ frontEndVersion = "Macintosh Mathematica Notebook Front End Version 2.1"; macintoshStandardFontEncoding; paletteColors = 128; automaticGrouping; currentKernel; fontset = title, inactive, noPageBreakBelow, nohscroll, preserveAspect, groupLikeTitle, center, M7, bold, e8, 24, "Times"; ; fontset = subtitle, inactive, noPageBreakBelow, nohscroll, preserveAspect, groupLikeTitle, center, M7, bold, e6, 18, "Times"; ; fontset = subsubtitle, inactive, noPageBreakBelow, nohscroll, preserveAspect, groupLikeTitle, center, M7, italic, e6, 14, "Times"; ; fontset = section, inactive, noPageBreakBelow, nohscroll, preserveAspect, groupLikeSection, grayBox, M22, bold, a20, 18, "Times"; ; fontset = subsection, inactive, noPageBreakBelow, nohscroll, preserveAspect, groupLikeSection, blackBox, M19, bold, a15, 14, "Times"; ; fontset = subsubsection, inactive, noPageBreakBelow, nohscroll, preserveAspect, groupLikeSection, whiteBox, M18, bold, a12, 12, "Times"; ; fontset = text, inactive, nohscroll, noKeepOnOnePage, preserveAspect, M7, 12, "Times"; ; fontset = smalltext, inactive, nohscroll, noKeepOnOnePage, preserveAspect, M7, 10, "Times"; ; fontset = input, noPageBreakInGroup, nowordwrap, preserveAspect, groupLikeInput, M42, N23, bold, L-5, 12, "Courier"; ; fontset = output, output, inactive, noPageBreakInGroup, nowordwrap, preserveAspect, groupLikeOutput, M42, N23, L-5, 12, "Courier"; ; fontset = message, inactive, noPageBreakInGroup, nowordwrap, preserveAspect, groupLikeOutput, M42, N23, R65535, L-5, 12, "Courier"; ; fontset = print, inactive, noPageBreakInGroup, nowordwrap, preserveAspect, groupLikeOutput, M42, N23, L-5, 12, "Courier"; ; fontset = info, inactive, noPageBreakInGroup, nowordwrap, preserveAspect, groupLikeOutput, M42, N23, B65535, L-5, 12, "Courier"; ; fontset = postscript, PostScript, formatAsPostScript, output, inactive, noPageBreakInGroup, nowordwrap, preserveAspect, groupLikeGraphics, M7, l34, w282, h287, 12, "Courier"; ; fontset = name, inactive, nohscroll, noKeepOnOnePage, preserveAspect, M7, italic, 10, "Geneva"; ; fontset = header, inactive, noKeepOnOnePage, preserveAspect, M7, 12, "Times"; ; fontset = leftheader, inactive, L2, 12, "Times"; ; fontset = footer, inactive, noKeepOnOnePage, preserveAspect, center, M7, 12, "Times"; ; fontset = leftfooter, inactive, L2, 12, "Times"; ; fontset = help, inactive, nohscroll, noKeepOnOnePage, preserveAspect, M7, 10, "Times"; ; fontset = clipboard, inactive, nohscroll, noKeepOnOnePage, preserveAspect, M7, 12, "Times"; ; fontset = completions, inactive, nohscroll, noKeepOnOnePage, preserveAspect, M7, 12, "Times"; ; fontset = special1, inactive, nohscroll, noKeepOnOnePage, preserveAspect, M7, 12, "Times"; ; fontset = special2, inactive, nohscroll, noKeepOnOnePage, preserveAspect, M7, 12, "Times"; ; fontset = special3, inactive, nohscroll, noKeepOnOnePage, preserveAspect, M7, 12, "Times"; ; fontset = special4, inactive, nohscroll, noKeepOnOnePage, preserveAspect, M7, 12, "Times"; ; fontset = special5, inactive, nohscroll, noKeepOnOnePage, preserveAspect, M7, 12, "Times"; ; ] :[font = special1; inactive; preserveAspect; ] Discrete and Continuous Dynamical Systems The cell below defines the discrete dynamical system used as an example in the browser window. Evaluate it now. ;[s] 4:0,1;68,0;166,2;181,0;183,-1; 3:2,13,9,Times,0,12,0,0,0;1,13,9,Times,1,12,0,0,0;1,13,9,Times,1,12,65535,0,0; :[font = input; preserveAspect; ] Supply[p_] := 1000 p - 400 Demand[p_] := 1000 - 500 p p[1] := 0.50 p[n_] := p[n] = p[n - 1] + k (Demand[p[n-1]] - Supply[p[n-1]]) k := 0.0002 :[font = special1; inactive; preserveAspect; ] The next cell prints and plots the first twenty years of this model. Evaluate it now. ;[s] 3:0,0;69,1;85,0;87,-1; 2:2,13,9,Times,0,12,0,0,0;1,13,9,Times,1,12,65535,0,0; :[font = input; preserveAspect; ] TableForm[Table[{i, p[i]}, {i, 1, 20}]] ListPlot[Table[{i, p[i]}, {i, 1, 20}], PlotJoined -> True, PlotRange -> {0, 2}] :[font = special1; inactive; preserveAspect; ] You can answer the questions about the discrete dynamical systems by changing the intitial condition, p[1], and the value of k. The next cell computes numerical estimates for the initial value problem used as an example in the browser window. Evaluate it now. ;[s] 7:0,0;102,1;106,0;125,1;126,0;245,2;260,0;262,-1; 3:4,13,9,Times,0,12,0,0,0;2,13,9,Times,1,12,0,0,0;1,13,9,Times,1,12,65535,0,0; :[font = input; preserveAspect; ] Clear[solution, p, k] InitialCondition := 0.50 k := 0.0002 solution=NDSolve[ {p'[t] == k (Demand[p[t]] - Supply[p[t]]), p[0] == InitialCondition}, {p}, {t, 0, 20}]; Plot[p[t] /. solution, {t, 0, 20}, PlotRange -> {0, 2}] :[font = special1; inactive; preserveAspect; ] You can answer the questions about continuous dynamical systems by changing the values of InitialCondition and k. ;[s] 5:0,0;90,1;106,0;111,1;112,0;114,-1; 2:3,13,9,Times,0,12,0,0,0;2,13,9,Times,1,12,0,0,0; ^*)