data Step : (a -> a -> Type) -> a -> a -> Type
data FastDerivation : (a -> a -> Type) -> a -> a -> Type
(|~) : (x : a) -> FastDerivation leq x x
(<~) : FastDerivation leq x y -> Step leq y z -> FastDerivation leq x z
data DerivationType : FastDerivation leq x y -> Type
TrivialDerivation : DerivationType ((|~) x)
SingleStepDerivation : DerivationType ((|~) x <~ step)
NonTrivialDerivation : DerivationType ((der <~ step1) <~ step2)
derivationType : (der : FastDerivation leq x y) -> DerivationType der
0 Prerequisite : DerivationType der -> Type
inductivePrerequisite : (der : FastDerivation leq x y) -> (0 step1 : Step leq y z) -> (0 step2 : Step leq z w) -> Prerequisite (derivationType ((der <~ step1) <~ step2)) -> Prerequisite (derivationType (der <~ step1))
preorderPrerequisite : Preorder dom leq => (der : FastDerivation leq x y) -> Prerequisite (derivationType der)
CalcSmart : (der : FastDerivation leq x y) -> Prerequisite (derivationType der) => leq x y
The Prerequisite for the derivation:
0-length derivation: Reflexive dom leq
1-length derivation: Unit (no prerequisite)
2 steps of longer: Transitivity
CalcWith : Preorder dom leq => FastDerivation leq x y -> leq x y
(~~) : FastDerivation leq x y -> (0 _ : Step Equal y z) -> FastDerivation leq x z
(..<) : Symmetric a leq => (y : a) -> leq y x -> Step leq x y
(..>) : (y : a) -> leq x y -> Step leq x y
(.=.) : Reflexive a leq => (y : a) -> x = y -> Step leq x y
(.=>) : Reflexive a leq => (y : a) -> x = y -> Step leq x y
(.=<) : Reflexive a leq => (y : a) -> y = x -> Step leq x y
(~=) : FastDerivation leq x y -> (0 z : dom) -> y = z => FastDerivation leq x z