Changeset 4791 for palm/trunk
- Timestamp:
- Nov 23, 2020 11:44:26 AM (4 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
palm/trunk/SOURCE/init_3d_model.f90
r4783 r4791 24 24 ! ----------------- 25 25 ! $Id$ 26 ! Add possibility to initialize surface flux of passive scalar via static driver 27 ! 28 ! 4783 2020-11-13 13:58:45Z raasch 26 29 ! bugfix for reading restart data with MPI-I/O (does not work with blockwise I/O) 27 30 ! … … 1604 1607 ENDIF 1605 1608 ! 1606 !-- Input surface sensible heat flux. 1607 IF ( check_existence( vars_pids, 'qsws' ) ) THEN 1608 ! 1609 !-- Read _FillValue attribute 1610 CALL get_attribute( pids_id, char_fill, tmp_2d%fill, & 1611 .FALSE., 'qsws' ) 1612 ! 1613 !-- Read variable 1614 CALL get_variable( pids_id, 'qsws', tmp_2d%var, & 1615 nxl, nxr, nys, nyn ) 1616 ! 1617 !-- Initialize latent heat flux. Note, qsws will be only initialized at default-type surfaces. 1618 !-- At natural or urban qsws is implicitly initialized by the respective parameter lists. 1619 !-- Initialize horizontal surface elements. 1620 CALL init_single_surface_properties( surf_def_h(0)%qsws, tmp_2d%var, surf_def_h(0)%ns, & 1621 tmp_2d%fill, surf_def_h(0)%i, surf_def_h(0)%j ) 1622 ! 1623 !-- Initialize latent heat flux also at vertical surface elements. 1624 !-- Note, the actual 2D input arrays are only defined on the subdomain. Therefore, pass the 1625 !-- index arrays with their respective offset values. 1626 DO l = 0, 3 1627 CALL init_single_surface_properties( surf_def_v(l)%qsws, tmp_2d%var, surf_def_v(l)%ns,& 1628 tmp_2d%fill, surf_def_v(l)%i+surf_def_v(l)%ioff, & 1629 surf_def_v(l)%j+surf_def_v(l)%joff ) 1630 ENDDO 1631 1609 !-- Input surface latent heat flux. 1610 IF ( humidity ) THEN 1611 IF ( check_existence( vars_pids, 'qsws' ) ) THEN 1612 ! 1613 !-- Read _FillValue attribute 1614 CALL get_attribute( pids_id, char_fill, tmp_2d%fill, .FALSE., 'qsws' ) 1615 ! 1616 !-- Read variable 1617 CALL get_variable( pids_id, 'qsws', tmp_2d%var, nxl, nxr, nys, nyn ) 1618 ! 1619 !-- Initialize latent heat flux. Note, qsws will be only initialized at default-type surfaces. 1620 !-- At natural or urban qsws is implicitly initialized by the respective parameter lists. 1621 !-- Initialize horizontal surface elements. 1622 CALL init_single_surface_properties( surf_def_h(0)%qsws, tmp_2d%var, surf_def_h(0)%ns,& 1623 tmp_2d%fill, surf_def_h(0)%i, surf_def_h(0)%j ) 1624 ! 1625 !-- Initialize latent heat flux also at vertical surface elements. 1626 !-- Note, the actual 2D input arrays are only defined on the subdomain. Therefore, pass the 1627 !-- index arrays with their respective offset values. 1628 DO l = 0, 3 1629 CALL init_single_surface_properties( surf_def_v(l)%qsws, tmp_2d%var, & 1630 surf_def_v(l)%ns, tmp_2d%fill, & 1631 surf_def_v(l)%i+surf_def_v(l)%ioff, & 1632 surf_def_v(l)%j+surf_def_v(l)%joff ) 1633 ENDDO 1634 1635 ENDIF 1636 ENDIF 1637 ! 1638 !-- Input passive scalar flux. 1639 IF ( passive_scalar ) THEN 1640 IF ( check_existence( vars_pids, 'ssws' ) ) THEN 1641 ! 1642 !-- Read _FillValue attribute 1643 CALL get_attribute( pids_id, char_fill, tmp_2d%fill, .FALSE., 'ssws' ) 1644 ! 1645 !-- Read variable 1646 CALL get_variable( pids_id, 'ssws', tmp_2d%var, nxl, nxr, nys, nyn ) 1647 ! 1648 !-- Initialize passive scalar flux. Initialize horizontal surface elements. 1649 CALL init_single_surface_properties( surf_def_h(0)%ssws, tmp_2d%var, surf_def_h(0)%ns,& 1650 tmp_2d%fill, surf_def_h(0)%i, surf_def_h(0)%j ) 1651 1652 DO l = 0, 3 1653 CALL init_single_surface_properties( surf_def_v(l)%ssws, tmp_2d%var, & 1654 surf_def_v(l)%ns, tmp_2d%fill, & 1655 surf_def_v(l)%i+surf_def_v(l)%ioff, & 1656 surf_def_v(l)%j+surf_def_v(l)%joff ) 1657 ENDDO 1658 1659 ENDIF 1632 1660 ENDIF 1633 1661 !
Note: See TracChangeset
for help on using the changeset viewer.