Changeset 3572 for palm/trunk/SOURCE/surface_output_mod.f90
- Timestamp:
- Nov 28, 2018 11:40:28 AM (6 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
palm/trunk/SOURCE/surface_output_mod.f90
r3494 r3572 25 25 ! ----------------- 26 26 ! $Id$ 27 ! Added short- and longwave radiation flux arrays (e.g. diffuse, direct, 28 ! reflected, resedual) for all surfaces (M. Salim) 29 ! 30 ! 3494 2018-11-06 14:51:27Z suehring 27 31 ! Bugfix in gathering surface data from different types and orientation. 28 32 ! Output of total number of surfaces and vertices added. … … 2003 2007 surf_lsm_v(3)%r_s, & 2004 2008 surf_usm_v(3)%r_s ) 2009 ELSE 2010 ! 2011 !-- Output of averaged data 2012 surfaces%var_out(:) = surfaces%var_av(:,n_out) / & 2013 REAL( average_count_surf, KIND=wp ) 2014 surfaces%var_av(:,n_out) = 0.0_wp 2015 2016 ENDIF 2017 2018 CASE ( 'rad_sw_dir' ) 2019 ! 2020 !-- Output of instantaneous data 2021 IF ( av == 0 ) THEN 2022 CALL surface_output_collect( surf_def_h(0)%rad_sw_dir, & 2023 surf_def_h(1)%rad_sw_dir, & 2024 surf_lsm_h%rad_sw_dir, & 2025 surf_usm_h%rad_sw_dir, & 2026 surf_def_v(0)%rad_sw_dir, & 2027 surf_lsm_v(0)%rad_sw_dir, & 2028 surf_usm_v(0)%rad_sw_dir, & 2029 surf_def_v(1)%rad_sw_dir, & 2030 surf_lsm_v(1)%rad_sw_dir, & 2031 surf_usm_v(1)%rad_sw_dir, & 2032 surf_def_v(2)%rad_sw_dir, & 2033 surf_lsm_v(2)%rad_sw_dir, & 2034 surf_usm_v(2)%rad_sw_dir, & 2035 surf_def_v(3)%rad_sw_dir, & 2036 surf_lsm_v(3)%rad_sw_dir, & 2037 surf_usm_v(3)%rad_sw_dir ) 2038 ELSE 2039 ! 2040 !-- Output of averaged data 2041 surfaces%var_out(:) = surfaces%var_av(:,n_out) / & 2042 REAL( average_count_surf, KIND=wp ) 2043 surfaces%var_av(:,n_out) = 0.0_wp 2044 2045 ENDIF 2046 2047 CASE ( 'rad_sw_dif' ) 2048 ! 2049 !-- Output of instantaneous data 2050 IF ( av == 0 ) THEN 2051 CALL surface_output_collect( surf_def_h(0)%rad_sw_dif, & 2052 surf_def_h(1)%rad_sw_dif, & 2053 surf_lsm_h%rad_sw_dif, & 2054 surf_usm_h%rad_sw_dif, & 2055 surf_def_v(0)%rad_sw_dif, & 2056 surf_lsm_v(0)%rad_sw_dif, & 2057 surf_usm_v(0)%rad_sw_dif, & 2058 surf_def_v(1)%rad_sw_dif, & 2059 surf_lsm_v(1)%rad_sw_dif, & 2060 surf_usm_v(1)%rad_sw_dif, & 2061 surf_def_v(2)%rad_sw_dif, & 2062 surf_lsm_v(2)%rad_sw_dif, & 2063 surf_usm_v(2)%rad_sw_dif, & 2064 surf_def_v(3)%rad_sw_dif, & 2065 surf_lsm_v(3)%rad_sw_dif, & 2066 surf_usm_v(3)%rad_sw_dif ) 2067 ELSE 2068 ! 2069 !-- Output of averaged data 2070 surfaces%var_out(:) = surfaces%var_av(:,n_out) / & 2071 REAL( average_count_surf, KIND=wp ) 2072 surfaces%var_av(:,n_out) = 0.0_wp 2073 2074 ENDIF 2075 2076 CASE ( 'rad_sw_ref' ) 2077 ! 2078 !-- Output of instantaneous data 2079 IF ( av == 0 ) THEN 2080 CALL surface_output_collect( surf_def_h(0)%rad_sw_ref, & 2081 surf_def_h(1)%rad_sw_ref, & 2082 surf_lsm_h%rad_sw_ref, & 2083 surf_usm_h%rad_sw_ref, & 2084 surf_def_v(0)%rad_sw_ref, & 2085 surf_lsm_v(0)%rad_sw_ref, & 2086 surf_usm_v(0)%rad_sw_ref, & 2087 surf_def_v(1)%rad_sw_ref, & 2088 surf_lsm_v(1)%rad_sw_ref, & 2089 surf_usm_v(1)%rad_sw_ref, & 2090 surf_def_v(2)%rad_sw_ref, & 2091 surf_lsm_v(2)%rad_sw_ref, & 2092 surf_usm_v(2)%rad_sw_ref, & 2093 surf_def_v(3)%rad_sw_ref, & 2094 surf_lsm_v(3)%rad_sw_ref, & 2095 surf_usm_v(3)%rad_sw_ref ) 2096 ELSE 2097 ! 2098 !-- Output of averaged data 2099 surfaces%var_out(:) = surfaces%var_av(:,n_out) / & 2100 REAL( average_count_surf, KIND=wp ) 2101 surfaces%var_av(:,n_out) = 0.0_wp 2102 2103 ENDIF 2104 2105 CASE ( 'rad_sw_res' ) 2106 ! 2107 !-- Output of instantaneous data 2108 IF ( av == 0 ) THEN 2109 CALL surface_output_collect( surf_def_h(0)%rad_sw_res, & 2110 surf_def_h(1)%rad_sw_res, & 2111 surf_lsm_h%rad_sw_res, & 2112 surf_usm_h%rad_sw_res, & 2113 surf_def_v(0)%rad_sw_res, & 2114 surf_lsm_v(0)%rad_sw_res, & 2115 surf_usm_v(0)%rad_sw_res, & 2116 surf_def_v(1)%rad_sw_res, & 2117 surf_lsm_v(1)%rad_sw_res, & 2118 surf_usm_v(1)%rad_sw_res, & 2119 surf_def_v(2)%rad_sw_res, & 2120 surf_lsm_v(2)%rad_sw_res, & 2121 surf_usm_v(2)%rad_sw_res, & 2122 surf_def_v(3)%rad_sw_res, & 2123 surf_lsm_v(3)%rad_sw_res, & 2124 surf_usm_v(3)%rad_sw_res ) 2125 ELSE 2126 ! 2127 !-- Output of averaged data 2128 surfaces%var_out(:) = surfaces%var_av(:,n_out) / & 2129 REAL( average_count_surf, KIND=wp ) 2130 surfaces%var_av(:,n_out) = 0.0_wp 2131 2132 ENDIF 2133 2134 CASE ( 'rad_lw_dif' ) 2135 ! 2136 !-- Output of instantaneous data 2137 IF ( av == 0 ) THEN 2138 CALL surface_output_collect( surf_def_h(0)%rad_lw_dif, & 2139 surf_def_h(1)%rad_lw_dif, & 2140 surf_lsm_h%rad_lw_dif, & 2141 surf_usm_h%rad_lw_dif, & 2142 surf_def_v(0)%rad_lw_dif, & 2143 surf_lsm_v(0)%rad_lw_dif, & 2144 surf_usm_v(0)%rad_lw_dif, & 2145 surf_def_v(1)%rad_lw_dif, & 2146 surf_lsm_v(1)%rad_lw_dif, & 2147 surf_usm_v(1)%rad_lw_dif, & 2148 surf_def_v(2)%rad_lw_dif, & 2149 surf_lsm_v(2)%rad_lw_dif, & 2150 surf_usm_v(2)%rad_lw_dif, & 2151 surf_def_v(3)%rad_lw_dif, & 2152 surf_lsm_v(3)%rad_lw_dif, & 2153 surf_usm_v(3)%rad_lw_dif ) 2154 ELSE 2155 ! 2156 !-- Output of averaged data 2157 surfaces%var_out(:) = surfaces%var_av(:,n_out) / & 2158 REAL( average_count_surf, KIND=wp ) 2159 surfaces%var_av(:,n_out) = 0.0_wp 2160 2161 ENDIF 2162 2163 CASE ( 'rad_lw_ref' ) 2164 ! 2165 !-- Output of instantaneous data 2166 IF ( av == 0 ) THEN 2167 CALL surface_output_collect( surf_def_h(0)%rad_lw_ref, & 2168 surf_def_h(1)%rad_lw_ref, & 2169 surf_lsm_h%rad_lw_ref, & 2170 surf_usm_h%rad_lw_ref, & 2171 surf_def_v(0)%rad_lw_ref, & 2172 surf_lsm_v(0)%rad_lw_ref, & 2173 surf_usm_v(0)%rad_lw_ref, & 2174 surf_def_v(1)%rad_lw_ref, & 2175 surf_lsm_v(1)%rad_lw_ref, & 2176 surf_usm_v(1)%rad_lw_ref, & 2177 surf_def_v(2)%rad_lw_ref, & 2178 surf_lsm_v(2)%rad_lw_ref, & 2179 surf_usm_v(2)%rad_lw_ref, & 2180 surf_def_v(3)%rad_lw_ref, & 2181 surf_lsm_v(3)%rad_lw_ref, & 2182 surf_usm_v(3)%rad_lw_ref ) 2183 ELSE 2184 ! 2185 !-- Output of averaged data 2186 surfaces%var_out(:) = surfaces%var_av(:,n_out) / & 2187 REAL( average_count_surf, KIND=wp ) 2188 surfaces%var_av(:,n_out) = 0.0_wp 2189 2190 ENDIF 2191 2192 CASE ( 'rad_lw_res' ) 2193 ! 2194 !-- Output of instantaneous data 2195 IF ( av == 0 ) THEN 2196 CALL surface_output_collect( surf_def_h(0)%rad_lw_res, & 2197 surf_def_h(1)%rad_lw_res, & 2198 surf_lsm_h%rad_lw_res, & 2199 surf_usm_h%rad_lw_res, & 2200 surf_def_v(0)%rad_lw_res, & 2201 surf_lsm_v(0)%rad_lw_res, & 2202 surf_usm_v(0)%rad_lw_res, & 2203 surf_def_v(1)%rad_lw_res, & 2204 surf_lsm_v(1)%rad_lw_res, & 2205 surf_usm_v(1)%rad_lw_res, & 2206 surf_def_v(2)%rad_lw_res, & 2207 surf_lsm_v(2)%rad_lw_res, & 2208 surf_usm_v(2)%rad_lw_res, & 2209 surf_def_v(3)%rad_lw_res, & 2210 surf_lsm_v(3)%rad_lw_res, & 2211 surf_usm_v(3)%rad_lw_res ) 2005 2212 ELSE 2006 2213 ! … … 2753 2960 surf_usm_v(3)%r_s, n_out ) 2754 2961 2962 2963 CASE ( 'rad_sw_dir' ) 2964 CALL surface_output_sum_up( surf_def_h(0)%rad_sw_dir, & 2965 surf_def_h(1)%rad_sw_dir, & 2966 surf_lsm_h%rad_sw_dir, & 2967 surf_usm_h%rad_sw_dir, & 2968 surf_def_v(0)%rad_sw_dir, & 2969 surf_lsm_v(0)%rad_sw_dir, & 2970 surf_usm_v(0)%rad_sw_dir, & 2971 surf_def_v(1)%rad_sw_dir, & 2972 surf_lsm_v(1)%rad_sw_dir, & 2973 surf_usm_v(1)%rad_sw_dir, & 2974 surf_def_v(2)%rad_sw_dir, & 2975 surf_lsm_v(2)%rad_sw_dir, & 2976 surf_usm_v(2)%rad_sw_dir, & 2977 surf_def_v(3)%rad_sw_dir, & 2978 surf_lsm_v(3)%rad_sw_dir, & 2979 surf_usm_v(3)%rad_sw_dir, n_out ) 2980 CASE ( 'rad_sw_dif' ) 2981 CALL surface_output_sum_up( surf_def_h(0)%rad_sw_dif, & 2982 surf_def_h(1)%rad_sw_dif, & 2983 surf_lsm_h%rad_sw_dif, & 2984 surf_usm_h%rad_sw_dif, & 2985 surf_def_v(0)%rad_sw_dif, & 2986 surf_lsm_v(0)%rad_sw_dif, & 2987 surf_usm_v(0)%rad_sw_dif, & 2988 surf_def_v(1)%rad_sw_dif, & 2989 surf_lsm_v(1)%rad_sw_dif, & 2990 surf_usm_v(1)%rad_sw_dif, & 2991 surf_def_v(2)%rad_sw_dif, & 2992 surf_lsm_v(2)%rad_sw_dif, & 2993 surf_usm_v(2)%rad_sw_dif, & 2994 surf_def_v(3)%rad_sw_dif, & 2995 surf_lsm_v(3)%rad_sw_dif, & 2996 surf_usm_v(3)%rad_sw_dif, n_out ) 2997 2998 CASE ( 'rad_sw_ref' ) 2999 CALL surface_output_sum_up( surf_def_h(0)%rad_sw_ref, & 3000 surf_def_h(1)%rad_sw_ref, & 3001 surf_lsm_h%rad_sw_ref, & 3002 surf_usm_h%rad_sw_ref, & 3003 surf_def_v(0)%rad_sw_ref, & 3004 surf_lsm_v(0)%rad_sw_ref, & 3005 surf_usm_v(0)%rad_sw_ref, & 3006 surf_def_v(1)%rad_sw_ref, & 3007 surf_lsm_v(1)%rad_sw_ref, & 3008 surf_usm_v(1)%rad_sw_ref, & 3009 surf_def_v(2)%rad_sw_ref, & 3010 surf_lsm_v(2)%rad_sw_ref, & 3011 surf_usm_v(2)%rad_sw_ref, & 3012 surf_def_v(3)%rad_sw_ref, & 3013 surf_lsm_v(3)%rad_sw_ref, & 3014 surf_usm_v(3)%rad_sw_ref, n_out ) 3015 3016 CASE ( 'rad_sw_res' ) 3017 CALL surface_output_sum_up( surf_def_h(0)%rad_sw_res, & 3018 surf_def_h(1)%rad_sw_res, & 3019 surf_lsm_h%rad_sw_res, & 3020 surf_usm_h%rad_sw_res, & 3021 surf_def_v(0)%rad_sw_res, & 3022 surf_lsm_v(0)%rad_sw_res, & 3023 surf_usm_v(0)%rad_sw_res, & 3024 surf_def_v(1)%rad_sw_res, & 3025 surf_lsm_v(1)%rad_sw_res, & 3026 surf_usm_v(1)%rad_sw_res, & 3027 surf_def_v(2)%rad_sw_res, & 3028 surf_lsm_v(2)%rad_sw_res, & 3029 surf_usm_v(2)%rad_sw_res, & 3030 surf_def_v(3)%rad_sw_res, & 3031 surf_lsm_v(3)%rad_sw_res, & 3032 surf_usm_v(3)%rad_sw_res, n_out ) 3033 3034 CASE ( 'rad_lw_dif' ) 3035 CALL surface_output_sum_up( surf_def_h(0)%rad_lw_dif, & 3036 surf_def_h(1)%rad_lw_dif, & 3037 surf_lsm_h%rad_lw_dif, & 3038 surf_usm_h%rad_lw_dif, & 3039 surf_def_v(0)%rad_lw_dif, & 3040 surf_lsm_v(0)%rad_lw_dif, & 3041 surf_usm_v(0)%rad_lw_dif, & 3042 surf_def_v(1)%rad_lw_dif, & 3043 surf_lsm_v(1)%rad_lw_dif, & 3044 surf_usm_v(1)%rad_lw_dif, & 3045 surf_def_v(2)%rad_lw_dif, & 3046 surf_lsm_v(2)%rad_lw_dif, & 3047 surf_usm_v(2)%rad_lw_dif, & 3048 surf_def_v(3)%rad_lw_dif, & 3049 surf_lsm_v(3)%rad_lw_dif, & 3050 surf_usm_v(3)%rad_lw_dif, n_out ) 3051 3052 CASE ( 'rad_lw_ref' ) 3053 CALL surface_output_sum_up( surf_def_h(0)%rad_lw_ref, & 3054 surf_def_h(1)%rad_lw_ref, & 3055 surf_lsm_h%rad_lw_ref, & 3056 surf_usm_h%rad_lw_ref, & 3057 surf_def_v(0)%rad_lw_ref, & 3058 surf_lsm_v(0)%rad_lw_ref, & 3059 surf_usm_v(0)%rad_lw_ref, & 3060 surf_def_v(1)%rad_lw_ref, & 3061 surf_lsm_v(1)%rad_lw_ref, & 3062 surf_usm_v(1)%rad_lw_ref, & 3063 surf_def_v(2)%rad_lw_ref, & 3064 surf_lsm_v(2)%rad_lw_ref, & 3065 surf_usm_v(2)%rad_lw_ref, & 3066 surf_def_v(3)%rad_lw_ref, & 3067 surf_lsm_v(3)%rad_lw_ref, & 3068 surf_usm_v(3)%rad_lw_ref, n_out ) 3069 3070 CASE ( 'rad_lw_res' ) 3071 CALL surface_output_sum_up( surf_def_h(0)%rad_lw_res, & 3072 surf_def_h(1)%rad_lw_res, & 3073 surf_lsm_h%rad_lw_res, & 3074 surf_usm_h%rad_lw_res, & 3075 surf_def_v(0)%rad_lw_res, & 3076 surf_lsm_v(0)%rad_lw_res, & 3077 surf_usm_v(0)%rad_lw_res, & 3078 surf_def_v(1)%rad_lw_res, & 3079 surf_lsm_v(1)%rad_lw_res, & 3080 surf_usm_v(1)%rad_lw_res, & 3081 surf_def_v(2)%rad_lw_res, & 3082 surf_lsm_v(2)%rad_lw_res, & 3083 surf_usm_v(2)%rad_lw_res, & 3084 surf_def_v(3)%rad_lw_res, & 3085 surf_lsm_v(3)%rad_lw_res, & 3086 surf_usm_v(3)%rad_lw_res, n_out ) 3087 2755 3088 END SELECT 2756 3089 ENDDO … … 3311 3644 CASE ( 'rad_net' ) 3312 3645 3313 CASE ( 'rad_lw_in', 'rad_lw_out', 'rad_sw_in', 'rad_sw_out' ) 3646 CASE ( 'rad_lw_in', 'rad_lw_out', 'rad_lw_dif', 'rad_lw_ref', & 3647 'rad_lw_res' ) 3648 3649 CASE ( 'rad_sw_in', 'rad_sw_out', 'rad_sw_dif', 'rad_sw_ref', & 3650 'rad_sw_res', 'rad_sw_dir' ) 3314 3651 3315 3652 CASE ( 'ghf' )
Note: See TracChangeset
for help on using the changeset viewer.