0
$\begingroup$

I need to plot the direction field and phase plane of the following ODE using matlab. I've tried using meshgrid w/ the quiver function, however, I'm not getting the correct field.

I need to plot

$\frac{dy}{dx}=$ $\frac{y(1.98x-1)}{0.5-x(1.98y+0.5)}$

$\endgroup$
  • $\begingroup$ Is this a question about mathematics or programming? The latter you should better ask on stackoverflow. In both cases the code, the plot and an explanation of what is wrong about it or why you think it is wrong should be added. $\endgroup$ – LutzL Mar 8 at 7:36
  • $\begingroup$ Disregarding the directions, it should give an impression like this Wolfram Alpha stream plot $\endgroup$ – LutzL Mar 8 at 7:47
  • $\begingroup$ OP: By using $\frac{\mathrm{d}y}{\mathrm{d}x}= \frac{\mathrm{d}y}{\mathrm{d}t} \div \frac{\mathrm{d}x}{\mathrm{d}t}$, you can rewrite the expression as: $x'=0.5-x(1.98y+0.5)$ and $y'=y(1.95x-1)$, where the derivative is with respect to say, $t$. Then you can reuse the matlab code found educ.jmu.edu/~strawbem/Phase_how_to.pdf $\endgroup$ – Winter Soldier Mar 23 at 17:45

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.