ASKSAGE: Sage Q&A Forum - RSS feedhttps://ask.sagemath.org/questions/Q&A Forum for SageenCopyright Sage, 2010. Some rights reserved under creative commons license.Wed, 24 Jun 2015 17:20:57 +0200Problem with matrix_plot ?https://ask.sagemath.org/question/27192/problem-with-matrix_plot/Hello,
I am using Linux Mint (latest version) with Sage Math 6.7 64bits . All 3D and 2D graphics are working perfectly but matrix_plot. When I use the example (of help):
matrix_plot(matrix([[1,3,5,1],[2,4,5,6],[1,3,5,7]]))
I got only a vertical axis from 2 to -2 . It happens in Firefox and Chrome.
Can someone help me, please? Thank you in advance.
LRMWed, 24 Jun 2015 17:20:57 +0200https://ask.sagemath.org/question/27192/Plotting a latex matrix using text()https://ask.sagemath.org/question/9155/plotting-a-latex-matrix-using-text/I would like to plot a latex'd matrix at a location in a 2d plot. I tried this:
text('$\\left( \\begin{array}{ll} 2 & 3 \\\\ 4 & 5 \\end{array} \\right)$', (1,0) )
and various variations to do with the backslashes being escaped or not. But every time I get an error:
matplotlib.pyparsing.ParseFatalException: Expected end of math '$'
$\left( \begin{array}{ll} 2 & 3 \\ 4 & 5 \end{array} \right)$ (at char 0), (line:1, col:1)
It appears that matplotlib doesn't want to parse an array or a pmatrix etc. Is there a workaround?Kate StangeSat, 14 Jul 2012 09:04:17 +0200https://ask.sagemath.org/question/9155/How to make 1:1 matrix plots?https://ask.sagemath.org/question/7806/how-to-make-11-matrix-plots/Hello,
I want to make a matrix_plot of an array, but it never displays correctly. How would I, for example, make each number in an array into a pixel? I find matrix_plot, in resizing, "corrupts" the image. For example, this is a plot of the Sierpinski triangle:
![Sierpinski triangle](http://img109.imageshack.us/img109/7189/sage0.png)
(it also does this on svg plots), and you can see the array isn't translating correctly to pixels. aspect_ratio=1 doesn't work. A sufficiently large figsize works, but I don't see why this is necessary. Isn't there another way?
Thank you.Eviatar BachSat, 11 Dec 2010 13:37:55 +0100https://ask.sagemath.org/question/7806/