1. Correct the 5 errors in the following program.
# Part a
x=1
print "sin(%g)=%g" % (x, sin(x))
# Part b
F = 114
print 5/9*(F-32)
# Part c
interest = "0.1%"
print "Growth = %g" % 42.0*float(interest)
# Part d
# Table header:
# Survey Name USGS ID Contributor Year Number of Tracklines KMS Shot
line = "Beaufort Sea W-62-77-AR WesternGeco 1977 69 4,987"
print "The year the data was collected was %d", line[4]
# Part e
heights = (1.56, 1.67, 1.97, 1.43)
heights.append(1.81)
print heights
2. The equation $s=ut-\frac{1}{2}gt^2$ can be used to describe the height of a ball thrown vertically, where $s$ is the height, $u$ is the initial velocity, $t$ is the time and $g$ is acceleration (assumed here to be $9.81ms^{-2}$).
3. The Gaussian function can be defined as: $$g(x) = ae^{\frac{(x-b)^2}{2c^2}}-d.$$
4. The file hpip_yakutsk_borehole_data.txt (provided with this IPython notebook file) contains permafrost borehole temperature data (in degrees Celsius) for January between the years 1915 and 2000. By looking at the header of the text file you can see that the 2$^{nd}$ column contains the temperatures at a depth of 0.80m, the 3$^{rd}$ column contains the temperatures at a depth of 3.20m and the 4$^{th}$ column gives the surface temperatures taken from the World Monthly Surface Climatology dataset (ds570.0). A temperature value of "-999" indicates that the data value is missing.
5. Create a Python class for Igneous Rocks.