On 2011-08-22  , at 16:06 , nasim hhhhh wrote:

> for( var i:Number= -10000 ;i<10000;i+=.001) { arr[i]=new object() arr[i].x=i
> arr[i].y=5*Math.sin(20*i);
> functiononlinedraw()
> }

Perhaps the problem is simply that you're trying to plot too many points.  If 
you're stepping from -10000 to +10000 in increments of 0.001, that's 20 million 
points.  Plotting 20 million points of a sine function seems a little futileā€¦

I suggest you try a smaller range and bigger increment first, just to see 
whether the code's basically working, e.g. go from -100 to +100 in steps of 0.1.

If speed and space are issues, try using two vectors of Numbers, one for the x 
values, the other for the y values. 

-Gerry
_______________________________________________
Flashcoders mailing list
Flashcoders@chattyfig.figleaf.com
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Reply via email to