Changeset 4064 for palm


Ignore:
Timestamp:
Jul 1, 2019 5:33:33 AM (5 years ago)
Author:
gronemeier
Message:

Moved call to radiation module out of intermediate time loop (time_integration, time_integration_spinup)

Location:
palm/trunk/SOURCE
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • palm/trunk/SOURCE/time_integration.f90

    r4048 r4064  
    2525! -----------------
    2626! $Id$
     27! Moved call to radiation module out of intermediate time loop
     28!
     29! 4048 2019-06-21 21:00:21Z knoop
    2730! Moved production_e_init call into turbulence_closure_mod
    2831!
     
    14821485          ENDIF
    14831486
    1484 !
    1485 !--       If required, calculate radiative fluxes and heating rates
    1486           IF ( radiation  .AND.  intermediate_timestep_count == intermediate_timestep_count_max    &
    1487                .AND. time_since_reference_point > skip_time_do_radiation )  THEN
    1488 
    1489                time_radiation = time_radiation + dt_3d
    1490 
    1491              IF ( time_radiation >= dt_radiation  .OR.  force_radiation_call )  THEN
    1492 
    1493                 CALL cpu_log( log_point(50), 'radiation', 'start' )
    1494 
    1495                 IF ( .NOT. force_radiation_call )  THEN
    1496                    time_radiation = time_radiation - dt_radiation
    1497                 ENDIF
    1498 
    1499 !
    1500 !--             Adjust the current time to the time step of the radiation model.
    1501 !--             Needed since radiation is pre-calculated and stored only on apparent
    1502 !--             solar positions
    1503                 time_since_reference_point_save = time_since_reference_point
    1504                 time_since_reference_point = REAL( FLOOR( time_since_reference_point /             &
    1505                                                           dt_radiation), wp ) * dt_radiation
    1506 
    1507                 CALL radiation_control
    1508 
    1509                 IF ( ( urban_surface  .OR.  land_surface )  .AND.  radiation_interactions )  THEN
    1510                    CALL cpu_log( log_point_s(46), 'radiation_interaction', 'start' )
    1511                    CALL radiation_interaction
    1512                    CALL cpu_log( log_point_s(46), 'radiation_interaction', 'stop' )
    1513                 ENDIF
    1514    
    1515 !
    1516 !--             Return the current time to its original value
    1517                 time_since_reference_point = time_since_reference_point_save
    1518 
    1519                 CALL cpu_log( log_point(50), 'radiation', 'stop' )
    1520 
    1521              ENDIF
    1522           ENDIF
    1523 
    15241487       ENDDO   ! Intermediate step loop
    15251488
     
    15441507
    15451508!
     1509!--    If required, calculate radiative fluxes and heating rates
     1510       IF ( radiation  .AND.  time_since_reference_point > skip_time_do_radiation )  THEN
     1511
     1512          time_radiation = time_radiation + dt_3d
     1513
     1514          IF ( time_radiation >= dt_radiation  .OR.  force_radiation_call )  THEN
     1515
     1516             CALL cpu_log( log_point(50), 'radiation', 'start' )
     1517
     1518             IF ( .NOT. force_radiation_call )  THEN
     1519                time_radiation = time_radiation - dt_radiation
     1520             ENDIF
     1521
     1522!
     1523!--          Adjust the current time to the time step of the radiation model.
     1524!--          Needed since radiation is pre-calculated and stored only on apparent
     1525!--          solar positions
     1526             time_since_reference_point_save = time_since_reference_point
     1527             time_since_reference_point = REAL( FLOOR( time_since_reference_point /             &
     1528                                                       dt_radiation ), wp ) * dt_radiation
     1529
     1530             CALL radiation_control
     1531
     1532             IF ( ( urban_surface  .OR.  land_surface )  .AND.  radiation_interactions )  THEN
     1533                CALL cpu_log( log_point_s(46), 'radiation_interaction', 'start' )
     1534                CALL radiation_interaction
     1535                CALL cpu_log( log_point_s(46), 'radiation_interaction', 'stop' )
     1536             ENDIF
     1537 
     1538!
     1539!--          Return the current time to its original value
     1540             time_since_reference_point = time_since_reference_point_save
     1541
     1542             CALL cpu_log( log_point(50), 'radiation', 'stop' )
     1543
     1544          ENDIF
     1545       ENDIF
     1546
     1547!
    15461548!--    If required, consider chemical emissions
    15471549       IF ( air_chemistry  .AND.  emissions_anthropogenic )  THEN
  • palm/trunk/SOURCE/time_integration_spinup.f90

    r4023 r4064  
    2525! -----------------
    2626! $Id$
     27! Moved call to radiation module out of intermediate time loop
     28!
     29! 4023 2019-06-12 13:20:01Z maronga
    2730! Time stamps are now negative in run control output
    2831!
     
    426429          ENDIF
    427430
    428 !
    429 !--       If required, calculate radiative fluxes and heating rates
    430           IF ( radiation .AND. intermediate_timestep_count                     &
    431                == intermediate_timestep_count_max )  THEN
    432 
    433                time_radiation = time_radiation + dt_3d
    434 
    435              IF ( time_radiation >= dt_3d .OR. force_radiation_call )          &
    436              THEN
    437 
    438                 IF ( .NOT. force_radiation_call )  THEN
    439                    time_radiation = time_radiation - dt_3d
    440                 ENDIF
    441 
    442                 CALL radiation_control
    443 
    444                 IF ( radiation_interactions )  THEN
    445                    CALL radiation_interaction
    446                 ENDIF
     431       ENDDO   ! Intermediate step loop
     432
     433!
     434!--    If required, calculate radiative fluxes and heating rates
     435       IF ( radiation )  THEN
     436
     437            time_radiation = time_radiation + dt_3d
     438
     439          IF ( time_radiation >= dt_3d .OR. force_radiation_call )  THEN
     440
     441             IF ( .NOT. force_radiation_call )  THEN
     442                time_radiation = time_radiation - dt_3d
    447443             ENDIF
    448           ENDIF
    449 
    450        ENDDO   ! Intermediate step loop
     444
     445             CALL radiation_control
     446
     447             IF ( radiation_interactions )  THEN
     448                CALL radiation_interaction
     449             ENDIF
     450          ENDIF
     451       ENDIF
    451452
    452453!
Note: See TracChangeset for help on using the changeset viewer.