Why are quantifiers needed in Tuple Relational Calculus?

322 Views Asked by At

Why are quantifiers needed in Tuple Relational Calculus?
Lets say I have this statement:

{S.sname | S in Student and (exists G in Grade )(S.s# = G.s#)};

Why can't I just use this instead?

{S.sname | S in Student and G in Grade and S.s# = G.s#};

1

There are 1 best solutions below

4
On BEST ANSWER

When you write "$\{S: $ stuff about $S$ and $G\}$", what does $G$ mean? Think about it this way: if I say "The set of people who bought Sam a penguin," this describes a set - except you don't know who Sam is. Now, by contrast, "The set of people who bought someone a penguin" makes perfect sense. This latter sentence has the form "$\{S: \exists G($stuff$)\}$": it is $\{p$: there exists a person $q$ such that $p$ bought $q$ a penguin$\}$.

The point is that you need the "$\exists$" to make what you're writing fully meaningful: free variables - that is, variables not bound by a quantifier, or introduced via set-builder notation - are inherently ambiguous.