Changeset 2670 for src/common/FEMeasurable.ma
 Timestamp:
 Feb 15, 2013, 11:27:59 AM (7 years ago)
 File:

 1 edited
Legend:
 Unmodified
 Added
 Removed

src/common/FEMeasurable.ma
r2669 r2670 78 78 79 79 (* TODO: obs eq *) 80 81 definition trace_starts : ∀S. execution S io_out io_in → S → Prop ≝82 λS,t,s. match t with [ e_step _ s' _ ⇒ s = s'  _ ⇒ False ].83 84 (* TODO: too many of these lemmas, slim it down*)85 86 lemma split_trace_S : ∀fx:trans_system io_out io_in. ∀g,tr,s,n,a,b.87 split_trace … (exec_inf_aux ?? fx g (Value … 〈tr,s〉)) (S n) = Some ? 〈a,b〉 →88 ∃a'. a = 〈tr,s〉::a' ∧89 ((is_final … fx g s = None ? ∧ split_trace … (exec_inf_aux ?? fx g (step … fx g s)) n = Some ? 〈a',b〉) ∨90 (∃r. is_final … fx g s = Some ? r ∧ n = 0 ∧ a' = [ ] ∧ b = e_stop … tr r s)).91 #fx #g #tr #s #n #a #b92 >exec_inf_aux_unfold whd in ⊢ (??(????%?)? → ?);93 cases (is_final … s)94 [ whd in ⊢ (??%? → ?); cases (split_trace ?????)95 [ #E whd in E:(??%%); destruct96  * #a' #b' #E whd in E:(??%%); destruct97 %{a'} %{(refl ??)} %1 %{(refl ??)} %98 ]99  #r cases n [2:#n'] whd in ⊢ (??%? → ?); #E destruct100 %{[ ]} %{(refl ??)} %2 %{r} /4/101 ] qed.102 103 lemma split_trace_S' : ∀fx:trans_system io_out io_in. ∀g,s,n,a,b.104 split_trace … (exec_inf_aux ?? fx g (step … fx g s)) (S n) = Some ? 〈a,b〉 →105 ∃tr,s'. step … fx g s = Value … 〈tr,s'〉 ∧106 ∃a'. a = 〈tr,s'〉::a' ∧107 ((is_final … fx g s' = None ? ∧ split_trace … (exec_inf_aux ?? fx g (step … fx g s')) n = Some ? 〈a',b〉) ∨108 (∃r. is_final … fx g s' = Some ? r ∧ n = 0 ∧ a' = [ ] ∧ b = e_stop … tr r s')).109 #fx #g #s #n #a #b110 cases (step … fx g s)111 [ #o #i whd in ⊢ (??%? → ?); #E destruct112  * #tr #s' #split %{tr} %{s'} %{(refl …)} @split_trace_S @split113  #err #E whd in E:(??%%); destruct114 ] qed.115 116 lemma split_trace_1 : ∀fx:trans_system io_out io_in. ∀g,tr,s,a,b.117 split_trace … (exec_inf_aux ?? fx g (Value … 〈tr,s〉)) 1 = Some ? 〈a,b〉 →118 a = [〈tr,s〉] ∧119 ((is_final … fx g s = None ? ∧ b = exec_inf_aux ?? fx g (step … fx g s)) ∨120 (∃r. is_final … fx g s = Some ? r ∧ b = e_stop … tr r s)).121 #fx #g #tr #s #a #b #split122 cases (split_trace_S … split)123 #a' * #E1 *124 [ * #notfinal #split' whd in split':(??%?); destruct %{(refl ??)}125 %1 %{notfinal} %126  * #r * * * #final #_ #E2 #E3 destruct %{(refl ??)}127 %2 %{r} %{final} %128 ] qed.129 130 131 lemma split_trace_SS : ∀fx:trans_system io_out io_in. ∀g,tr,s,n,a,b.132 split_trace … (exec_inf_aux ?? fx g (Value … 〈tr,s〉)) (S (S n)) = Some ? 〈a,b〉 →133 ∃a'. a = 〈tr,s〉::a' ∧134 is_final … fx g s = None ? ∧135 ∃tr',s'. step … fx g s = Value … 〈tr',s'〉 ∧136 split_trace … (exec_inf_aux ?? fx g (Value … 〈tr',s'〉)) (S n) = Some ? 〈a',b〉.137 #fx #g #tr #s #n #a #b #splitSS138 cases (split_trace_S … splitSS)139 #a' * #E1 *140 [ * #notfinal #splitS %{a'} % [ %{E1} @notfinal ]141 cases (step … s) in splitS ⊢ %;142 [ #o #i #E whd in E:(??%%); destruct143  * #tr' #s' #splitS %{tr'} %{s'} %{(refl ??)} @splitS144  #m #E whd in E:(??%%); destruct145 ]146  * #r * * * #final #En #Ea #Eb destruct147 ] qed.148 80 149 81 lemma stack_normal_step : ∀C:preclassified_system. ∀g,s1,trace,s2,stack,current. … … 344 276 measurable (ms_C1 MS) p1 m n stack_cost max → 345 277 ∃m',n'. measurable (ms_C2 MS) p2 m' n' stack_cost max. 346 * #C1 #C2 #compiled #inv #rel #sim_normal #sim_call_return #sim_cost #sim_init 347 #p1 #p2 #m #n #stack_cost #max #compiled 348 whd in ⊢ (% → ?); letin C1' ≝ (mk_classified_system C1 ????) letin g1 ≝ (make_global ?? C1 ?) 349 * #prefix * #suffix * #subtrace * #remainder 350 * * * * #split1 #split2 #subtrace_ok #terminates #max_ok 351 352 *) 278
Note: See TracChangeset
for help on using the changeset viewer.