City | Food |
Monza | Pasta |
Baku | Burger |
Baku | Fish |
Munich | Pasta |
Munich | Fish |
Porto | Pizza |
CapeTown | Pasta |
Cape Town | Fish |
Division in RA: The above is a table eats: Which cities eat
all the foods eaten in Munich? Be sure to show
your work
Solution
Foods eaten in Munich:
πFood(σCity='Munich'(Eats))
All possiblities of cities and food eaten in Munich
= All Cities X Foods eaten in Munich
= πCity(Eats) X πFood(σCity='Munich'(Eats))
Cities which do not eat all the foods eaten in Munich
= All possiblities of cities and food eaten in Munich - Actual city, food combination(Eats table)
= πCity(πCity(Eats) X πFood(σCity='Munich'(Eats)) - πCity,Food(Eats))
Cities which eat all the foods eaten in Munich
= All cites except Munich - Cities which do not eat all the foods eaten in Munich
= πCity(σCity!='Munich'(Eats)) - Cities which do not eat all the foods eaten in Munich
= πCity(σCity!='Munich'(Eats)) - πCity[πCity(Eats) X πFood(σCity='Munich'(Eats)) - πCity,Food(Eats)]
Get Answers For Free
Most questions answered within 1 hours.