comp.lang.idl-pvwave archive
Messages from Usenet group comp.lang.idl-pvwave, compiled by Paulo Penteado

Home » Public Forums » archive » Re: A problem using IDL?
Show: Today's Messages :: Show Polls :: Message Navigator
E-mail to friend 
Return to the default flat view Create a new topic Submit Reply
Re: A problem using IDL? [message #60099 is a reply to message #60080] Thu, 01 May 2008 08:41 Go to previous messageGo to previous message
Vince Hradil is currently offline  Vince Hradil
Messages: 574
Registered: December 1999
Senior Member
On May 1, 9:49 am, pgri...@gmail.com wrote:
> If you want a meaningful plot of a sinusoidal function,
> you should make sure that you have enough data
> points (say, at least 10) in each cycle (period) of the function.
> If this condition is not fulfilled, the plot will look strange.
>
> Cheers,
> Paolochih...@sohu.com wrote:
>> I used idl to write the following:
>
>> window,xsize=800,ysize=400
>> min=0
>> max=100
>> n=200
>> x=fltarr(n+1)
>> for i=0,n do x[i]=min+double(i)*(max-min)/n
>> print,x
>> y=sin(2*3.141593*x)
>> plot,x,y
>
>> When n=100 or n=200,the graph is wrong. When n >=300,it's OK.Can
>> someone tell me why?

Also, combined with: http://www.dfanning.com/math_tips/sky_is_falling.html
[Message index]
 
Read Message
Read Message
Read Message
Read Message
Previous Topic: Re: ProductLog function
Next Topic: idl array question

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ] [ PDF ]

Current Time: Thu Oct 09 23:51:44 PDT 2025

Total time taken to generate the page: 0.07959 seconds