xxxxxxxxxx
def _(cmap=['cool','prism','jet','flag',
'gnuplot','tab10','tab20']):
var('x,y'); f(x,y)=(x^2-y)*sin(x*y); t=3
ld={-t:'f=-%d'%t,0:'f=0',t:'f=%d'%t}
cp=contour_plot(f,(x,-t,t),(y,-t,t),
contours=[-t,0,t],fill=False,
cmap=cmap,labels=True,label_inline=True,
label_fmt=ld,label_colors='black')
cp.show(figsize=(5,5))
No comments:
Post a Comment