
# plotSine.py
# langtangen, B.1.1, The Sine function, p. 684

# input: 5, or 10, or 20, or 100

import math
import matplotlib.pyplot as plt
from frange import *


n = int(input("n? "))

xs = linspace(0, math.pi, n+1)
ys = [math.sin(x) for x in xs]

plt.plot(xs, ys)
plt.title("Plot sin() for n="+str(n))

plt.show()
