
286 Foundations of Semantic Web Technologies
Filter((?price < 15),
Join(
LeftJoin(
Join(Z, BGP( ?book <http://example.org/price> ?price.)),
Join(Z, BGP( ?book <http://example.org/title> ?title.)),
true
), Union( Join(Z, BGP( ?book <http://example.org/author>
<http://example.org/Shakespeare>.)),
Join(Z, BGP( ?book <http://example.org/author>
<http://example.org/Marlowe>.) ))
)
)
One can simplify Join expressions that contain the empty expression Z as
one of their parameters by replacing them with their other parameters. This
is allowed since Z is the neutral element of the Join operation – similar to
the way in which 0 is the neutral element of ad dition.