245 class(MethodCellPollockQuadType),
intent(inout) :: this
246 type(ParticleType),
pointer,
intent(inout) :: particle
247 class(SubcellRectType),
intent(inout) :: subcell
249 real(DP) :: dx, dy, dz, areax, areay, areaz
250 real(DP) :: dxprel, dyprel
251 integer(I4B) :: isc, npolyverts, m1, m2
252 real(DP) :: qextl1, qextl2, qintl1, qintl2
253 real(DP) :: factor, term
255 select type (cell => this%cell)
256 type is (cellrectquadtype)
257 factor = done / cell%defn%retfactor
258 factor = factor / cell%defn%porosity
259 npolyverts = cell%defn%npolyverts
261 isc = particle%idomain(3)
269 dxprel = particle%x / dx
270 dyprel = particle%y / dy
272 if (dyprel .ge. 5d-1)
then
273 if (dxprel .le. 5d-1)
then
279 if (dxprel .le. 5d-1)
then
286 subcell%isubcell = isc
287 particle%idomain(3) = isc
291 dz = cell%defn%top - &
296 qintl1 = cell%qintl(isc)
298 qintl2 = cell%qintl(isc + 1)
299 qextl1 = cell%qextl1(isc)
300 qextl2 = cell%qextl2(isc)
305 subcell%sinrot = dzero
306 subcell%cosrot = done
307 subcell%zOrigin = dzero
312 term = factor / areax
313 subcell%vx1 = qintl1 * term
314 subcell%vx2 = -qextl2 * term
315 term = factor / areay
316 subcell%vy1 = -qintl2 * term
317 subcell%vy2 = -qextl1 * term
320 subcell%yOrigin = dzero
321 term = factor / areax
322 subcell%vx1 = -qintl2 * term
323 subcell%vx2 = -qextl1 * term
324 term = factor / areay
325 subcell%vy1 = qextl2 * term
326 subcell%vy2 = -qintl1 * term
328 subcell%xOrigin = dzero
329 subcell%yOrigin = dzero
330 term = factor / areax
331 subcell%vx1 = qextl2 * term
332 subcell%vx2 = -qintl1 * term
333 term = factor / areay
334 subcell%vy1 = qextl1 * term
335 subcell%vy2 = qintl2 * term
337 subcell%xOrigin = dzero
339 term = factor / areax
340 subcell%vx1 = qextl1 * term
341 subcell%vx2 = qintl2 * term
342 term = factor / areay
343 subcell%vy1 = qintl1 * term
344 subcell%vy2 = -qextl2 * term
348 term = factor / areaz
349 subcell%vz1 = 2.5d-1 * cell%defn%faceflow(m1) * term
350 subcell%vz2 = -2.5d-1 * cell%defn%faceflow(m2) * term