ABSTRACT

This chapter covers the initial value problem along with MATLAB's built-in ode45 function to solve these types of problems. It demonstrates MATLAB's ode45 function, which is based on fourth- and fifth-order Runge–Kutta methods. Many ordinary differential equations (ODE) result from a particular physical law. The physical law is a mathematical model of some particular physical phenomenon. MATLAB has several built-in ODE functions that solve a system of first-order ordinary differential equations, including ode23 and ode45. Initial value problems are those in which the initial conditions of the variables are known. Boundary value problems in which we know variable conditions at specific coordinates in the problem geometry. The time interval TSPAN is typically a two-element vector containing a start and end time; ode45 will automatically choose an appropriate time step. ode45 will return two vectors: a list of time points TOUT and the solution YOUT at each time point.