Plotting a phase portrait of a differential equation

Hey Folks.

I was just wondering if there was an existing package or tool for plotting the phase portrait of a system of differential equations, or a phase portrait plus direction field? I am thinking of a plot like this for the system of equations.

\frac{dx}{dt} = -x \\ \frac{dy}{dt} = 2y

The corresponding plot would be (taken from Haberman’s ODE textbook):

Selection_002

I did not see any mention of this in the plots documentation for the Julia DifferentialEquations package, but perhaps the plot is in a different package.

It is not too bad to develop a plot like this myself, but just was wondering if anyone already had developed this–since it is such a common plot for differential equations.

Note that there was a previous post on this topic, but I don’t believe it received a response.

5 Likes