IPython Notebook for turning in solutions to the problems in the Essentials of Paleomagnetism Textbook by L. Tauxe

Problems in Chapter 6

Problem 1


In [18]:
from IPython.display import Image   # this is how you display images in your notebook. 
Image(filename='ps6_prob1.png')


Out[18]:

Type your answer here.

Problem 2a

Start by modifying the function dir2cart from Problem set # 2:


In [19]:

Read in the datafile 'demag.dat' in the Chapter_6 folder in the data_files/Essentials_Examples directory that comes with the PmagPy distribution. Copy that folder into the directory with you notebook in it.


In [4]:
import numpy as np
data=np.loadtxt('Chapter_6/demag.dat')  # this will load the data. 
# first print it out so you can see what is in data....   
# Put Temperature in Ts and Ints, Decs Incs into their own lists
# check whether you should transpose data to make that easier.  
# then send your data to your dir2cart function.

Problem 2b

For this we just have to normalize the intensities by the first step and re-run dir2cart.


In [21]:

Problem 2c

Now plot X and Y components versus Temperature


In [6]:
import matplotlib.pyplot as plt
%matplotlib inline
# plot Temperatures on the X axis and X on the Y axis.
# Then do the same (using different symbols) for Y on the Y axis.  
# add labels for the X and Y axes.

Write your figure caption here.