SURFEX  V8_0
Surfex V8_0 release
 All Classes Files Functions Variables
sw_daycycle.F90
Go to the documentation of this file.
1 !SFX_LIC Copyright 1994-2014 CNRS, Meteo-France and Universite Paul Sabatier
2 !SFX_LIC This is part of the SURFEX software governed by the CeCILL-C licence
3 !SFX_LIC version 1. See LICENSE, CeCILL-C_V1-en.txt and CeCILL-C_V1-fr.txt
4 !SFX_LIC for details. version 1.
5 ! #############################################################
6 SUBROUTINE sw_daycycle(KI, PZENITH, PTOT_SW)
7 ! #############################################################
8 !
9 USE yomhook ,ONLY : lhook, dr_hook
10 USE parkind1 ,ONLY : jprb
11 !
12 !http://www.apesimulator.it/help/models/solarradiation/Calculating_extra-terrestrial_solar_radiation.html
13 !
14 INTEGER, INTENT(IN) :: ki ! number of points
15 REAL, DIMENSION(KI), INTENT(IN) :: pzenith ! Zenith angle (rad)
16 REAL, DIMENSION(KI), INTENT(OUT) :: ptot_sw ! Extraterrestrial solar radiation (W m-2)
17 !
18 !RJ: missing declaration
19 INTEGER :: jj
20 !
21 REAL :: zc_sol ! Solar constant [W/m2]
22 REAL :: zd_corr ! Correction to acutal solar distance at any specific day of the year
23 INTEGER :: zjulian ! Julian day of the year
24 REAL(KIND=JPRB) :: zhook_handle
25 !
26 IF (lhook) CALL dr_hook('SW_DAYCYCLE',0,zhook_handle)
27 !
28 zjulian = 197
29 zc_sol = 4.921*1e6/3600 ! W m-2
30 zd_corr = 1 + 0.0334 * cos(0.01721 * zjulian - 0.0552)
31 !
32 DO jj=1,ki
33  ptot_sw(jj) = zc_sol * zd_corr * cos(pzenith(jj))
34 END DO
35 !
36 IF (lhook) CALL dr_hook('SW_DAYCYCLE',1,zhook_handle)
37 !
38 END SUBROUTINE sw_daycycle
39 
subroutine sw_daycycle(KI, PZENITH, PTOT_SW)
Definition: sw_daycycle.F90:6