User Tools

Site Tools


gibson:teaching:spring-2016:math445:lecture:timestepping

====== Differences ====== This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
gibson:teaching:spring-2016:math445:lecture:timestepping [2016/04/14 18:21]
gibson [Problem 1]
gibson:teaching:spring-2016:math445:lecture:timestepping [2016/04/14 18:23] (current)
gibson [Problem 4]
Line 172: Line 172:
   x0 = [-2.8; y];                 % set initial position of particle   x0 = [-2.8; y];                 % set initial position of particle
  
-  [t, x] = ode45(@v, [0 T], x0);  % compute x(t) at given values of t+  [t, x] = ode45(@v, [0 T], x0);  % compute x(t) over range 0 <= <= T
  
   plot(x(:,​1),​ x(:,2), '​r-'​); ​    % plot the path   plot(x(:,​1),​ x(:,2), '​r-'​); ​    % plot the path
gibson/teaching/spring-2016/math445/lecture/timestepping.1460683285.txt.gz ยท Last modified: 2016/04/14 18:21 by gibson