flâneur — a map of the web's best reading

Reading 11: Abstraction Functions & Rep Invariants

web.mit.edu · 8,868 words · saved by 1 readers

In this reading, we study a more formal mathematical idea of what it means for a class to implement an ADT, via the notions of abstraction functions and rep invariants. These mathematical notions are eminently practical in software design. The abstraction function will give us a way to cleanly define the equality operation on an abstract data type (which we’ll discuss in more depth in a future class). The rep invariant will make it easier to catch bugs caused by a corrupted data structure.

Reading 11: Abstraction Functions & Rep Invariants Reading 11: Abstraction Functions & Rep Invariants Software in 6.031 Safe from bugs Easy to understand Ready for change Correct today and correct in the unknown future. Communicating clearly with future programmers, including future you. Designed to accommodate change without rewriting. Objectives Today’s reading introduces several ideas: invariants representation exposure abstraction functions representation invariants In this reading, we study a more formal mathematical idea of what it means for a class to implement an ADT, via the notions o

Explore this link on the map →

related reading