0

I'm pretty sure this question has been asked before, I tried looking for something like it, however, I couldn't find anything.

Given two relations $R(A,B),S(B,C)$, assuming S is not empty, prove the following equality: $$(R \times \pi_A(S)) \div \pi_A(S) \equiv R$$

Intuitively:

It's pretty clear that we are concatenating each entry in $R$ with every entry in $\pi_A(S)$, thus when dividing we get the relation $R$.

Is my claim correct?, if so how can I prove this formally?

Aa me
  • 148
  • It shouldn't be dividing, it should be a quotient. Also, what is $\pi_A$? Some sort of projection? – CyclotomicField Dec 09 '21 at 13:50
  • yes, $\pi_{A}$ is a projection of the attribute A. – Aa me Dec 09 '21 at 13:51
  • 1
    It seems so... See Relational Algebra. We assume $A \subseteq B$. With $R \times S$ we get pairs of pairs $((a,b),(1)), ((a,b),(2)),((a,b),(3))$ where $(1),(2),(3)$ are all pairs of $S$. With $R \times \pi_A(S)$ we cut out all the pairs of pairs whose second pair [$(1),(2),(3)$] is not in $A$ [e.g. $(2)$]. Result: $((a,b),(1)), ((a,b), (3))$. If now we "divide" we get "the restrictions of tuples in R to the attribute names unique to R for which it holds that all their combinations with tuples in S are present in R." – Mauro ALLEGRANZA Dec 09 '21 at 14:30

0 Answers0