On 11/14/11 3:51 PM, v...@ukr.net wrote:
On Mon, 14 Nov 2011 12:56:26 -0800
William Stein<wst...@gmail.com>  wrote:

What input did you give to get the output you show in the file above?


On Mon, 14 Nov 2011 15:33:50 -0600
Jason Grout<jason-s...@creativetrax.com>  wrote:

There were some changes in how aspect ratio and figure sizes are
handled in 4.7.2, so yes, it would be great if you could give the
code that gave the figure you posted.


   Here is the code I use:

e = 1

curves_graphs = []
curves = []

for n_a in [1,2,4,8]:
     p = []
     p.append(N(exp((n_a/e)*(exp(-e)-1))))

     for n in range(1,20):
         sum = 0
         for l in range(0,n):
             sum += p[n-1-l]*exp(-e)*(e**l)/factorial(l)
         p.append(N(n_a*sum/(n)))
     curves.append(p)
     curves_graphs.append(bar_chart(p, width=1.0, rgbcolor=(0.4,0.4,1)))

curves_plot = graphics_array(curves_graphs)
curves_plot.show(ymin=0, ymax=0.7, figsize=[8,4])

Thanks. The problem here is that the aspect ratio was not getting set correctly (so the first three plots were plotted with an aspect ratio of 1 instead of 'automatic'). This is fixed in the patch at trac ticket #11963, which hopefully will be finished and merged before the next release. As a work-around, you can do (in the last statement):

curves_plot.show(ymin=0, ymax=0.7, figsize=[8,4],aspect_ratio='automatic')

Thanks,

Jason

--
To post to this group, send email to sage-support@googlegroups.com
To unsubscribe from this group, send email to 
sage-support+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/sage-support
URL: http://www.sagemath.org

Reply via email to