We introduce the formal foundations of a set-theoretic data model that can model data at both the logical and physical level. To demonstrate its practical value, we show how to use it to dynamically restructure data based on query requirements. Over time, most queries can be answered by retrieving from disk at most a small superset of the data they actually need, thereby yielding higher performance than conventional methods in today's database systems.
The formal foundation defines operations and operands where all data representations belong to the same clan (with set theory being the common formal ancestor), allowing all operations to apply meaningfully to all operands. All data representations, both logical and physical, are treated as mathematical objects, instead of relying solely on the specific physical structure of the data representation. The mathematical mechanism includes extensions to set theory that support a compound set-membership condition, set-theoretic definitions of data representations that faithfully preserve content, structure and behavior, and a homogeneous integration of XML structures and the relational model.