power,'_mag','hel_mag',k=k,spec1=spec1,spec2=spec2,i=n,tt=t,/noplot
power,'_GWs','hel_GWs',k=k,spec1=grav1,spec2=grav2,i=n,tt=t,/noplot
;power,'_Str','hel_Str',k=k,spec1=grav1,spec2=grav2,i=n,tt=t,/noplot
;
;  $Id: ppower_allb.pro,v 1.2 2017/08/23 23:25:43 brandenb Exp $
;
;  This routine is used to view all power spectra
;  that were written during the run (controlled by dspec)
;  The plot range yr is set to a default value.
;  The time interval of plotting is "w" (default value)
;
;   5-oct-02/axel: written
;
spawn,'if (! -f param.pro) touch parameters.pro'
@parameters
xr=[1,max(k)]
istride=1
default,w,.2
default,t1,.0
default,iover,0
default,istride,1
default,yr,[3e-12,3e-2]
ampl15=3e-10 & ampl4=1e-13
ampl15=3e-6 & ampl4=1e-8
circ_sym,1.3,1
;
good=where(t ge t1)
i1=min(good)
i2=n-2
;
for i=i1,i2,istride do begin
  if iover eq 0 or i eq 0 then begin
    plot_oo,k,spec1(*,i),xr=xr,yr=yr,tit='t='+str(t(i))
  endif
  oplot,k,spec1(*,i)
  oplot,k,abs(spec2(*,i)),li=1
  oplot,k,spec2(*,i),col=122,ps=8
  oplot,k,-spec2(*,i),col=55,ps=8
  ;
  oplot,k,grav1(*,i),col=188
  oplot,k,abs(grav2(*,i)),li=1,col=188
  oplot,k,grav2(*,i),col=122,ps=8
  oplot,k,-grav2(*,i),col=55,ps=8
  ;kk=[1.,5.] & oplot,kk,.02/kk^8
  ;kk=[1.,5.] & oplot,kk,1e-23*kk^2
  print,i,t(i)
  wait,w
end
;
END
