for Loops

for Loops in Python

  1. State the syntax for for loops in Python.
  2. Use for loops to loop over range() objects.
  3. Use for loops to loop over arbitrary lists.

for Loops for Sums and Products

  1. Use for loops to compute partial sums and products.

Approximating \(\pi\) via Taylor Series

  1. Define the arctangent of a length ratio.
  2. Relate the arctangent of a length ratio to the tangent of an angle.
  3. Sketch a graph of the arctangent function, identifying its horizontal asymptotes.
  4. Explain how the Taylor series expansion of \(\arctan x\) about \(x_{0} = 0\) can be used to approximate \(\pi\).

Quadrature

  1. Explain the basic idea behind how numerical quadrature is used to approximate definite integrals.
  2. Sketch a graphical representation of the following quadrature rules:
  3. Give the expressions for the above quadrature rules.
  4. Implement the above quadrature rules using for loops.