Coq - 在Ssreflect中证明涉及bigops的严格不等式

时间:2017-05-23 11:46:48

标签: coq coq-tactic ssreflect

我试图使用数学组件库来证明以下内容:

Lemma bigsum_aux (i: 'I_q) (j: 'I_q) (F G : 'I_q -> R):
  (forall i0, F i0 <= G i0) /\ (exists j0, F j0 < G j0) ->
  \sum_(i < q) F i < \sum_(i < q) G i.

最初,我试图在bigsum_auxssralg的文档中找到与bigop相当的引理,但我找不到任何引理;所以这就是我迄今为止所能做到的:

Proof.
 move => [Hall Hex]. rewrite ltr_neqAle ler_sum; last first.
 - move => ? _. exact: Hall.
 - rewrite andbT. (* A: What now? *)

欢迎对相关引理的任何帮助或指示。

1 个答案:

答案 0 :(得分:2)

你想要在&#34;坏&#34;中分割总和。 (&lt;)部分,其余部分是微不足道的:

From mathcomp Require Import all_ssreflect all_algebra.

Set Implicit Arguments.
Unset Strict Implicit.
Unset Printing Implicit Defensive.

Open Scope ring_scope.
Import Num.Theory.

Lemma bigsum_aux (R : numDomainType) q (i: 'I_q) (j: 'I_q) (F G : 'I_q -> R)
      (hle : forall i0, F i0 <= G i0) z (hlt : F z < G z) :
  \sum_(i < q) F i < \sum_(i < q) G i.
Proof.
by rewrite [\sum__ F _](bigD1 z) ?[\sum__ G _](bigD1 z) ?ltr_le_add ?ler_sum.
Qed.