subroutine cond include 'com_main.fc' vrAD=PI/180. PI2=2.*PI c##################################### calculation of the ion drag c------------------------------------- Alex Pogoreltsev November 2015 rtime=float(ncom)/384. time=(rtime-INT(rtime))*24.+12. if(time.GE.24.) time=time-24. c------------ without diurnal (and longitudinal) variability c until ncom < nphi c---------------------------------------------------------------------- nfor=max0(ncom-nphi,0) xsec = 3600./float(ntime) ! seconds per step tdfor = float(nfor)*xsec/30./86400. c--------------------- efficiency of the generation of tides after nphi t_tides= 1.- exp(-tdfor) DO 110 k=1,19 do 111 j=1,nb jplus1=j+1 do 112 i=1,igit rlon=float(i-1)*5.625 c####################################################################### c------------------------------- SIG2 ---------------------------------- drag(i,j,k+37,3)=drag0(i,j,k+37,3) * +t_tides*( * As2m1w24(j,k)*cos(PI2*time/24.+(rlon-Fs2m1w24(j,k))*VRAD) * +As2m1w12(j,k)*cos(PI2*time/12.+(rlon-Fs2m1w12(j,k))*VRAD) * +As2m1w08(j,k)*cos(PI2*time/ 8.+(rlon-Fs2m1w08(j,k))*VRAD) * +As2m1w06(j,k)*cos(PI2*time/ 6.+(rlon-Fs2m1w06(j,k))*VRAD) * +As2m1spw(j,k)*cos( (rlon-Fs2m1SPW(j,k))*VRAD) c--------------------------------------------------------------------- * +As2m1e24(j,k)*cos(-PI2*time/24.+(rlon-Fs2m1e24(j,k))*VRAD) * +As2m1e12(j,k)*cos(-PI2*time/12.+(rlon-Fs2m1e12(j,k))*VRAD) * +As2m1e08(j,k)*cos(-PI2*time/ 8.+(rlon-Fs2m1e08(j,k))*VRAD) * +As2m1e06(j,k)*cos(-PI2*time/ 6.+(rlon-Fs2m1e06(j,k))*VRAD) c--------------------------------------------------------------------- * +As2m2w24(j,k)*cos(PI2*time/24.+2.*(rlon-Fs2m2w24(j,k))*VRAD) * +As2m2w12(j,k)*cos(PI2*time/12.+2.*(rlon-Fs2m2w12(j,k))*VRAD) * +As2m2w08(j,k)*cos(PI2*time/ 8.+2.*(rlon-Fs2m2w08(j,k))*VRAD) * +As2m2w06(j,k)*cos(PI2*time/ 6.+2.*(rlon-Fs2m2w06(j,k))*VRAD) * +As2m2spw(j,k)*cos( 2.*(rlon-Fs2m2spw(j,k))*VRAD) c--------------------------------------------------------------------- * +As2m2e24(j,k)*cos(-PI2*time/24.+2.*(rlon-Fs2m2e24(j,k))*VRAD) * +As2m2e12(j,k)*cos(-PI2*time/12.+2.*(rlon-Fs2m2e12(j,k))*VRAD) * +As2m2e08(j,k)*cos(-PI2*time/ 8.+2.*(rlon-Fs2m2e08(j,k))*VRAD) * +As2m2e06(j,k)*cos(-PI2*time/ 6.+2.*(rlon-Fs2m2e06(j,k))*VRAD)) c-------------------------------------------------------------------- c--------------------------------------------------------------------- c * +s2_m3(1,j,k,1)*cos(PI2*time/24.+3.*(rlon-s2_m3(1,j,k,3))*VRAD) c * +s2_m3(2,j,k,1)*cos(PI2*time/12.+3.*(rlon-s2_m3(2,j,k,3))*VRAD) c * +s2_m3(3,j,k,1)*cos(PI2*time/ 8.+3.*(rlon-s2_m3(3,j,k,3))*VRAD) c * +s2_m3(4,j,k,1)*cos(PI2*time/ 6.+3.*(rlon-s2_m3(4,j,k,3))*VRAD) c * +s2_m3(5,j,k,1)*cos( 3.*(rlon-s2_m3(5,j,k,3))*VRAD) c--------------------------------------------------------------------- c * +s2_m3(1,j,k,2)*cos(-PI2*time/24.+3.*(rlon-s2_m3(1,j,k,4))*VRAD) c * +s2_m3(2,j,k,2)*cos(-PI2*time/12.+3.*(rlon-s2_m3(2,j,k,4))*VRAD) c * +s2_m3(3,j,k,2)*cos(-PI2*time/ 8.+3.*(rlon-s2_m3(3,j,k,4))*VRAD) c * +s2_m3(4,j,k,2)*cos(-PI2*time/ 6.+3.*(rlon-s2_m3(4,j,k,4))*VRAD) c--------------------------------------------------------------------- c * +s2_m4(1,j,k,1)*cos(PI2*time/24.+4.*(rlon-s2_m4(1,j,k,3))*VRAD) c * +s2_m4(2,j,k,1)*cos(PI2*time/12.+4.*(rlon-s2_m4(2,j,k,3))*VRAD) c * +s2_m4(3,j,k,1)*cos(PI2*time/ 8.+4.*(rlon-s2_m4(3,j,k,3))*VRAD) c * +s2_m4(4,j,k,1)*cos(PI2*time/ 6.+4.*(rlon-s2_m4(4,j,k,3))*VRAD) c * +s2_m4(5,j,k,1)*cos( 4.*(rlon-s2_m4(5,j,k,3))*VRAD) c--------------------------------------------------------------------- c *+s2_m4(1,j,k,2)*cos(-PI2*time/24.+4.*(rlon-s2_m4(1,j,k,4))*VRAD) c *+s2_m4(2,j,k,2)*cos(-PI2*time/12.+4.*(rlon-s2_m4(2,j,k,4))*VRAD) c *+s2_m4(3,j,k,2)*cos(-PI2*time/ 8.+4.*(rlon-s2_m4(3,j,k,4))*VRAD) c *+s2_m4(4,j,k,2)*cos(-PI2*time/ 6.+4.*(rlon-s2_m4(4,j,k,4))*VRAD) c * ) c--------------------------------------------------------------------- IF (j.LE.nb/2.and.drag(i,j,k+37,3).LT.0.) drag(i,j,k+37,3)=0. IF (j.GT.nb/2.and.drag(i,j,k+37,3).GT.0.) drag(i,j,k+37,3)=0. c###################################################################### c------------------------------- SIG1_U ------------------------------- drag(i,j,k+37,1)=drag0(i,j,k+37,1) * +t_tides*( * As1m1w24(j,k)*cos(PI2*time/24.+(rlon-Fs1m1w24(j,k))*VRAD) * +As1m1w12(j,k)*cos(PI2*time/12.+(rlon-Fs1m1w12(j,k))*VRAD) * +As1m1w08(j,k)*cos(PI2*time/ 8.+(rlon-Fs1m1w08(j,k))*VRAD) * +As1m1w06(j,k)*cos(PI2*time/ 6.+(rlon-Fs1m1w06(j,k))*VRAD) * +As1m1spw(j,k)*cos( (rlon-Fs1m1SPW(j,k))*VRAD) c--------------------------------------------------------------------- * +As1m1e24(j,k)*cos(-PI2*time/24.+(rlon-Fs1m1e24(j,k))*VRAD) * +As1m1e12(j,k)*cos(-PI2*time/12.+(rlon-Fs1m1e12(j,k))*VRAD) * +As1m1e08(j,k)*cos(-PI2*time/ 8.+(rlon-Fs1m1e08(j,k))*VRAD) * +As1m1e06(j,k)*cos(-PI2*time/ 6.+(rlon-Fs1m1e06(j,k))*VRAD) c--------------------------------------------------------------------- * +As1m2w24(j,k)*cos(PI2*time/24.+2.*(rlon-Fs1m2w24(j,k))*VRAD) * +As1m2w12(j,k)*cos(PI2*time/12.+2.*(rlon-Fs1m2w12(j,k))*VRAD) * +As1m2w08(j,k)*cos(PI2*time/ 8.+2.*(rlon-Fs1m2w08(j,k))*VRAD) * +As1m2w06(j,k)*cos(PI2*time/ 6.+2.*(rlon-Fs1m2w06(j,k))*VRAD) * +As1m2spw(j,k)*cos( 2.*(rlon-Fs1m2spw(j,k))*VRAD) c--------------------------------------------------------------------- * +As1m2e24(j,k)*cos(-PI2*time/24.+2.*(rlon-Fs1m2e24(j,k))*VRAD) * +As1m2e12(j,k)*cos(-PI2*time/12.+2.*(rlon-Fs1m2e12(j,k))*VRAD) * +As1m2e08(j,k)*cos(-PI2*time/ 8.+2.*(rlon-Fs1m2e08(j,k))*VRAD) * +As1m2e06(j,k)*cos(-PI2*time/ 6.+2.*(rlon-Fs1m2e06(j,k))*VRAD)) c-------------------------------------------------------------------- IF (drag(i,j,k+37,1).LT.5.e-7) drag(i,j,k+37,1)=5.E-7 IF (drag(i,j,k+37,1).LT.5.e-6.and.k.gt.44) drag(i,j,k+37,1)=5.E-6 c-------------------------------------------------------------------- drag(i,j,k+37,2)=drag(i,j,k+37,1)*4.*sinfi(jplus1)*sinfi(jplus1)/ * (1.+3.*sinfi(jplus1)*sinfi(jplus1)) 112 CONTINUE 111 CONTINUE 110 CONTINUE c######################################################## END ION DRAG RETURN END