04-1-filtration.py
author Dmitriy Morozov <dmitriy@mrzv.org>
Mon, 18 Jun 2012 10:04:58 -0700
changeset 5 9acb920a945c
parent 2 4b3728f0d920
permissions -rw-r--r--
Added PDF of the talk

simplices = [([0], 1),   ([1], 2), ([0,1], 3), ([2], 4), \
             ([1,2], 5), ([0,2], 6)]
f = Filtration()
for vertices, time in simplices:
     f.append(Simplex(vertices, time))
f.sort(dim_data_cmp)
for s in f:
    print s, s.data    # s.data is the time