Skip to content

brianhill/loops-and-orbits

Repository files navigation

Loops and Orbits

Programming for Aspiring Rocketeers

Whole Class

Weekly Schedule

Week 1

  • Physics & Math: The Description of Motions of Objects in 1-D including Coordinates, Units, Speed, Velocity, and Acceleration.
  • Computer Science: Jupyter Notebooks. Documentation in Markdown. Elements of Python including Expressions, Statements, Variables and Assignments, Types (Lists, Tuples, and Ranges), Control Flow (While and For loops), and introducing Functions.

Week 2

  • Physics & Math: The Description of Motions of Objects in 2-D. Projectile Motion. Two-Dimensional Acceleration. Newton's Universal Theory of Gravitation
  • Computer Science: Continue Discussion of Functions, Scope and Lifetime of Variables. Libraries. Testing. Debugging. Dot Notation for Library Functions and Object Methods.

Week 3

  • Physics, Math & Applications: Circular and Elliptical Orbits. Modeling Battery Charging. Modeling Economic Growth. Kepler's Laws. Energy Conservation.
  • Computer Science: Numpy. Mutability, Assignment, and Performance of Python Lists and Numpy Arrays. Second Order Runge-Kutta and Midpoint Method Improvememts to Euler and Euler-Cromer Update Methods. Data Visualization with Pandas.

Week 4

  • Final Project: Planning, Selection, Work, and Presentations.

Bonus Notebooks

During the coronavirus on-line courses period, these notebooks were developed as one alternative to continuing the normal introductory physics labs:

Instead of using these notebooks, we ended up sending the students kits to perform Physics 4 labs at home, but they might still be useful starting points, so I'll leave them up.

Daily Schedule

Week 1 Daily Schedule

Week 1 Physics & Math

  • Physics and Math Day 1-1: Speed; Velocity; Definitiions; Coordinates; Units of Position and Velocity; Velocity from Position.
  • Physics and Math Day 1-2: Position from Velocity. Indices. Summations. Relationship to Derivatives and Integrals.
  • Physics and Math Day 1-3: Physics Laws. Acceleration. Newton's Three Laws. Units of Acceleration. Constant Acceleration.
  • Physics and Math Day 1-4: Air Glider on Spring Demonstration. Amplitude. Period. Frequency. Spring Constant. Mass. Sign of Acceleration. Comparing Position, Velocity, and Acceleration Graphs. Adding Damping to Air Glider. Adding Wind Resistance to Drag Racer.

Week 1 Worksheets

  • Worksheet 1: Velocity from Position (Lionel Messi Run).
  • Worksheet 2: Position from Velocity (Lionel Messi Run).
  • Worksheet 3: Steady Acceleration with Graphs (Drag Racer).

Week 1 Computer Science

  • Computer Science Day 1-1: Markdown. Statements. Expressions. Variables and Assignments. Types.
  • Computer Science Day 1-2: Comparisons; While Loops; Lists; Lists vs. Arrays.
  • Computer Science Day 1-3: Tuples; Unpacking Tuples; Ranges; For Loops; Compare and Contrast Lists, Tuples, and Ranges.
  • Computer Science Day 1-4: Introduce Function Definitions (Power-of-Two Implementation), Function Usage (Call Sites), Scope of Variables. Lifetime of Variables. Pass-by-Value Example (Alternate Power-of-Two Implementation). Pass-by-Reference Example (Add-to-Roster).1

Week 1 Python Coding Lab

Week 1 Homework

Week 2 Daily Schedule

Week 2 Physics & Math

  • Physics and Math Day 2-1: Lengths; Angles; Position, Velocity, and Acceleration in 2-D; Similar Triangles; Getting Components of Vectors from Lengths and Angles; Newton's Laws in 2-D, Vector Form, Component Form.
  • Physics and Math Day 2-2: Getting Lengths and Angles from Components of Vectors; Air Resistance in 2-D. Rocket Thrust in 2-D.
  • Physics and Math Day 2-3: Newton's Universal Theory of Gravitation.
  • Physics and Math Day 2-4: Midterm at this time.

Week 2 Computer Science

Week 2 Python Coding Lab

Week 2 Homework

Week 3 Daily Schedule

Week 3 Physics, Math & Applications

  • Physics & Math Day 3-1: First Order Differenential Equations. Charging a Battery. Charging a Capacitor (see Homework 3). Viral Exponential Growth.
  • Special Economics Day 3-2 with Prof. Margitay-Becht: Solow-Swan Economic Growth Model.
  • Physics & Math Day 3-3: Elliptical Orbits. Kepler's Laws.
  • Physics & Math Day 3-4: Transfer Orbits. Energy Conservation.

Week 3 Computer Science

  • Computer Science Day 3-1: Mutability, Assignment, and Performance of Python Lists and Numpy Arrays.
  • Computer Science Day 3-2 with Prof. Margitay-Becht: Multi-Function Plots.
  • Computer Science Day 3-3: Improving on the Euler and Euler-Cromer Update Methods with 2nd Order Runge Kutta.
  • Computer Science Day 3-4: Data Visualization with Pandas.

Week 3 Python Coding Lab

Week 3 Homework

Week 3 Final Project Planning and Selection

  • Start Final Project Planning on Day 3-4.

Week 4 Daily Schedule

Plan

Teams

Week 4 Final Project Schedule

  • Final Project Preparation Day 4-1: Class-time devoted to preparing final projects. Short progress presentations.
  • Final Project Preparation Day 4-2: Class-time devoted to preparing final projects. Short progress presentations.
  • Final Project Preparation and Presentations Day 4-3: 2/3 of class time devoted to preparing final projects; 1/3 devoted to first 3 final project presentations.
  • Final Project Presentations Day 4-4: Remaining eight final project presentations.

Week 4 Homework

Footnotes

1: For students who had an easy time accepting the pass-by-value and pass-by-reference rules, here is a good-quality and patient explanation of how those somewhat contradictory rules are actually highly compatible: Is Python pass-by-reference or pass-by-value? The bottom line is Python is indeed pass-by-value, but a list is an object — we haven't learned about objects yet! — and for objects the variable and the function argument are references to the object, not the object itself. This means that the function body gets a copy of the reference to the list, and the copy of the reference still refers to the original list.