Changeset 36 for codes/icosagcm/trunk
- Timestamp:
- 07/27/12 16:10:47 (12 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
codes/icosagcm/trunk/src/wind.f90
r21 r36 166 166 END SUBROUTINE compute_wind_from_lonlat_compound 167 167 168 168 SUBROUTINE compute_wind_perp_from_lonlat_compound(ulon, ulat, up) 169 USE icosa 170 171 IMPLICIT NONE 172 REAL(rstd) :: up(3*iim*jjm,llm) 173 REAL(rstd) :: ulon(3*iim*jjm,llm) 174 REAL(rstd) :: ulat(3*iim*jjm,llm) 175 REAL(rstd) :: u(3*iim*jjm,3,llm) 176 177 INTEGER :: i,j,ij,l 178 179 CALL compute_wind_from_lonlat_compound(ulon, ulat, u) 180 181 DO l=1,llm 182 DO j=jj_begin-1,jj_end+1 183 DO i=ii_begin-1,ii_end+1 184 ij=(j-1)*iim+i 185 up(ij+u_right,l)=sum(u(ij+u_right,:,l)*ep_e(ij+u_right,:)) 186 up(ij+u_lup,l)=sum(u(ij+u_lup,:,l)*ep_e(ij+u_lup,:)) 187 up(ij+u_ldown,l)=sum(u(ij+u_ldown,:,l)*ep_e(ij+u_ldown,:)) 188 ENDDO 189 ENDDO 190 ENDDO 191 192 END SUBROUTINE compute_wind_perp_from_lonlat_compound 193 169 194 SUBROUTINE compute_wind_centered_lonlat_compound(uc, ulon, ulat) 170 195 USE icosa 171 196 172 197 IMPLICIT NONE 173 REAL(rstd) :: uc( 3*iim*jjm,3,llm)174 REAL(rstd) :: ulon( 3*iim*jjm,3,llm)175 REAL(rstd) :: ulat( 3*iim*jjm,3,llm)198 REAL(rstd) :: uc(iim*jjm,3,llm) 199 REAL(rstd) :: ulon(iim*jjm,3,llm) 200 REAL(rstd) :: ulat(iim*jjm,3,llm) 176 201 177 202 INTEGER :: i,j,ij,l … … 182 207 DO i=ii_begin,ii_end 183 208 ij=(j-1)*iim+i 184 ulon(ij, :,l)=sum(uc(ij,:,l)*elon_i(ij,:))*elon_i(ij,:)185 ulat(ij, :,l)=sum(uc(ij,:,l)*elat_i(ij,:))**elat_i(ij,:)209 ulon(ij,l)=sum(uc(ij,:,l)*elon_i(ij,:)) 210 ulat(ij,l)=sum(uc(ij,:,l)*elat_i(ij,:)) 186 211 ENDDO 187 212 ENDDO
Note: See TracChangeset
for help on using the changeset viewer.