Content deleted Content added
No edit summary |
m →top: clean up spacing around commas and other punctuation fixes, replaced: ; → ; (8) |
||
(11 intermediate revisions by 10 users not shown) | |||
Line 1:
ReduceAndReconstruct is based on a set of local proof rewriting rules that transform a subproof into
A context
{{NumBlk|:|<math>\cfrac{\cfrac{\beta \qquad \gamma}{\delta} \, p \qquad \alpha}{\eta} \, q</math>|{{EquationRef|1}}}}
The table below shows the rewriting rules proposed by Simone ''et al
{| class="wikitable"
Line 14:
|-
| Case A1: <math>s \notin \alpha, t \in \gamma</math> ||
<math>\cfrac{\cfrac{stC \qquad \overline{s} tD}{tCD} \, \operatorname{var}(s) \qquad \overline{t} E}{CDE} \, \operatorname{var}(t) \Rightarrow
\cfrac{\cfrac{stC \qquad \overline{t} E}{sCE}\, \operatorname{var}(t) \qquad \cfrac{\overline{t} E \qquad \overline{s} tD}{\overline{s}DE}\, \operatorname{var}(t)}{CDE} \, \operatorname{var}(s)</math>
|-
| Case A2: <math>s \notin \alpha, t \notin \gamma</math> ||
<math>\cfrac{\cfrac{stC \qquad \overline{s} D}{tCD} \, \operatorname{var}(s) \qquad \overline{t} E}{CDE} \, \operatorname{var}(t) \Rightarrow
\cfrac{\cfrac{stC \qquad \overline{t} E}{sCE} \, \operatorname{var}(t) \qquad \overline{s} D}{CDE} \, \operatorname{var}(s)</math>
|-
| Case B1: <math>s \in \alpha, t \in \gamma</math> ||
<math>\cfrac{\cfrac{stC \qquad \overline{s}tD}{tCD} \, \operatorname{var}(s) \qquad s \overline{t} E}{sCDE} \, \operatorname{var}(t) \Rightarrow
\cfrac{stC \qquad s \overline{t} E}{sCE}\, \operatorname{var}(t)</math>
|-
| Case B2: <math>s \in \alpha, t \notin \gamma</math> ||
<math>\cfrac{\cfrac{stC \qquad \overline{s}D}{tDC} \, \operatorname{var}(s) \qquad s \overline{t} E}{sCDE} \, \operatorname{var}(t) \Rightarrow
\cfrac{\cfrac{stC \qquad s \overline{t} E}{sCE} \, \operatorname{var}(t) \qquad \overline{s} D}{CDE} \, \operatorname{var}(s)</math>
|-
| Case B3: <math>\overline{s} \in \alpha, t \notin \gamma</math> ||
<math>\cfrac{\cfrac{stC \qquad \overline{s}D}{tDC} \, \operatorname{var}(s) \qquad \overline{s} \overline{t} E}{\overline{s} CDE} \, \operatorname{var}(t) \Rightarrow
\overline{s} D</math>
|-
| Case A1' ||
<math>\cfrac{\cfrac{stC \qquad \overline{s} tD}{tCD} \, \operatorname{var}(s) \qquad \overline{t} E}{CDE} \, \operatorname{var}(t) \Leftarrow
\cfrac{\cfrac{stC \qquad \overline{t} E}{sCE}\, \operatorname{var}(t) \qquad \cfrac{\overline{t} E \qquad \overline{s} tD}{\overline{s}DE}\, \operatorname{var}(t)}{CDE} \, \operatorname{var}(s)</math>
|-
| Case B2': <math>t \notin \gamma </math> ||
<math>\cfrac{\cfrac{stC \qquad \overline{s} D}{tCD} \, \operatorname{var}(s) \qquad s \overline{t} E}{sCDE} \, \operatorname{var}(t) \Rightarrow
\cfrac{stC \qquad s \overline{t} E}{sCE}\, \operatorname{var}(t)</math>
|}
* Rule A2 does not perform any reduction on its own. However, it is still useful, because of its "shuffling" effect that can create new opportunities for applying the other rules;
* Rule A1 is not used in practice, because it may increase proof size;
* Rules B1, B2, B2' and B3 are directly
* The application of a B rule may lead to
The following example
{{NumBlk|:|
Line 63:
</math>|{{EquationRef|3}}}}
{{NumBlk|:|
Line 70:
</math>|{{EquationRef|4}}}}
1 '''function''' ReduceAndReconstruct(''<math>\pi</math>'' ''/* a proof */'', ''timelimit'', ''maxIterations''):
Line 82:
7 '''end function'''
<code>ReduceAndReconstruct</code> uses the function <code>ReduceAndReconstructLoop</code>, which is specified below.
1 '''function''' ReduceAndReconstructLoop(''<math>\pi</math>'' ''/* a proof */''):
Line 88:
3 '''for each''' node <math>n</math> '''in''' ''TS''
4 '''if''' <math>n</math> is not a leaf
5 '''if''' ''<math>n_\text{piv} \in n_\text{clause}^\text{left}</math> and <math>\overline{n_\text{piv}} \in n_\text{clause}^\text{right}</math>'' '''then'''
6 <math>n_\text{clause}</math> = Resolution(<math>n_\text{clause}^\text{left}</math>, <math>n_\text{clause}^\text{right}</math>);
7 Determine left context of <math>n</math>, if any;
8 Determine right context of <math>n</math>, if any;
9 Heuristically choose one context (if any) and apply the corresponding rule;
10 '''else if''' ''<math>n_\text{piv} \notin n_\text{clause}^\text{left}</math> and <math>\overline{n_\text{piv}} \in n_\text{clause}^\text{right}</math>'' '''then'''
11 Substitute <math>n</math> with <math>n^\text{left}</math>;
12 '''else if''' ''<math>n_\text{piv} \in n_\text{clause}^\text{left}</math> and <math>\overline{n_\text{piv}} \notin n_\text{clause}^\text{right}</math>'' '''then'''
13 Substitute <math>n</math> with <math>n^\text{right}</math>;
14 '''else if''' ''<math>n_\text{piv} \notin n_\text{clause}^\text{left}</math> and <math>\overline{n_\text{piv}} \notin n_\text{clause}^\text{right}</math>'' '''then'''
15 Heuristically choose an antecedent <math>n^\text{left}</math> or <math>n^\text{right}</math>;
16 Substitute <math>n</math> with <math>n^\text{left}</math> or <math>n^\text{right}</math>;
17 '''end for'''
18 '''end function'''
Experiments have shown that ReduceAndReconstruct alone has a worse compression/time ratio than the algorithm [[RecyclePivots]]
==Notes==
{{reflist}}
[[Category:Articles with example pseudocode]]
[[Category:Proof theory]]
|