- #1
cupcake
- 76
- 0
Homework Statement
write down the scilab code that will plot the direction field of dy/dx = x^2 + y^2 -1 on a suitably large rectangle. you have to adjust the interval values of x and y so as to get a clear picture.
Homework Equations
dy/dx = x^2 + y^2 -1
The Attempt at a Solution
I have been trying to do this question, but I'm not sure whether I did it correctly or not, since I have to learn scilab with my own. so, here's my code...
-->deff('[xdot]=f(x,y)', 'xdot=[x(1).^2; y(1).^2-1]')
-->fchamp(f, 1, -4:0.4:4, -4:0.4:4, 1.5)
-->mtlb_axis ( [-4 4 -4 4] )
-->xlabel('x')
-->ylabel('y')
please correct me if I'm wrong..