plot2d -range



On Thu, 2007-08-30 at 17:01 +0200, Adam Majewski wrote:

> I want to draw list complex points on the screen.
> I do it with procedure which computes and draws points.
> 
> draw_centers(p):=block( P(n):=if n=0 then 0 else P(n-1)^2+c, 
> r:allroots(P(p)), rec:makelist(realpart(rhs(r[i])),i,1,length(r)), 
> imc:makelist(imagpart(rhs(r[i])),i,1,length(r)), 
> plot2d([discrete,rec,imc],[gnuplot_curve_styles, ["with points"]]) )
> 
> But I would lika to draw points on the same horizontal and vertical range.
> adding [x, -2.5,2.5],[y,-2,2] does not work.
> What can I do ?

Looking at your code, it seems that you are using a Maxima version older
than 5.12. The [x,...] and [y,...] options did not work in older
versions, but started to work correctly from version 5.12. However,
versions 5.12 and 5.13 will not accept the gnuplot_curve_styles (my
mistake, I will fix it for 5.14). Thus, you should update to 5.12 or
5.13 and then use the following syntax:

 draw_centers(p):=block( P(n):=if n=0 then 0 else P(n-1)^2+c, 
 r:allroots(P(p)), rec:makelist(realpart(rhs(r[i])),i,1,length(r)), 
 imc:makelist(imagpart(rhs(r[i])),i,1,length(r)), 
 plot2d([discrete,rec,imc],[style,points],[x, -2.5,2.5],[y,-2,2]))$

For big values of p, you might want to try changing "points" by "dots".

> Adam Majewski
> fraktal.republika.pl

Very nice site! I'll talk to you about later, since our research
interests seem to be similar.

Best regards,
Jaime Villate