# Maplet Overriding in Goal

(Redirected from Mapplet Overriding in Goal)

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

$\rel$ $\trel$ $\srel$ $\strel$ $\pfun$ $\tfun$ $\pinj$ $\tinj$ $\psur$ $\tsur$ $\tbij$ $op_1\;\backslash\;op_2$ $\checkmark$ $\checkmark$ $\checkmark$ $\checkmark$ $\checkmark$ $\checkmark$ $\checkmark$ $\checkmark$ $\checkmark$ $\checkmark$ $\checkmark$ $-$ $\checkmark$ $-$ $\checkmark$ $-$ $\checkmark$ $-$ $\checkmark$ $-$ $\checkmark$ $\checkmark$ $-$ $-$ $\checkmark$ $\checkmark$ $-$ $-$ $-$ $-$ $\checkmark$ $\checkmark$ $\checkmark$ $-$ $-$ $-$ $\checkmark$ $-$ $-$ $-$ $-$ $-$ $\checkmark$ $\checkmark$ $-$ $-$ $-$ $-$ $\checkmark$ $\checkmark$ $\checkmark$ $\checkmark$ $\checkmark$ $\checkmark$ $\checkmark$ $-$ $-$ $-$ $-$ $-$ $\checkmark$ $-$ $\checkmark$ $-$ $\checkmark$ $\checkmark$ $-$ $-$ $-$ $-$ $-$ $-$ $\checkmark$ $\checkmark$ $-$ $-$ $\checkmark$ $-$ $-$ $-$ $-$ $-$ $-$ $-$ $\checkmark$ $-$ $-$ $\checkmark$ $-$ $-$ $-$ $-$ $-$ $-$ $-$ $-$ $\checkmark$ $\checkmark$ $\checkmark$ $-$ $-$ $-$ $-$ $-$ $-$ $-$ $-$ $-$ $\checkmark$ $\checkmark$ $-$ $-$ $-$ $-$ $-$ $-$ $-$ $-$ $-$ $-$ $\checkmark$