From 89b9fd93f64b4b56c20f082a0a29f078e495d997 Mon Sep 17 00:00:00 2001 From: Brian Groenke Date: Sun, 20 Oct 2024 13:44:11 +0200 Subject: [PATCH] Fix error in parameter ensembles example --- examples/cglite_parameter_ensembles.jl | 3 +-- src/Physics/Snow/snow_lite.jl | 1 + 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/examples/cglite_parameter_ensembles.jl b/examples/cglite_parameter_ensembles.jl index 7573f276..1eec62a5 100644 --- a/examples/cglite_parameter_ensembles.jl +++ b/examples/cglite_parameter_ensembles.jl @@ -35,8 +35,7 @@ upperbc = TemperatureBC( ) ssinit = ThermalSteadyStateInit(T0=-15.0u"°C") heatop = Heat.EnthalpyImplicit() -freezecurve = FreeWater() -heat = HeatBalance(heatop; freezecurve) +heat = HeatBalance(heatop) soil_layers = map(para -> Ground(para; heat), soilprofile) strat = Stratigraphy( z_top => Top(upperbc), diff --git a/src/Physics/Snow/snow_lite.jl b/src/Physics/Snow/snow_lite.jl index adc4ee93..f6c28d30 100644 --- a/src/Physics/Snow/snow_lite.jl +++ b/src/Physics/Snow/snow_lite.jl @@ -138,6 +138,7 @@ function CryoGrid.initialcondition!(snowpack::LiteSnowpack, ::SnowMassBalance, s @. state.ρsn = snowpack.para.ρsn_0 @. state.swe = 0.0 @. state.dsn = 0.0 + @. state.ubc_idx = length(state.T) end function Hydrology.watercontent!(snow::LiteSnowpack, ::WaterBalance, state)