Require Import Vbase Relations ClassicalDescription ClassicalChoice.

Set Implicit Arguments.

Inductive fraction :=
  | pe_full
  | pe_half.

Definition fraction_plus x y :=
  match x, y with
    | pe_half, pe_halfSome pe_full
    | _, _None
  end.

Definition fraction_le x y :=
  x = y rem, fraction_plus x rem = Some y.

Lemma fraction_plusC x y : fraction_plus x y = fraction_plus y x.

Lemma fraction_plusA :
   x y xy (P1: fraction_plus x y = Some xy) z xyz
                (P2: fraction_plus xy z = Some xyz),
     yz, fraction_plus y z = Some yz fraction_plus x yz = Some xyz.

Lemma fraction_plus_full_l x : fraction_plus pe_full x = None.

Lemma fraction_plus_full_r x : fraction_plus x pe_full = None.

Lemma fraction_plusK1 x y : fraction_plus x y = Some x False.

Lemma fraction_plusK2 x y : fraction_plus x y = Some y False.

Lemma fraction_plusK x y z w :
  fraction_plus x y = Some w
  fraction_plus x z = Some w
  y = z.

fraction_le is a partial order
Other properties of fraction_le

This page has been generated by coqdoc