Gerald Wenzel
math notes
Monday, January 10, 2011
Sage 2D plot
var('x y')
p=plot((x-1)/(x+2),(-5,1), color='red')
xmin=-5
xmax=1
ymin=-10
ymax=10
p.show(axes=True, xmin=xmin, xmax=xmax, ymin=ymin, ymax=ymax)
Add XY axis to MatLab 2D plot
%%
syms
x y
;
ezplot((x-1)/(x+2));
% Add xy axis to above function plot.
% line([x1 ; x2],[y1 ; y2])
% where line goes from (x1,y1) to (x2,y2)
line([-10 ; 10],[0 ; 0],
'color'
,
'black'
,
'LineStyle'
,
':'
)
line([0 ; 0],[-10 ; 10],
'color'
,
'black'
,
'LineStyle'
,
':'
)
Newer Posts
Home
Subscribe to:
Posts (Atom)