## incremental deletion

when the insertion of a value depends on the non-presence of another (contained in a negated relation), then that means for insertions into a negated relation, existing facts must be removed if they can not be backed by any other rule. take for instance `C(x) :- A(x), !B(x).` which subtracts set B from set A. this is equivalent to `!C(x) :- !A(x). !C(x) :- B(x).`, which could be called deletion rules. simply put, `Y(x) :- X(x). Y(x) :- Z(x).`, without any further disjunctive rules, implies `!Y(x) :- !X(x),!Z(x).`, and in a "convex" set this can be ignored, but if `!X` and `!Z` conclusions exist, then `!Y` conclusions must also be realized. all this gives us clear logical paths to follow and thus seems reasonable to me, if only it is unclear how to implement this efficiently.
## incremental deletion when the insertion of a value depends on the non-presence of another (contained in a negated relation), then that means for insertions into a negated relation, existing facts must be removed if they can not be backed by any other rule. take for instance `C(x) :- A(x), !B(x).` which subtracts set B from set A. this is equivalent to `!C(x) :- !A(x). !C(x) :- B(x).`, which could be called deletion rules. simply put, `Y(x) :- X(x). Y(x) :- Z(x).`, without any further disjunctive rules, implies `!Y(x) :- !X(x),!Z(x).`, and in a "convex" set this can be ignored, but if `!X` and `!Z` conclusions exist, then `!Y` conclusions must also be realized. all this gives us clear logical paths to follow and thus seems reasonable to me, if only it is unclear how to implement this efficiently.
## relations as first-class objects

logically, all relations could be collated into a single relation of polymorphic variadic type, where the relation itself becomes the first argument, i.e. `rel(x,...)` becomes `(rel,x,...)`.

this then makes it possible to e.g. match all relations that contain a specific value in a specific column, or to enumerate all relations that exist in the program, or to interrogate the program. it would also permit dynamic creation of new relations at runtime, although more properties are required to capture every aspect of a relation. to begin with, what is the arity of a relation? this, too, is an arbitrary constraint.

the "super relation" as i would call it also hosts every virtual relation, and thus likely has cosmic proportions, so can not be naively enumerated.
## relations as first-class objects logically, all relations could be collated into a single relation of polymorphic variadic type, where the relation itself becomes the first argument, i.e. `rel(x,...)` becomes `(rel,x,...)`. this then makes it possible to e.g. match all relations that contain a specific value in a specific column, or to enumerate all relations that exist in the program, or to interrogate the program. it would also permit dynamic creation of new relations at runtime, although more properties are required to capture every aspect of a relation. to begin with, what is the arity of a relation? this, too, is an arbitrary constraint. the "super relation" as i would call it also hosts every virtual relation, and thus likely has cosmic proportions, so can not be naively enumerated.