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

Problems in Chapter 7

Most of these problems, you should be able to solve on your own. congratulations! you are a programmer now! But here is one hint that will help you out with Problem 2

Problem 2

Type in here the text for your problem. what is tau? how does it depend on M?

For this problem, I want you to use the nice 'tabulate' environment, downloaded from https://pypi.python.org/pypi/tabulate/0.7.2 unzip the downloaded file, change directories into it and type the command

pip install tabulate.

You can use tabulate like this.....


In [4]:
from tabulate import tabulate
header = [["mineral","M (A/m)","B (uT)", "tau (sec)"]]
table=[['mineral','some number','some field','some number'],
      ['mineral', 'another number','another field','another number']]
print tabulate(header)
print tabulate(table)
# and so on.  of course you put in your own data.


-------  -------  ------  ---------
mineral  M (A/m)  B (uT)  tau (sec)
-------  -------  ------  ---------
-------  --------------  -------------  --------------
mineral  some number     some field     some number
mineral  another number  another field  another number
-------  --------------  -------------  --------------