Skip to content

Commit 256c553

Browse files
committed
fixup
[skip ci][ci skip]
1 parent 895830d commit 256c553

File tree

2 files changed

+28
-32
lines changed

2 files changed

+28
-32
lines changed

docs/Project.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,9 +3,9 @@ AbstractTrees = "1520ce14-60c1-5f80-bbc7-55ef81b5835c"
33
BSON = "fbb218c0-5317-5bc6-957e-2ee96dd4b1f0"
44
CSV = "336ed68f-0bac-5ca0-87d4-7b16caf5d00b"
55
CairoMakie = "13f3f980-e62b-5c42-98c6-ff1f3baf88f0"
6+
ClimaComms = "3a4d1b5c-c61d-41fd-a00a-5873ba7a1b0d"
67
ClimaCore = "d414da3d-4745-48bb-8d80-42e94e092884"
78
ClimaLand = "08f4d4ce-cf43-44bb-ad95-9d2d5f413532"
8-
ClimaLandSimulations = "348a0bd3-1299-4261-8002-d2cd97df6055"
99
ClimaParams = "5c42b081-d73a-476f-9059-fd94b934656c"
1010
ClimaTimeSteppers = "595c0a79-7f3d-439a-bc5a-b232dc3bde79"
1111
ClimaUtilities = "b3f4f4ca-9299-4f7f-bd9b-81e1242a7513"

experiments/integrated/fluxnet/met_drivers_FLUXNET.jl

Lines changed: 27 additions & 31 deletions
Original file line numberDiff line numberDiff line change
@@ -163,42 +163,38 @@ atmos = ClimaLand.PrescribedAtmosphere(
163163
c_co2 = atmos_co2,
164164
)
165165

166-
function zenith_angle(
167-
t,
168-
start_date;
169-
latitude = lat,
170-
longitude = long,
171-
insol_params::Insolation.Parameters.InsolationParameters{FT} = earth_param_set.insol_params,
172-
) where {FT}
173-
# This should be time in UTC
174-
current_datetime = start_date + Dates.Second(round(t))
175-
176-
# Orbital Data uses Float64, so we need to convert to our sim FT
177-
d, δ, η_UTC =
178-
FT.(
179-
Insolation.helper_instantaneous_zenith_angle(
180-
current_datetime,
181-
start_date,
182-
insol_params,
183-
)
184-
)
185-
186-
FT(
187-
Insolation.instantaneous_zenith_angle(
188-
d,
189-
δ,
190-
η_UTC,
191-
longitude,
192-
latitude,
193-
)[1],
194-
)
195-
end
196166
radiation = ClimaLand.PrescribedRadiativeFluxes(
197167
FT,
198168
SW_IN,
199169
LW_IN,
200170
UTC_DATETIME[1];
201-
θs = zenith_angle,
171+
θs = (t, start_date) ->
172+
let longitude = long,
173+
latitude = lat,
174+
insol_params = earth_param_set.insol_params
175+
# This should be time in UTC
176+
current_datetime = start_date + Dates.Second(round(t))
177+
178+
# Orbital Data uses Float64, so we need to convert to our sim FT
179+
d, δ, η_UTC =
180+
FT.(
181+
Insolation.helper_instantaneous_zenith_angle(
182+
current_datetime,
183+
start_date,
184+
insol_params,
185+
)
186+
)
187+
188+
FT(
189+
Insolation.instantaneous_zenith_angle(
190+
d,
191+
δ,
192+
η_UTC,
193+
longitude,
194+
latitude,
195+
)[1],
196+
)
197+
end,
202198
earth_param_set = earth_param_set,
203199
)
204200

0 commit comments

Comments
 (0)