Omniadisce

Computational physics 5.1: Draw your results with plot()

Lesson Beginner

Join free to take this lesson

Anyone can look around, but taking a lesson needs a free account. With one, your answers are checked step by step and your progress is saved, so you can stop and pick up where you left off on any device.

11 steps ยท about 20 min

By the end you can

  • Draw a graph with plot(xs, ys), from two lists or arrays of the same length
  • Name the axes and the lines: plot(t, s, "Earth", x="t (s)", y="s (m)")
  • Put two lines on one graph to compare them
  • Read the error when the two lists don't match

Who it is for: Anyone who has done units 1-4 of this course (or skipped them), and physics lesson 2.7 (free fall).

The steps

  1. plot(xs, ys)
  2. Your first plot
  3. Two lists that don't match
  4. Names for the axes
  5. A longer fall
  6. A smooth curve from an array
  7. A smooth curve
  8. Two lines on one graph
  9. Earth and Moon
  10. Reading the graph
  11. Why draw it?

Discussion 0 comments

Log in to join the discussion.

× Enlarged view