Changeset 77 for branches/iLoveclim/SOURCES/diffusiv-polyn-0.6.f90
- Timestamp:
- 07/05/16 11:20:52 (8 years ago)
- Location:
- branches/iLoveclim
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/iLoveclim
-
branches/iLoveclim/SOURCES/diffusiv-polyn-0.6.f90
r4 r77 34 34 35 35 ! =============================================================== 36 36 !$ USE OMP_LIB 37 37 USE module3D_phy 38 38 … … 44 44 REAL :: INV_4DX ! inverse de dx pour eviter les divisions =1/(4*dx) 45 45 REAL :: INV_4DY ! inverse de dy pour eviter les divisions =1/(4*dy) 46 INTEGER :: ii47 integer :: ll48 46 49 47 if (itracebug.eq.1) call tracebug(' Entree dans routine diffusiv') … … 60 58 61 59 ! initialisation de la diffusion 60 !$OMP PARALLEL 61 !$OMP WORKSHARE 62 62 diffmx(:,:)=0. 63 63 diffmy(:,:)=0. 64 64 !$OMP END WORKSHARE 65 !$OMP END PARALLEL 65 66 66 67 ! calcul de SDX, SDY et de la pente au carre en mx et en my : … … 81 82 ! Calcul de la vitesse de glissement, qu'elle soit calculee par diagno ou par sliding 82 83 !------------------------------------------------------------------------------------ 83 ! 84 !$OMP PARALLEL 85 !$OMP WORKSHARE 84 86 where (flgzmx(:,:)) 85 87 ubx(:,:) = uxflgz(:,:) … … 93 95 uby(:,:) = ddby(:,:)* (-sdy(:,:)) 94 96 endwhere 95 96 97 !$OMP END WORKSHARE 98 !$OMP END PARALLEL 97 99 if (itracebug.eq.1) call tracebug(' diffusiv apres calcul glissement') 98 100 … … 101 103 ! Deformation SIA : Calcul de ddy et ddx pour chaque valeur de iglen 102 104 !------------------------------------------------------------------ 103 104 105 do iglen=n1poly,n2poly 105 106 glenexp=max(0.,(glen(iglen)-1.)/2.) 106 107 107 !$OMP PARALLEL 108 !$OMP DO 108 109 do j=1,ny 109 110 do i=1,nx 110 111 111 if (.not.flotmy(i,j)) then ! On calcule quand la deformation même pour les ice streams 112 112 ddy(i,j,iglen)=((slope2my(i,j)** & ! slope2my calcule en debut de routine 113 113 glenexp)*(rog)**glen(iglen)) & 114 114 *hmy(i,j)**(glen(iglen)+1) 115 116 117 115 endif 118 116 end do 119 117 end do 118 !$OMP END DO 119 !$OMP END PARALLEL 120 120 end do 121 122 121 123 122 124 do iglen=n1poly,n2poly 123 125 glenexp=max(0.,(glen(iglen)-1.)/2.) 124 125 126 !$OMP PARALLEL 127 !$OMP DO 126 128 do j=1,ny 127 129 do i=1,nx 128 129 130 if (.not.flotmx(i,j)) then ! bug y->x corrige le 5 avril 2008 ( 130 131 131 ddx(i,j,iglen)=((slope2mx(i,j)** & ! slope2mx calcule en debut de routine 132 132 glenexp)*(rog)**glen(iglen)) & … … 135 135 end do 136 136 end do 137 !$OMP END DO 138 !$OMP END PARALLEL 137 139 end do 138 140 141 139 142 ! vitesse due a la déformation----------------------------------------------- 140 141 143 !$OMP PARALLEL 144 !$OMP DO 142 145 ydef: do j=2,ny 143 146 do i=1,nx … … 166 169 end do 167 170 end do ydef 168 171 !$OMP END DO 172 173 !$OMP DO 169 174 xdef: do j=1,ny 170 175 do i=2,nx … … 194 199 end do 195 200 end do xdef 201 !$OMP END DO 196 202 197 203 if (itracebug.eq.1) call tracebug(' diffusiv avant limit') … … 201 207 202 208 ! la limitation selon x 209 !$OMP WORKSHARE 203 210 where(.not.flgzmx(:,:)) 204 211 uxbar(:,:)=min(uxbar(:,:),ultot) … … 211 218 uybar(:,:)=max(uybar(:,:),-ultot) 212 219 end where 220 !$OMP END WORKSHARE 213 221 214 222 ! cas particulier des sommets ou il ne reste plus de neige. 223 !$OMP DO 215 224 do j=2,ny-1 216 225 do i=2,nx-1 … … 223 232 end do 224 233 end do 225 234 !$OMP END DO 235 !$OMP END PARALLEL 226 236 if (itracebug.eq.1) call tracebug(' fin diffusiv ') 227 237
Note: See TracChangeset
for help on using the changeset viewer.