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

Home » Public Forums » archive » Problem with Polar_contour
Show: Today's Messages :: Show Polls :: Message Navigator
E-mail to friend 
Return to the default flat view Create a new topic Submit Reply
Problem with Polar_contour [message #62083] Mon, 25 August 2008 12:46 Go to previous message
tarequeaziz is currently offline  tarequeaziz
Messages: 20
Registered: November 2007
Junior Member
Dear IDL GODS,

I am back with another problem.

I am having troubles regarding polar_contour. The problem is as
follows. I got the following code from one of my buddy where he uses
polar_contour procedure to plot polar data.


" tit='cf_100_ave_POLAR.DAT'


fileout='cf_100_polar.eps'


;---------------
device, retain=0 <-------------------- THIS IS ONE OF
THE PLACES WHERE I GET STUCK !!!!
device, decomposed=0
device, true_color=2048 <------------------- THIS IS ANOTHER
POINT
loadct,1
;---------------


!p.multi=[0,1,1]


;---------------
Ntime=1
Ntime1=Ntime-1l
Nr=0l
Nthe=0l
openr,1,'E_NrNp.dat'
readf,1,Nr
readf,1,Nthe
close,1
;---------------


Nrighe=Ntime*Nr*Nthe
Nslide1=Nr*Nthe
Nslide=Nr*Nthe-1
NDT=1l
Tstart=0l
TIMEEPS=Ntime1
nn=0l
;


openr,1,'POL.data'
polaro=dblarr(2,Nslide1)
readf,1,polaro
close,1

;

nlev=128
lab=findgen(nlev)+1


wrk=dblarr(2,Nslide1)
wrk(0,*)=polaro(0,0:Nslide)
wrk(1,*)=polaro(1,0:Nslide)
r=reform(wrk(0,*),Nthe,Nr)
t=reform(wrk(1,*),Nthe,Nr)



openr,2,tit,/f77_unformatted
data1=dblarr(Nslide1)
data0=dblarr(Nr,Nthe)





nframe=0l
for j=0l,Ntime1 do begin
readu,2,data0
endfor

RMIN=MIN(data0)
RMAX=MAX(data0)
;RMIN=ABS(RMAX - RMIN)/


nn=0l
for ir=0l,Nr-1 do begin
for ithe=0l,Nthe-1 do begin
data1(nn)=data0(ir,ithe)
nn=nn+1l
endfor
endfor

ttt=j*1.0

tit0=string(ttt,format='(" - F - Time = ",F10.2)')

z1=reform(data1,Nthe,Nr)


;~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
polar_contour, z1,t[*,0],r[0,*],/
FILL,nlevels=nlev,title=tit,zr=[-0.3,RMAX]
;~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~


close,2 "


Now when he runs it in his machine (with IDL version 6.2) it just
works like a charm but the same code breaks down when I want to run on
machine (with IDL 7.0).

As I showed on the code, program breaks down at weird places, like
"DEVICE,RETAIN=0"( shown above). It says that, retain is NOT allowed
for device command, how ridiculous!!!!!

Even if I circumvent this area, when it gets down to polar_contour
command, it says, it cannot plot since the points are collinear !! How
come then it works on his machine?????

As far as I can see, the code seems alright. I just cannot figure out
why it is breaking down on my machine.


Please help...!!!!!!!!

Best,

T
[Message index]
 
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: Re: Problem with Polar_contour
Next Topic: Having trouble stopping a loop (or loop de loop de loop)

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

Current Time: Fri Oct 10 13:15:34 PDT 2025

Total time taken to generate the page: 1.04065 seconds