(a) The Archimedean spiral:
import pylab
theta = pylab.linspace(0., 8*pylab.pi, 1000)
a, b = 0, 2.
pylab.polar(theta, a+b*theta)
pylab.show()
(b) The logarithmic spiral
import pylab
theta = pylab.linspace(0, 8*pylab.pi, 1000)
a1 = 0.8
pylab.polar(theta, a1**theta)
pylab.show()