mplot

452 days ago by volosati

from sage.plot.matrix_plot import MatrixPlot import matplotlib.cm import numpy #l=matplotlib.cm.hot(srange(0,1,0.1)) l=map(tuple,matplotlib.cm.hot(srange(0,1,0.1))) n=numpy.array([[1,1,1,3,3,3,3,3,3,3,3,3,1,1,1],[1,1,1,4,3,3,3,3,3,3,3,4,1,1,1],[1,1,1,3,3,3,3,3,3,3,3,3,1,1,1],[2,2,2,4,4,3,3,3,3,3,4,4,2,2,2],[2,2,2,4,4,3,3,3,3,3,4,4,2,2,2],[2,2,5,5,4,3,3,3,3,3,4,5,5,2,2],[2,6,5,5,5,5,3,3,3,5,5,5,5,6,2],[4,4,5,5,5,5,3,3,3,5,5,5,5,4,4],[4,5,5,5,5,5,3,3,3,5,5,5,5,5,4]],'int32') m=matrix(n); m; m.parent() list_plot3d(m, interpolation_type='nn',frame_aspect_ratio=[1,1,1/3],adaptive=true)