Maplet Overriding in Goal: Difference between revisions

From Event-B
Jump to navigationJump to search
imported>Billaude
imported>Laurent
mNo edit summary
 
(One intermediate revision by one other user not shown)
Line 178: Line 178:




[[Category:Design proposal]]
[[Category:Design]]

Latest revision as of 16:05, 18 March 2014

This page describes the design of a tactic requested here : Feature Request #3306228

Objective

Split every goal in the form : f\ovl{\{x\mapsto y\}}\in A\;op_1\;B into two sub-goals if and only if the sequent contains a hypothesis such as f\in A\;op_2\;B :

  • x\in A
  • y\in B

Where op_1 denote either a Relation \left(\rel\right), or a Total Relation \left(\trel\right), or a Partial Function \left(\pfun\right), or a Total Function \left(\tfun\right), and op_2 is such as f\in A\;op_2\;B\limp f\in A\;op_1\;B.

Design Decision

Those two subgoals and the predicate are not equivalent to the goal. Indeed, in the case op_1 is a Relation, the goal is equivalent to \{x\}\domsub f\in A\setminus\{x\}\rel B\land x\in A\land y\in B. But this has the drawback of writing three times the expression x. If this expression is big, then it can make the proof rule hard to read.

But, we know that \left(f\in A\;op_1\;B\right)\limp \left(\{x\}\domsub f\in A\setminus\{x\}\;op_1\;B\right) for all the relation given in Objective. By ensuring that f\in A\;op_2\;B is among the hypotheses of the sequent, we ensure that the first predicate of the conjunction is provable. Indeed, if this check was not done, the proof obligation may be unprovable since there are a loss of informations by writing f\in A\;op_2\;B instead of \{x\}\domsub f\in A\setminus\{x\}\;op_1\;B.

Table

f\in A\;op_2\;B\limp f\in A\;op_1 B
op_1\;\backslash\;op_2 \rel \trel \srel \strel \pfun \tfun \pinj \tinj \psur \tsur \tbij
\rel \checkmark \checkmark \checkmark \checkmark \checkmark \checkmark \checkmark \checkmark \checkmark \checkmark \checkmark
\trel - \checkmark - \checkmark - \checkmark - \checkmark - \checkmark \checkmark
\srel - - \checkmark \checkmark - - - - \checkmark \checkmark \checkmark
\strel - - - \checkmark - - - - - \checkmark \checkmark
\pfun - - - - \checkmark \checkmark \checkmark \checkmark \checkmark \checkmark \checkmark
\tfun - - - - - \checkmark - \checkmark - \checkmark \checkmark
\pinj - - - - - - \checkmark \checkmark - - \checkmark
\tinj - - - - - - - \checkmark - - \checkmark
\psur - - - - - - - - \checkmark \checkmark \checkmark
\tsur - - - - - - - - - \checkmark \checkmark
\tbij - - - - - - - - - - \checkmark