Skip to content

Commit

Permalink
wvel also above cloud base
Browse files Browse the repository at this point in the history
  • Loading branch information
yoctoyotta1024 committed Jan 16, 2024
1 parent 95672ee commit 47a6af4
Showing 1 changed file with 2 additions and 5 deletions.
7 changes: 2 additions & 5 deletions pySD/thermobinary_src/thermogen.py
Original file line number Diff line number Diff line change
Expand Up @@ -553,17 +553,14 @@ def hydrostatic_lapserates_thermo(self, zfulls):
return TEMP, PRESS, qvap

def wvel_profile(self, gbxbounds, ndims, ntime):
''' returns WVEL=0.0 above cloud base, and sinusoidal profile
with amplitude WMAX and wavelength 2*Wlength below cloud base'''
''' returnssinusoidal profile with amplitude WMAX
and wavelength 2*Wlength '''

zfaces = rgrid.coords_forgridboxfaces(gbxbounds, ndims, "z")[0]
WVEL = self.WMAX * np.sin(np.pi * zfaces/(2*self.Wlength))

WVEL = np.where(zfaces < self.Zbase, WVEL, 0.0)

return np.tile(WVEL, ntime)


def generate_winds(self, gbxbounds, ndims, ntime, THERMODATA):

THERMODATA = constant_winds(ndims, ntime, THERMODATA,
Expand Down

0 comments on commit 47a6af4

Please sign in to comment.