Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

set! for PrescribedAtmosphere #252

Open
glwagner opened this issue Nov 15, 2024 · 0 comments
Open

set! for PrescribedAtmosphere #252

glwagner opened this issue Nov 15, 2024 · 0 comments

Comments

@glwagner
Copy link
Member

glwagner commented Nov 15, 2024

It would be fun to support set! for PrescribedAtmosphere, which would give us more flexibility in constructing idealized atmospheric states like #251 .

Oceananigans CliMA/Oceananigans.jl#3929 is related, since having set! for FieldTimeSeries will help a lot.

I'm envisioning something like

# Atmospheric state parameters
Tₐ = 273.15 + 20 # Kelvin
u₁₀ = 10 # wind at 10 m, m/s
qₐ = 0.01 # specific humidity
Qℓw = 400 # shortwave radiation (W m⁻², positive means heating right now)

# Build the atmosphere
atmosphere_grid = RectilinearGrid(size=(), topology=(Flat, Flat, Flat))
atmosphere_times = range(0, 1day, length=3)
atmosphere = PrescribedAtmosphere(atmosphere_grid, atmosphere_times)

set!(atmosphere, T=Tₐ, u=u₁₀, q=qₐ, Qℓw=Qℓw)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant