TME 310 - Computational Physical Modeling

Approaching Problems

Lorne Arnold, PhD, PE

University of Washington Tacoma

Homework format

Based on the problem-solving approach proposed by G. Polya:

From How to solve it

  1. Understand the problem
  2. Make a plan
  3. Carry out the Plan
  4. Look back at the solution

TME 310 Homework

  1. Summarize
  2. Plan
  3. Code
  4. Reflect

Steps 1 and 2

Understand and Plan

These are about aligning your efforts with your goals.

G. Polya:

It is foolish to solve a problem that you do not understand.
It is sad to work for an end that you do not desire.

Optional Canvas assignment: What do you want to model?

Step 3

Code

I strongly recommend an incremental development1 approach:

Incremental development

  1. Always start with a working program
  2. Make one small, testable change at a time.
  3. Run the program and see if the change worked.

Step 4

Look back

There are two places I’ll ask you to look back:

The Reflect prompt

Looking back at your code and the resulting output, reflect on whether your code achieved the problem goal(s). To the extent the problem models a physical system, how realistic does the behavior seem? Are there any changes you would make to your approach if you were to solve this problem again (e.g., to make your code more re-usable or to avoid dead ends)?

Self-grading

  • This should only take a few minutes of your time
  • Reinforces the look back
  • Focus on comparing your code to the solution code