Main Index

Week 1

Day 1 – Jan. 3

Day 2 – Jan. 5

Week 2

Day 3 – Jan. 8

  • Go over the adiabatic_box_solution_html
  • Introduce my review of the relationship between temperature and molecular kinetic energy: temperature notes
  • Introduce my review of the first law of thermodynamics: internal energy notes
  • For Wednesday:
    • Add a cell to the dry_les notebook that uses pcolormesh to plot the temperature perturbation for the last timestep at z=800 meters for ensemble member 3.
    • For discussion on Wednesday: how can we integrate \(\int_0^{Tfinal} du = \int c_v dT\) to get \(u = c_v Tfinal\) if air liquifies at 80 K?

Day 4 – Jan. 10

Day 5 – Jan. 12

  • Read through page 22 of the Adrian Thompkins notes
  • For Monday do the following problem on paper (link to a png file) or in a notebook (link to the notebook):
    • Consider two compartments, each with a volume of 1 \(m^3\), separated by a rigid, perfectly insulating membrane.
    • Initially \(T_A\) = 300 K and \(p_A\) = \(10^5\) Pa, and \(T_B\) = 100 K and \(p_B\) = \(10^3\) Pa. Suppose the membrane breaks. Find the final temperature and pressure in the 2 \(m^3\) compartment. Does the total entropy change? By how much?

Week 3

Day 6 – Jan. 15

Day 7 – Jan. 17

python idiom: keyword and argument unpacking

Try this in a notebook cell:

def tryme(a,b,c,d):
   print(f'tryme got values {a}, {b}, {c}, {d}')

def tryme2(a=1,b=2):
  print(f'tryme2 got values {a}, {b}')

tryme(1,2,3,4)
onestep=[1,2,3,4]
#
# argument unpacking
#
tryme(*onestep)

onedict=dict(a=5,b=6)
tryme2()
tryme2(b=7)
#
# keyword argument onpacking
#
tryme2(**onedict)

begin, *middle, end = (0, 1, 2, 3, 4, 5)
print(f'begin={begin}, middle={middle}, end={end}')
  • Review the first part of my notes on the Maxwell relations

  • Introduce my notes on the Clausius-Clapeyron equation and the equivalent potential temperature

  • For Friday read Adrian Thompkins notes through p. 38 and my Clausius-Clapeyron notes and equivalent potential temperature notes. Answer the question at the end of my equivalent potential temperature notes:

    Note that this result is slightly different from the result from
    Thompkins.  What is the difference, and where have the
    two derivations diverged?  (i.e. what approximation does Thompkins make
    that the current derivation avoids?)
    

    Put a image/pdf of your answer in your google drive folder – this one is credit/no credit – i.e. any reasonable attempt counts.

Day 8 – Jan. 19

Week 4

Day 9 – Jan. 22

For the saturation vapor pressure \(e_{sat}\) and compare with Thompkins 2.13 or 2.15 for 10 temperatures between 0 and 20 degrees C. (Hint: in this case, the temperature \(T\) is fixed, the variable you are trying to guess is the the vapor pressure \(e_{sat}\), which is buried inside \(\phi_v^*\).

Day 10 – Jan. 24

Day 11 – Jan. 26

Week 5

Day 12 – Jan. 29

Day 13 – Jan. 31

  • demo how to loop through multiple soundings on the Wyoming upperair website
  • work with my cape_part1_html notebook to draw an adiabat through the LCL and LFC
  • review virtual temperature (Thompkins eqn. 2.33)
  • Review Normand’s construction (Thompkins Figure 2.19), stability (Thompkins Figure 3.17), CIN and CAPE Thompkins Figure 3.18 and 3.19
  • For Friday, calculate the buoyancy defined by Thompkins eq. 1.61 \(B=g \left ( \frac{T_{v,a} - T_{v,env}}{T_{v_env}} \right )\) as a function of height, where \(T_{v,a}\) is the virtual temperature of the pseudoadiabat and \(T_{v,env}\) is the virtual temperature of your particular environmental sounding as a function of height using the lowest level to calculate the \(theta_e\) for the moist adiabat. Check in a notebook that extends cape_part1_html by defining the function (ok to copy code from my library), running it and plotting it vs. height

Day 14 – Friday, Feb. 2

  • Go over my cape_part1_solution_html
  • For Monday: Read Thompkins to page 60
    • Hand in a written solution to taylor_mix.pdf
    • For a sounding with positive CAPE: check in a notebook with supporting files (the hdf sounding, any functions you write) that calculates:
      1. the total CAPE with units
      2. the level of neutral buoyancy LNB (where positive area stops, Thompkins Fig. 3.19)
      3. the maximum updraft velocity at the LNB
      4. the maximum cloud top height (where positive cape = negative cape)

Week 6

Day 15 – Monday, Feb 5

Day 16 – Wed., Feb 7

  • go over the virtual temperature question
  • Introduce the entraining_plume_html notebook
  • For Friday: add a cell to the entraining_plume_html notebook that plots the default sounding and \(theta_e\) vs. pressure on a skew-T plot for three different entrainment rates (0, \(2 x 10^{-4}\ s^{-1}\), and \(8 x 10^{-4}\ s^{-1}\) ). (i.e. we’re trying to reproduce Tompkins Figure 3.34)

Day 17 – Fri., Feb 9

Week 7

Day 18 – Wed., Feb 14

Day 19 – Fri., Feb 16

Week 8

Day 20 – Mon. Feb. 26

  1. Programming:
    • Be able to explain what the following functions do
      1. searchsorted
      2. rootfinding using bisection
    • Write a (pseudo-python) program to:
      • calculate the liquid water content as a function of temperature along a moist adiabat
      • calculate CAPE, updraft velocity, maximum cloud top
      • calculate the buoyancy of a range of parcel mixtures
    • Given the documentation on one of the a405thermo functions, explain how it works.
  2. Other thermo/math
    • prove that the total water mixing ratio of a fractional mixture is the linear combination of the total water mixing ratio of the two original mixtures
    • Derive the wet bulb equation starting with the moist static energy
    • Explain the difference between absolute, conditional and convective instability
    • Define CAPE, CIN, LNB, LFC and draw them on a sounding
    • Be able do a 2nd order Taylor series expansion on a polynomial function
    • Prove the the moist static energy is conserved for aidabatic ascent/descent in a hydrostatic atmosphere.
  • in class:

    • flowchart a python program that would find the vapor pressure in a 1 liter container filled with 0.25 liters of liquid water at temperatures between 0 deg C and 500 deg C
  • For Wednesday – hand in a png of a tephigram that traces the following heat engine:

    1. pseudo-adiabatic ascent in the tropical Pacific, surface pressure = 1000 hPa, where the SST is 300 K and the relative humidity is 80%. Air rises to 400 hPa and loses 80% of its liquid water
    2. Cooling at a constant pressure of 400 hPa by 20 K, with no change in total water
    3. Descent to 1000 hPa, conserving water

    Find the following:

    1. The change in enthalpy at the surface and at 400 hPa, including both sensible and latent heat terms.
    2. Find the total work done by the engine, and its efficiency.
    3. Find the percentage of the total heat change that is due to addition and remove of water during the cycle.
  • Do before class (not graded): use our thermodynamic functions to solve the problems in the thompkins_practice_html notebook.

Day 22 – Fri. Mar. 2

  • midterm

Week 9

Day 23 – Mon. Mar. 5

Day 24 – Wed. Mar. 7

Day 25 – Fri. Mar. 9

  • Go over kohler_sols_html

  • Go over the koehler stability notes

  • Look at Lohmann Figure 6.10 on how a cloud chamber works

  • For Monday read Thompkins pp. 73-76 on growth by diffusion (also covered in Lohmann Chapter 7 to p. 192)

  • For Monday upload written solutions to these two problems:

    1. Given the critical supersaturation from the kohler notes:

      \[SS=S^* - 1= \left ( \frac{4 a^3}{27b} \right )^{1/2}\]

      show that this implies, for \((NH_4)_2 SO_4\), density \(\rho_{aer}\) = 1775 \({kg}\,{m^{-3}}\) , van hoft i=3, that:

      \[S^* -1 \approx 1.54 \times 10^{-12}~ m_{aer}^{-0.5}\]

      where \(m_{aer}\) is the ammonium sulphate aerosol mass in kg.

      Note that this is why a cloud chamber can get the aerosol mass distribution from a series of saturation and light scattering measurements as smaller and smaller aerosols are pushed over their critical supersaturation and activated.

    2. Show that the expression for second derivative of the thermodynamic potential derived in the kohler stability notes:

      \[\frac{\delta ^2G}{\delta r^2} = - 4 \pi R_v T \rho_l \left [ 2 a - r^2 \left ( 1 + \frac{b}{r^3} \right ) \frac{3b}{r^4} \right ] + 8 \pi \sigma\]

      Changes sign from stable (positive) to unstable (negative) at \(r_{crit}\).

      Hint – first show that the second derivative is zero at the critical radius. Then show that the third derivative is negative above and below the critical radius, which means that there has to be a sign change from + to -.

Week 10

Day 26 – Mon. Mar. 12

  • Go over the day25_aerosol_sol_html notebook

  • My handwritten solution to the Kohler stability problem (note E=G in my old notation)

  • My aero_dist_html notebook on aerosol size distriubtions.

  • For Wednesday:

    • Read my droplet growth notes

    • Hand in your version of the aero_dist_html answering the question in the last cell:

      • “Add a cell to this notebook that makes a plot of \(N(r)\) vs. \(S_{crit}\) for the \(n(r)\) in the previous cell, where:

        \(N(r) = \int_r^\infty n(r) dr\) is the number of aerosols with dry radii larger than \(r\) and \(S_{crit}\) is the critical supersaturation at radius r for these ammonium sulphate aerosols. Explain briefly why this is the output you would expect to see from an aerosol size counter based on a cloud chamber with a laser scattering sensor.

Day 27 – Wed. Mar. 14

  • Introduce my new Koehler equation module in dropgrowA_html

  • For Friday – read Lohmann pp. Ch 7 top page 197 and my equilibrium supersaturation notes

  • Hand in a notebook that adds the following plots to dropgrowA_html:

    • a plot of the ratio \(n_s/n_w\) as a function of equilibrium radius for the 30 aerosols in the mass distribution. Do this twice, once assuming that

      \[n_w = 4/3 \pi r^3 \rho_l/M_w\]

      (i.e. that the solution is so dilute that you can neglect the aerosol’s contribution to the volume of the drop.

    • Repeat making an exact calculation for \(n_w\) – i.e. find the part of the volume that is due to the aerosol (just its mass/(aerosol density)) and subtract that off from the drop volume before calculating \(n_w\) (assuming that the aerosol density is 1775 \(kg/m^3\)).

Day 28 – Fri. Mar. 16

  • For Monday, Read – Thompkins Sections 4.4-4.5 on collision coalescence

Hand in either a notebook or an image

  1. Assuming that cloud condensation nuclei (CCN) are removed from the atmosphere by first serving as the centers on which cloud droplets form, and the droplets subsequently grow to form precipitation particles, estimate the residence time of a CCN in a column extending from the surface of the Earth to an altitude of 5 km. Assume that the annual rainfall is 100 cm and the cloud liquid water content is 0.30 \(g/kg\) . Hint: Assume that all drops in the cloud have a radii of 10 microns and that every droplet contains exactly 1 CCN. How many CCN are in 1 kg of air? About how many kg of air are there in a 5 km column? About how many CCN are taken out by a rain rate of 1 m/year? Can you encode this information in a time constant of the form 1/N dN/dt = 1/tau ?
  2. A drop with an initial radius of 100 µm falls through a cloud containing 100 droplets per cubic centimeter that it collects in a continuous manner with a collection efficiency of 0.800. If all the cloud droplets have a radius of 10 µm, how long will it take for the drop to reach a radius of 1 mm? You may assume that for the drops of the size considered in this problem the terminal fall speed v (in \(m s^{-1}\)) of a drop of radius r (in meters) is given by \(v= 8 x 10^3\;r\). Assume that the cloud droplets are stationary and that the updraft velocity in the cloud is negligible. Hint: Integrate Thompkins equation 4.28

Week 11

Day 29 – Monday, March 19

  • Coverage – Thompkins section 4.4 and 4.5
    • Important equations/figures: why do warm clouds rain in 15 minutes?
      • 4.26, 4.27, 4.29, Figure 4.22, 423
  • Go over drizzle flux solutions
  • Where does the Marshall-Palmer distribution come from? 2009 article on the origins of the Marshall Palmer distribution Villermaux and Bossa (2009)
  • Ice nucleation slides
  • For Wednesday – Read Thompkins 4.6 and 4.7
  • Add cells to marshallpalmer_html that do the following:
    • Confirm that the mean diameter of the Marshall Palmer distribution is \(1/\Lambda\)
    • Calculate the precipitation flux (mm/hr) using the Marshall Palmer size distribution and the fall speed of Villermaux and Bossa (2009): \(w = - \sqrt{\rho_l/\rho_{air} * g *D}\) where D is the drop diameter and \(\rho_l,\rho_{air}\) are the liquid and air densities. Show that you get about R=15 mm/hour back if you put in R=15 mm/hour into the size distribution.

Day 30 – Wed., March 21

For Friday -

  • Read Thompkins pp. 82-98

  • hand in:

  • a png file showing your derivation of (6) in the equilibrium supersaturation notes

    \[\frac{d r_v}{dt} = \left (1 + SS \right ) \left [ \frac{-\epsilon e_s}{p^2} \left ( \frac{-g p V}{R_d T} \right ) + \frac{\epsilon}{p} \left ( \frac{\epsilon e_s L}{R_d T^2} \right ) \frac{dT}{dt} \right ] + \frac{\epsilon e_s}{p} \frac{dSS}{dt}\]

    where \(V\) is the vertical velocity.

  • Add a cell to the bottom of the dropgrow_full_html that defines a function that uses (6) to find dSS/dt. Check your function by showing that it predicts the slope dSS/dt at z=1010 meters in the figure at the bottom of the notebook, given the values of \(dr_v/dt\), \(p\), \(dT/dt\) etc. at 1010 m.

Day 31 – Fri., March 23

  • Go over Matt’s solution to dropgrow_full_predictSS_html

  • Introduce: Thompkins parameterization notes on model parameterization

  • For Monday:

    • Read Thompkins parameterization notes Sections 4.1 - 4.6 on cloud parameterizations

    • Modify dropgrow_full_predictSS_html to do the following and hand in the modified notebook:

      • Add a cell that defines a new version of find_derivs that adds SS as bulk variable number 4, in location deriv_vec[-4]. Note that you will need to increase the size of var_vec in the notebook by 1:

        var_vec = np.empty(numrads + 4)
        

        and initialize SS by adding the line:

        var_vec[-4] = parcel.SS
        

        where you have calculated the initial SS and added it to input_dict[‘initial_conditions’]

      • Note that I’ve checked in a new version of rlcalc and rlderiv:

        def rlcalc(var_vec,cloud_tup,nvars=3):
        
        def rlderiv(var_vec,deriv_vec,cloud_tup,nvars=3):
        

        You will need to call them with nvars=4 to account for the fact that you now have:

        SS, temp, press, height
        

        as the last 4 variables in var_vec

      • Run the model with this new set of equations – does it solve the problem of unstable aerosol activation?

Week 12

Day 32 – Mon., March 26

  • Introduce the 2012 final exam
  • Go over the explicit SS solution: mine – dropgrow_full_fourvars_html and Matt’s – dropgrow_full_predictSS_FungM_html
  • How do we develop and test relative-humidity base cloud fraction parameterizations like those discusses in the Thompkins parameterization notes section 4.6? Look at the CGILS experiment data in the cgilsI_html notebook.
  • For Wednesday:
    1. Read Thompkins chapter 4 parameterization notes through section 4.7.1
    2. Hand in a notebook that adds cells to cgilsI_html to:
      • use pcolormesh to plot a vertical cross section of the relative humidity for along y=2 km, x= 0->5 km
      • use plot to plot a vertical profile of the horizontal mean RH in for this cross section as a function of height
      • use plot to plot a vertical profile of the horizontal standard deviation of RH as a function of height

Day 33 – Wed., March 28

Day 35 – Fri., April 6