PRO read_dr2_ce,lun,is,ie,i,omega,dr2,x,ce,file=kfile ; ; needs first to read_ampli, for defining the values for is and ie ! ; ; reads the 'fort.82', the d/dr(\delta r), i.e ; the derivatives of the displacement eigenfunction \delta r ; and displacement EF x, and ce = x^2*r^2*dm/dlnp * 1e-30 ; ; hg: 02/03/98 ; ; input: ; ; kfile ..... input filename ; ; ouput: ; ; is ....................input...... # of starting meshpoint (defining surface) ; ie ....................input...... # of end meshpoint ; i .....................output..... # of modes (eigenfrequencies) ; omega(*) ..............output.... eigenfrequencies ; dr2(im,ie-is+1) .......output..... dataset of variable ; x (im,ie-is+1) .......output..... dataset of variable ; ce (im,ie-is+1) .......output..... dataset of variable ; if (n_params(0) lt 1) or keyword_set(hlp) then begin print,' usage: read_dr2_ce,lun,is,ie,i,omega,dr2,x,ce,file=fndr2' return endif ; if keyword_set(kfile) then begin if keyword_set(lun) eq 0 then lun=1 close,lun openr,lun,kfile,/f77_unformatted endif ; om=0.d0 i=0 im=50 n3=ie-is+1 ; dr2=dblarr(im,n3) x =dblarr(im,n3) ce =dblarr(im,n3) omega=dblarr(im) line=dblarr(3,n3) ; WHILE NOT EOF(lun) DO BEGIN READU,lun,om,line ; ; copy read data into dr2 dr2[i,0:n3-1]=line[0,*] x[i,0:n3-1]=line[1,*] ce[i,0:n3-1]=line[2,*] omega[i]=om ; IF i LT (im-1) THEN i=i+1 ELSE $ STOP,'forced stop (exhaust of array)',im,' records read' ; ; ENDWHILE ; PRINT,i,' modes of dataset read' ; dr2=dr2(0:i-1,*) x =x(0:i-1,*) ce =ce(0:i-1,*) omega=omega(0:i-1) ; RETURN END