Due to the lapse in federal government funding, NASA is not updating this website. We sincerely regret this inconvenience.
NASA Logo
Ocean Color Science Software

ocssw V2022
watlev.f
Go to the documentation of this file.
1  subroutine watlev
2 c
3 c compute the water leaving radiance
4 c
5 c**********************************************************************
6 c
7 c include the common blocks
8 c
9  implicit real*8 (a-h,o-z)
10  include 'afrt_rt2.cmn'
11 c
12 c**********************************************************************
13 c compute the downward diffused flux
14  call fluxlvl(fio,fzz,0)
15 c write(*,*)'downward flux above ocean surface',fzz
16  sum = 0.0d0
17  sumtt=0.0d0
18  sumd=0.0d0
19  sumu=0.0d0
20  do j = 1,(nx-1)
21  psum = 0.0
22  do k = 1,2
23  psum=(fio(k,j,1)+fio(k,j,jpart))+psum
24  do i=2,nophi/2
25  psum=psum+2.*fio(k,j,i)
26  enddo
27  enddo
28  sum=sum+psum*dcmusq(j)*(1.0d0-rfair(j))*ddphi
29  enddo
30  sumtt=(eo(1)+eo(2))*cosmu(kkx)*(1.0d0-rfair(kkx))
31  sumd=sum+sumtt
32 c compute the upwelling flux and radiance just below the
33 c ocean surface
34  sumu=alw*sumd
35  radu=sumu/pi
36  albtdr(ksza)=sumtt
37  albtdf(ksza)=sum
38  albtdt(ksza)=sumd
39  albtrf(ksza)=sumu
40 c write(*,150)sum,sumd,alw,sumu,radu
41 150 format('sum,sumd,alw,sumu,radu'/1p5e11.3)
42 c compute the radiance just above the ocean surface
43  do i=1,(nx-1)
44  ii=nmum1-i+1
45  do j=1,jpart
46  radxi(ii,j)=((1.0d0-rfwat(i))*radu)/(xrw**2+xiw*2)
47  radxi(i,j)=0.0d0
48  enddo
49 c write(*,175)i,ii,radxi(ii,1)
50 175 format('radiance just above the surface',2i4,1x,1pe11.3)
51  enddo
52 c
53  return
54  end
55 c**********************************************************************
subroutine fluxlvl(buft, sumg, iflag)
Definition: fluxlvl.f:2
#define pi
Definition: vincenty.c:23
subroutine watlev
Definition: watlev.f:2
Definition: RsViirs.h:71