Skip to content

Commit

Permalink
Remove lingering debug code from example
Browse files Browse the repository at this point in the history
  • Loading branch information
bgroenks96 committed Aug 29, 2023
1 parent 598085e commit 15845a1
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 6 deletions.
6 changes: 1 addition & 5 deletions examples/06_heat_freeW_seb_snow_bucketW_samoylov.jl
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ z = 2.0u"m"; # height [m] for which the forcing variables (Temp, humidity, wind,
seb = SurfaceEnergyBalance(forcings.Tair, forcings.pressure, forcings.q, forcings.wind, forcings.Lin, forcings.Sin, z)
swb = SurfaceWaterBalance(rainfall=forcings.rainfall, snowfall=forcings.snowfall)
upperbc = WaterHeatBC(swb, seb)
heat = HeatBalance(:H, freezecurve=PainterKarra())
heat = HeatBalance(:H)
water = WaterBalance(BucketScheme(), DampedET())
## build stratigraphy
strat = @Stratigraphy(
Expand Down Expand Up @@ -63,10 +63,6 @@ integrator = init(prob, Euler(), dt=60.0)
end
out = CryoGridOutput(integrator.sol)

while convert_t(integrator.t) < DateTime(2011,6,1)
step!(integrator)
end

# Plot it!
import Plots
zs = [1,5,10,15,20,25,30,40,50,100,150,200,500,1000]u"cm"
Expand Down
2 changes: 1 addition & 1 deletion src/Physics/Heat/heat_types.jl
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ Base.@kwdef struct HeatBalance{Tfc<:FreezeCurve,THeatOp<:HeatOperator,Tdt,Tprop}
end
# convenience constructors for HeatBalance
HeatBalance(var::Symbol; kwargs...) = HeatBalance(Val{var}(); kwargs...)
HeatBalance(::Val{:H}; freezecurve::FreezeCurve=FreeWater, fcsolver=default_fcsolver(freezecurve), kwargs...) = HeatBalance(; op=EnthalpyForm(fcsolver), freezecurve, kwargs...)
HeatBalance(::Val{:H}; freezecurve::FreezeCurve=FreeWater(), fcsolver=default_fcsolver(freezecurve), kwargs...) = HeatBalance(; op=EnthalpyForm(fcsolver), freezecurve, kwargs...)
HeatBalance(::Val{:T}; freezecurve::FreezeCurve, kwargs...) = HeatBalance(; op=TemperatureForm(), freezecurve, kwargs...)
HeatBalance(op::HeatOperator; kwargs...) = HeatBalance(; op, kwargs...)
# validation of HeatBalance freezecurve/operator configuration
Expand Down

0 comments on commit 15845a1

Please sign in to comment.