Changeset 792 for codes/icosagcm
- Timestamp:
- 12/10/18 12:48:58 (5 years ago)
- Location:
- codes/icosagcm/devel
- Files:
-
- 1 added
- 5 edited
Legend:
- Unmodified
- Added
- Removed
-
codes/icosagcm/devel/Python/src/kernels_transport.jin
r784 r792 312 312 313 313 KERNEL(scalar_laplacian) 314 315 314 FORALL_CELLS_EXT() 316 315 ON_EDGES … … 330 329 331 330 END_BLOCK 331 332 KERNEL(curl_laplacian) 333 FORALL_CELLS_EXT() 334 ON_DUAL 335 etav = 0.d0 336 FORALL_EDGES 337 etav = etav + SIGN*u(EDGE) 338 END_BLOCK 339 qv(DUAL_CELL) = etav/AV 340 END_BLOCK 341 END_BLOCK 342 343 FORALL_CELLS_EXT() 344 ON_EDGES 345 curlcurl(EDGE) = SIGN*(qv(VERTEX1)-qv(VERTEX2))*(1./LE_DE) 346 END_BLOCK 347 END_BLOCK 348 349 END_BLOCK -
codes/icosagcm/devel/Python/src/unstructured.pyx
r784 r792 78 78 ['dynamico_caldyn_unstructured', c_num, c_void_p,20], 79 79 ['dynamico_scalar_laplacian', c_void_p,2], 80 ['dynamico_curl_laplacian', c_void_p,2], 80 81 ['dynamico_partition_graph', c_int,2, c_void_p,3, c_int, c_void_p], 81 82 ['dynamico_init_transfer', c_int, c_int,2,c_void_p,3, c_int,2,c_void_p,3], -
codes/icosagcm/devel/Python/test/py/Baroclinic_3D_ullrich.py
r791 r792 201 201 caldyn_step.next() 202 202 davies.relax(llm, caldyn_step, flow0) 203 m,S = caldyn_step.mass, caldyn_step.theta_rhodz203 m,S,u = caldyn_step.mass, caldyn_step.theta_rhodz, caldyn_step.u 204 204 s = S/m 205 laps =mesh.field_mass()206 bilaps = mesh.field_mass()205 laps, bilaps = mesh.field_mass(), mesh.field_mass() 206 lapu, bilapu = mesh.field_u(), mesh.field_u() 207 207 unst.ker.dynamico_scalar_laplacian(s,laps) 208 208 unst.ker.dynamico_scalar_laplacian(laps,bilaps) 209 unst.ker.dynamico_curl_laplacian(u,lapu) 210 unst.ker.dynamico_curl_laplacian(lapu,bilapu) 209 211 caldyn_step.theta_rhodz[:] = S - dt*kappa*bilaps*m # Euler step 212 caldyn_step.u[:] = u - dt*kappa*bilapu # Euler step 213 210 214 return (caldyn_step.mass.copy(), caldyn_step.theta_rhodz.copy(), caldyn_step.u.copy(), 211 215 caldyn_step.geopot.copy(), caldyn_step.W.copy()) … … 230 234 v = mesh.field_mass() # specific volume (diagnosed) 231 235 232 for i in range(Nslice ):236 for i in range(Nslice+1): 233 237 context.update_calendar(i+1) 234 238 -
codes/icosagcm/devel/src/unstructured/caldyn_unstructured.F90
r784 r792 247 247 END SUBROUTINE compute_scalar_laplacian 248 248 249 SUBROUTINE compute_curl_laplacian(u,qv,curlcurl) 250 FIELD_Z :: qv ! BUF 251 FIELD_U :: u, curlcurl ! IN,OUT 252 DECLARE_INDICES 253 DECLARE_EDGES 254 DECLARE_VERTICES 255 NUM :: etav 256 START_TRACE(id_scalar_laplacian, 0,0,1) 257 #include "../kernels_unst/curl_laplacian.k90" 258 STOP_TRACE 259 END SUBROUTINE compute_curl_laplacian 260 249 261 END MODULE caldyn_unstructured_mod -
codes/icosagcm/devel/src/unstructured/timestep_unstructured.F90
r784 r792 29 29 !$OMP END PARALLEL 30 30 END SUBROUTINE scalar_laplacian 31 32 SUBROUTINE curl_laplacian(u,lapu) BINDC(curl_laplacian) 33 FIELD_U :: u,lapu ! IN, OUT 34 FIELD_Z :: qv ! BUF 35 !$OMP PARALLEL NUM_THREADS(nb_threads) 36 CALL update_halo(transfer_edge, u) 37 CALL compute_curl_laplacian(u,qv,lapu) 38 !$OMP END PARALLEL 39 END SUBROUTINE curl_laplacian 31 40 32 41 !
Note: See TracChangeset
for help on using the changeset viewer.