> #OK to post #HW26, Tim Nasralla, 12/5/21 > #Question 14 ii: Use TimeSeries to check stability of equilibrium points > read "/Users/tan88/OneDrive - Rutgers University/DMB.txt" First Written: Nov. 2021 This is DMB.txt, A Maple package to explore Dynamical models in Biology (both discrete and continuous) accompanying the class Dynamical Models in Biology, Rutgers University. Taught by Dr. Z. (Doron Zeilbeger) The most current version is available on WWW at: http://sites.math.rutgers.edu/~zeilberg/tokhniot/DMB.txt . Please report all bugs to: DoronZeil at gmail dot com . For general help, and a list of the MAIN functions, type "Help();". For specific help type "Help(procedure_name);" ------------------------------ For a list of the supporting functions type: Help1(); For help with any of them type: Help(ProcedureName); ------------------------------ For a list of the functions that give examples of Discrete-time dynamical systems (some famous), type: HelpDDM(); For help with any of them type: Help(ProcedureName); ------------------------------ For a list of the functions continuous-time dynamical systems (some famous) type: HelpCDM(); For help with any of them type: Help(ProcedureName); ------------------------------ > Help(TimeSeries) TimeSeries(F,x,pt,h,A,i): Inputs a transformation F in the list of variables x The time-series of x[i] vs. time of the Dynamical system approximating the the autonomous continuous dynamical process dx/dt=F(x(t)) by a discrete time dynamical system with step-size h from t=0 to t=A Try: TimeSeries([x*(1-y),y*(1-x)],[x,y],[0.5,0.5], 0.01, 10,1); > #F(x) = -2*x^4 + 12*x^3 - 22* x^2 + 12*x #Eq Point 1: x = 0 > TimeSeries([-2*x^4+12*x^3-22*x^2+12*x],[x],[0.01],0.01,10,1); > TimeSeries([-2*x^4+12*x^3-22*x^2+12*x],[x],[-0.01],0.01,10,1); > #Around x = 0 is not stable. Starting from x = 0.01 leads to a horizontal > asymptote at x = 1 which is a possible stable point. > #Eq Point 1: x = 1 > TimeSeries([-2*x^4+12*x^3-22*x^2+12*x],[x],[1.01],0.01,10,1); > TimeSeries([-2*x^4+12*x^3-22*x^2+12*x],[x],[.99],0.01,10,1); > #Due to the horizontal asymptotes shown, x=1 is stable > #Eq Point 1: x = 2 > TimeSeries([-2*x^4+12*x^3-22*x^2+12*x],[x],[2.01],0.01,10,1); > TimeSeries([-2*x^4+12*x^3-22*x^2+12*x],[x],[1.99],0.01,10,1); > # x = 2 is not stable. However, starting at 2.01 leads us to a horizontal > asymptote at x = 3 which is most probably stable. > #Eq Point 1: x = 3 > TimeSeries([-2*x^4+12*x^3-22*x^2+12*x],[x],[3.01],0.01,10,1); > TimeSeries([-2*x^4+12*x^3-22*x^2+12*x],[x],[2.99],0.01,10,1); > #Since starting above and below x = 3 yields a horizontal asymptote at x = 3, > x=3 is a stable equilibrium solution. > #Question 15, find the first four terms of the given function > Orb([x^3+2*y,x^2+5*y^2],[x,y],[1,3],0,2) [[1, 3], [7, 46], [435, 10629], [82334133, 565067430]] > > #Question 16, confirm the stable equilibrium point given w/ SFP then confirm > it numerically. > SFP([(2+x+y)/(2+2*x+2*y),(2+x+y)/(1+2*x+2*y)],[x,y]) {[0.6953496364, 0.8641637014]} > Orb([(2+x+y)/(2+2*x+2*y),(2+x+y)/(1+2*x+2*y)],[x,y],[0.5,0.4],1000,1010) [[0.6953496364, 0.8641637013], [0.6953496362, 0.8641637010], [0.6953496365, 0.8641637015], [0.6953496364, 0.8641637013], [0.6953496362, 0.8641637010], [0.6953496365, 0.8641637015], [0.6953496364, 0.8641637013], [0.6953496362, 0.8641637010], [0.6953496365, 0.8641637015], [0.6953496364, 0.8641637013], [0.6953496362, 0.8641637010], [0.6953496365, 0.8641637015]] > #The point is clearly stable > #Question 17, confirm numerically that the given equilibrium points are not > stable. TimeSeries([(1-2*x-3*y)*(2-2*x-3*y), > (3-x-2*y)*(1-x-2*y)],[x,y],[-4.9,3.9],0.01,20,1); > TimeSeries([(1-2*x-3*y)*(2-2*x-3*y), > (3-x-2*y)*(1-x-2*y)],[x,y],[-4.9,3.9],0.01,20,2); > #As seen, starting near the equilibrium point over time led to a horizontal > asymptote at [-1,1] which is a stable equilibrium point. > TimeSeries([(1-2*x-3*y)*(2-2*x-3*y), > (3-x-2*y)*(1-x-2*y)],[x,y],[.99,.01],0.01,20,1); > TimeSeries([(1-2*x-3*y)*(2-2*x-3*y), > (3-x-2*y)*(1-x-2*y)],[x,y],[.99,.01],0.01,20,2); > #As seen, starting near [1,0] yielded [-1,1] which is the stable equilibrium > point given.