-
Notifications
You must be signed in to change notification settings - Fork 2
improves definitions of all algebra operators that involve expressions #291
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Conversation
<p>Let <var>Ω<sub>1</sub></var> and <var>Ω<sub>2</sub></var> be multisets of solution mappings, | ||
<var>expr</var> be an <a href="#expressions">expression</a>, | ||
|D| be a <a href="#sparqlDataset">dataset</a>, | ||
and |G| be the <a href="#defn_ActiveGraph">active graph</a>. | ||
We define:</p> | ||
<p><a href="#defn_algDiff" class="algFct">Diff</a>(<var>Ω<sub>1</sub></var>, <var>Ω<sub>2</sub></var>, <var>expr</var>, |D|, |G|) = { <var>μ</var> | <var>μ</var> in <var>Ω<sub>1</sub></var> such that ∀ <var>μ'</var> in | ||
<var>Ω<sub>2</sub></var>, either i) <var>μ</var> and <var>μ'</var> are not <a href="#defn_algCompatibleMapping">compatible</a>, | ||
or | ||
ii) <var>μ</var> and <var>μ'</var> are <a href="#defn_algCompatibleMapping">compatible</a> and | ||
|expr|(merge(<var>μ</var>, <var>μ'</var>), |D|, |G|) is an [=error=], | ||
or | ||
iii) <var>μ</var> and <var>μ'</var> are <a href="#defn_algCompatibleMapping">compatible</a> and | ||
|expr|(merge(<var>μ</var>, <var>μ'</var>), |D|, |G|) is an RDF term |t| for which | ||
<a href="#func-ebv">EBV</a>(|t|) is not `"true"^^xsd:boolean` }</p> | ||
<p><a href="#defn_Multiplicity">multiplicity</a>( <var>μ</var> | <a href="#defn_algDiff" class="algFct">Diff</a>(<var>Ω<sub>1</sub></var>, <var>Ω<sub>2</sub></var>, <var>expr</var>, |D|, |G|) ) = | ||
<a href="#defn_Multiplicity">multiplicity</a>( <var>μ</var> | <var>Ω<sub>1</sub></var> )</p> | ||
<p> | ||
where, for every solution mapping <var>μ</var>, | ||
|expr|(<var>μ</var>, |D|, |G|) is the result of | ||
<a href="#expression-evaluation">evaluating</a> expression |expr| | ||
with respect to <var>μ</var>, in the context of dataset |D| with active graph |G|. | ||
</p> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It seems likely that this section (and likely others I'm not seeing right now) will benefit from HTML markup that delivers to the spec reader something like the subparagraphs which have been produced within the HTML markup. Perfect world, the lowercase Roman numerals could be reproduced in an ordered list, but these would be OK as a unordered list (to which I would suggest it be changed if there's no importance to the i/ii/iii) following the either
(which I would suggest be changed to one of the following
).
This is a rough suggestion (I have no HTML preview, at present), and it may itself need substantial change, if not a full rewrite, before merging.
<p>Let <var>Ω<sub>1</sub></var> and <var>Ω<sub>2</sub></var> be multisets of solution mappings, | |
<var>expr</var> be an <a href="#expressions">expression</a>, | |
|D| be a <a href="#sparqlDataset">dataset</a>, | |
and |G| be the <a href="#defn_ActiveGraph">active graph</a>. | |
We define:</p> | |
<p><a href="#defn_algDiff" class="algFct">Diff</a>(<var>Ω<sub>1</sub></var>, <var>Ω<sub>2</sub></var>, <var>expr</var>, |D|, |G|) = { <var>μ</var> | <var>μ</var> in <var>Ω<sub>1</sub></var> such that ∀ <var>μ'</var> in | |
<var>Ω<sub>2</sub></var>, either i) <var>μ</var> and <var>μ'</var> are not <a href="#defn_algCompatibleMapping">compatible</a>, | |
or | |
ii) <var>μ</var> and <var>μ'</var> are <a href="#defn_algCompatibleMapping">compatible</a> and | |
|expr|(merge(<var>μ</var>, <var>μ'</var>), |D|, |G|) is an [=error=], | |
or | |
iii) <var>μ</var> and <var>μ'</var> are <a href="#defn_algCompatibleMapping">compatible</a> and | |
|expr|(merge(<var>μ</var>, <var>μ'</var>), |D|, |G|) is an RDF term |t| for which | |
<a href="#func-ebv">EBV</a>(|t|) is not `"true"^^xsd:boolean` }</p> | |
<p><a href="#defn_Multiplicity">multiplicity</a>( <var>μ</var> | <a href="#defn_algDiff" class="algFct">Diff</a>(<var>Ω<sub>1</sub></var>, <var>Ω<sub>2</sub></var>, <var>expr</var>, |D|, |G|) ) = | |
<a href="#defn_Multiplicity">multiplicity</a>( <var>μ</var> | <var>Ω<sub>1</sub></var> )</p> | |
<p> | |
where, for every solution mapping <var>μ</var>, | |
|expr|(<var>μ</var>, |D|, |G|) is the result of | |
<a href="#expression-evaluation">evaluating</a> expression |expr| | |
with respect to <var>μ</var>, in the context of dataset |D| with active graph |G|. | |
</p> | |
<p>Let <var>Ω<sub>1</sub></var> and <var>Ω<sub>2</sub></var> | |
be multisets of solution mappings, | |
<var>expr</var> be an <a href="#expressions">expression</a>, | |
|D| be a <a href="#sparqlDataset">dataset</a>, | |
and |G| be the <a href="#defn_ActiveGraph">active graph</a>. | |
We define the following:</p> | |
<ul> | |
<li><a href="#defn_algDiff" | |
class="algFct">Diff</a>(<var>Ω<sub>1</sub></var>, | |
<var>Ω<sub>2</sub></var>, <var>expr</var>, |D|, |G|) = | |
{ <var>μ</var> | <var>μ</var> in <var>Ω<sub>1</sub></var> | |
such that ∀ <var>μ'</var> in | |
<var>Ω<sub>2</sub></var>, either of the following | |
<ol type="i"> | |
<li><var>μ</var> and <var>μ'</var> are not | |
<a href="#defn_algCompatibleMapping">compatible</a></li> | |
<li><var>μ</var> and <var>μ'</var> are | |
<a href="#defn_algCompatibleMapping">compatible</a> and | |
|expr|(merge(<var>μ</var>, <var>μ'</var>), |D|, |G|) | |
is an [=error=]</li> | |
<li><var>μ</var> and <var>μ'</var> are | |
<a href="#defn_algCompatibleMapping">compatible</a> </li> | |
</ol> | |
<p>and |expr|(merge(<var>μ</var>, <var>μ'</var>), |D|, |G|) | |
is an RDF term |t| for which | |
<a href="#func-ebv">EBV</a>(|t|) | |
is not `"true"^^xsd:boolean` }</p></li> | |
<li><a href="#defn_Multiplicity">multiplicity</a>( <var>μ</var> | <a href="#defn_algDiff" class="algFct">Diff</a>(<var>Ω<sub>1</sub></var>, <var>Ω<sub>2</sub></var>, <var>expr</var>, |D|, |G|) ) = | |
<a href="#defn_Multiplicity">multiplicity</a>( <var>μ</var> | <var>Ω<sub>1</sub></var> )</li></ul> | |
<p> | |
where, for every solution mapping <var>μ</var>, | |
|expr|(<var>μ</var>, |D|, |G|) is the result of | |
<a href="#expression-evaluation">evaluating</a> expression |expr| | |
with respect to <var>μ</var>, in the context of dataset |D| with active graph |G|. | |
</p> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Good idea. I have implemented it in commit 0c316c4
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Great! Similar should be applied to the other blocks that are similarly prettified as HTML, without prettifying their rendering in the browser.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Great! Similar should be applied to the other blocks that are similarly prettified as HTML, without prettifying their rendering in the browser.
There are no other such blocks within the scope of this PR (whose purpose is to fix issues in the formalization of algebra operators that involve expressions).
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I did look before posting the above ... but apparently I was hallucinating at the time. Sorry!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
No worries Ted.
So, you are okay now with this PR?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes. Merge away. :-)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Co-authored-by: Ted Thibodeau Jr <tthibodeau@openlinksw.com>
This PR addresses #254
Preview | Diff