Mean temperature: 18.5°C
Demo Lecture - Introduction to Scientific Computing
CU Boulder ATOC
2026-01-01
Arrays are fundamental to scientific computing:
Mean temperature: 18.5°C
Key point: NumPy operations are vectorized and fast!
Example: Working with NCEP/NCAR Reanalysis
Common operations for climate data:
data.mean(dim='time')data.groupby('season').mean()data - data.mean(dim='time')scipy.statsimport matplotlib.pyplot as plt
import numpy as np
# Generate sample data
time = np.arange(0, 24, 0.5)
temp = 15 + 5 * np.sin(2 * np.pi * time / 24)
# Create plot
plt.figure(figsize=(10, 4))
plt.plot(time, temp, 'o-', linewidth=2, markersize=4)
plt.xlabel('Hour of Day')
plt.ylabel('Temperature (°C)')
plt.title('Diurnal Temperature Cycle')
plt.grid(True, alpha=0.3)
plt.tight_layout()
plt.show()
Ideal Gas Law:
\[ p = \rho R T \]
Hydrostatic Balance:
\[ \frac{\partial p}{\partial z} = -\rho g \]
Geostrophic Wind:
\[ u_g = -\frac{1}{\rho f}\frac{\partial p}{\partial y}, \quad v_g = \frac{1}{\rho f}\frac{\partial p}{\partial x} \]
| Day | Activity |
|---|---|
| Monday | Lecture & coding demo |
| Wednesday | Lab work & debugging |
| Friday | Discussion & code review |
Prof. Will Chapman 📧 wchapman@colorado.edu 🌐 willychap.github.io 🏢 ATOC Building, CU Boulder

ATOC 4815/5815 - Chapman Research Group