Waves by Computer: Adding and Fitting Python Programming · High School (11–12), High School (9–10), Undergraduate, General · Trigonometry and Waves by Computer
Why do two close notes make beats? How can a fast wave look slow?
- Draw travelling and standing waves from their equations
- Add two waves to see beats and interference
- Build a square wave from harmonics and fit a sine curve
3Lessons10Problems2Python Labs1Question Set1Mock Test Angles, the Unit Circle and Trigonometric Graphs Python Programming · High School (11–12), High School (9–10), Undergraduate, General · Trigonometry and Waves by Computer
Why is sin(π) not exactly 0 in Python? Is sin(a + b) the same as sin a + sin b?
- Convert degrees and radians, and find sin, cos and tan
- Draw the unit circle and the graphs of sin, cos and tan
- Test identities on thousands of angles at once
3Lessons11Problems2Python Labs1Question Set1Mock Test Genetics by Computer Python Programming · High School (11–12), High School (9–10), Undergraduate, General · Biology by Computer, Simulation and Randomness
Why do pea crosses give 3 tall to 1 short? Why do small samples miss that ratio?
- Build Punnett squares in code
- Cross plants for one and two traits and count the ratios
- Simulate many crosses to see chance at work
3Lessons11Problems2Python Labs1Question Set1Mock Test Growth and Populations by Computer Python Programming · High School (11–12), High School (9–10), Undergraduate, General · Biology by Computer, Simulation and Randomness
Why can no population keep doubling for ever? How do you read growth from scattered counts?
- Model exponential growth and the doubling time
- Add a carrying capacity with logistic growth
- Fit a growth curve to real counts
3Lessons10Problems2Python Labs1Question Set1Mock Test The Periodic Table as Data Python Programming · High School (11–12), High School (9–10), Undergraduate, General · Chemistry by Computer, Data Analysis with pandas
Which elements break the rising trend across a period? How does the radius change?
- Load the elements into a pandas table
- Sort and filter them, and plot the periodic trends
- Look for properties that go together
3Lessons10Problems2Python Labs1Question Set1Mock Test Moles and Reactions by Computer Python Programming · High School (11–12), High School (9–10), Undergraduate, General · Chemistry by Computer
How can code read the brackets in Ca(OH)₂? Which reactant runs out first?
- Write a molar mass calculator that reads formulas
- Find moles, the limiting reagent and the yield
- Work out the volumes in a dilution or a titration
3Lessons10Problems2Python Labs1Question Set1Mock Test Data Analysis with pandas Python Programming · High School (11–12), High School (9–10), Undergraduate, General · Data Analysis with pandas
Can a table of the planets predict the year of Neptune?
- Build, read and clean tables with missing values
- Choose rows, add columns, group and merge tables
- Plot from a table and find a power law on a log-log graph
5Lessons10Problems6Python Labs1Question Set1Mock Test Simulation and Randomness Python Programming · High School (11–12), High School (9–10), Undergraduate, General · Simulation and Randomness
Can random dots find π? How far does a random walker wander?
- Make repeatable random numbers with a seeded generator
- Estimate π and probabilities by the Monte Carlo method
- Simulate random walks, decay and the error of a measurement
5Lessons10Problems6Python Labs1Question Set1Mock Test Calculus by Computer Python Programming · High School (11–12), High School (9–10), Undergraduate, General · Calculus by Computer
How do you find a slope with no formula? Why is the best throw below 45° in air?
- Find slopes with differences and np.gradient
- Find areas with rectangles, trapezoids and SciPy
- Follow a ball in small steps with Euler's method and solve_ivp
5Lessons10Problems6Python Labs1Question Set1Mock Test Solving Equations Python Programming · High School (11–12), High School (9–10), Undergraduate, General · Solving Equations
How can you solve cos x = x with no formula? What makes Newton's method so fast?
- Solve equations by bisection and Newton's method
- Fit lines and solve linear systems with NumPy
- Find a half-life with brentq and curve_fit
5Lessons10Problems6Python Labs1Question Set1Mock Test Graphs with matplotlib Python Programming · High School (11–12), High School (9–10), Undergraduate, General · Graphs with matplotlib
How many points make a curve look smooth? Can a car's positions give its speed?
- Draw line graphs with titles, labels, units and legends
- Choose a line, scatter, bar or histogram, and read each
- Use subplots, error bars and log scales, and save a graph
5Lessons10Problems6Python Labs1Question Set1Mock Test NumPy Arrays Python Programming · High School (11–12), High School (9–10), Undergraduate, General · NumPy Arrays
Why can changing a slice change the whole array? Which angle throws a ball furthest?
- Make arrays and use one formula on a whole array
- Pick numbers with indexes, slices and boolean masks
- Find sums, averages and standard deviations of tables
5Lessons10Problems6Python Labs1Question Set1Mock Test