Week 11: April 17 - 21

Generating Random Numbers

Sequences of random numbers are frequently needed to simulate processes in which outcomes are uncertain. Although computers work on deterministic principles, we see that they can be used to generate “pseudo-random” numbers that satisfy various tests for randomness.

Monte Carlo Methods

Monte Carlo methods use sequences of random numbers to obtain numerical results for functions or processes that are otherwise difficult to analyze. We apply such methods to integration, to estimating probabilities, and to a simple model of stock price movements.

Week 11 Notebook

NumPy

  • numpy.random.rand
  • Axis-dependent operations: sum, mean, amin, amax

Matplotlib

  • hist