MIT6_851S10_lec19

MIT6_851S10_lec19 - 6.851: Advanced Data Structures Spring...

Info iconThis preview shows pages 1–3. Sign up to view the full content.

View Full Document Right Arrow Icon

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
This is the end of the preview. Sign up to access the rest of the document.

Unformatted text preview: 6.851: Advanced Data Structures Spring 2010 Lecture 19 April 15, 2010 Prof. Erik Demaine 1 Overview This lecture is an interlude on time travel in data structures. Well consider two kinds of time-travel (temporal) data structures, based on the two leading theories of time travel: 1. Branching-universe model a.k.a. persistence: You can change the past, but then you enter a different branch of the universe, and never to return to the old one. In some cases, though, branches might merge (conuence). 2. Round-trip model a.k.a. retroactivity: You can change one thing in the past and then teleport back to the present and see what changed. In data structures, persistence is much easier to achieve than retroactivity: in most cases, persis- tence can be done with tiny overhead, whereas retroactivity can require linear overhead. This is strong computational evidence that the second model of time travel is impossible, while the first model (and a model where you can go back, but not forward, in time) is conceivable computation- ally. These data structural paradigms are also useful for more mundane applications like computational geometry, but we wont discuss those here. 2 Persistence 2.1 4 Levels of Persistence We begin by describing the levels of desired persistence. With data structure persistence, we would like to keep all versions of the data structure available for updates and queries. Each persistence level, however will vary based on where updates are allowed and how branches and nodes are modified and created. 1. Partial Persistence In this persistence model, we may query any previous version of the data structure, but we may only update the latest version. This implies a linear ordering among the versions. 2. Full Persistence In this model, both updates and queries are allowed on any version of the data structure. The versions here form of a branching tree. 3. Conuent Persistence In this model, we use combinators to combine input of more than one previous versions to output a new single version. Rather than a branching tree, combinations of versions induce a DAG(direct acyclic graph) structure on the version graph. 1 4. Functional Persistence This model takes its name from functional programming where objects are immutable. The versions in this model are likewise immutable, so revisions do not alter the existing nodes in the data structure, but create new ones instead. Okasaki discusses these as well as other functional data structures in his book [ ? ]. Each of the succeeding levels of persistence imply the preceding ones. That is, Functional Per- sistence = Conuent Persistence = Full Persistence = Partial Persistence. Functional implies conuent because we simply use the combinators to append a new combined version. Con- uent implies full if we do not use combinators. Lastly, full implies partial if we only update the most recent version....
View Full Document

This note was uploaded on 03/31/2011 for the course EECS 6.851 taught by Professor Erikdemaine during the Spring '10 term at MIT.

Page1 / 10

MIT6_851S10_lec19 - 6.851: Advanced Data Structures Spring...

This preview shows document pages 1 - 3. Sign up to view the full document.

View Full Document Right Arrow Icon
Ask a homework question - tutors are online