diff options
| author | Greg Brown <greg.brown01@ed.ac.uk> | 2022-12-05 15:55:09 +0000 | 
|---|---|---|
| committer | Greg Brown <greg.brown01@ed.ac.uk> | 2022-12-05 15:55:09 +0000 | 
| commit | 332f481a61429c031016fd5d43238095d1a22075 (patch) | |
| tree | 7946554f7bbfe498674b2f5e7fcf456c8162fb0c /src/Soat/SecondOrder/Algebra | |
| parent | 1f378ce7d61e16a3dc805ce63f87b5b8202f3f8e (diff) | |
refactor : rename homomorphism combinators.
- idHomo -> id
- compHomo -> (.)
Diffstat (limited to 'src/Soat/SecondOrder/Algebra')
| -rw-r--r-- | src/Soat/SecondOrder/Algebra/Lift.idr | 24 | 
1 files changed, 12 insertions, 12 deletions
| diff --git a/src/Soat/SecondOrder/Algebra/Lift.idr b/src/Soat/SecondOrder/Algebra/Lift.idr index 9a88446..596bb24 100644 --- a/src/Soat/SecondOrder/Algebra/Lift.idr +++ b/src/Soat/SecondOrder/Algebra/Lift.idr @@ -141,14 +141,14 @@ InitialIsAlgebra sig = MkIsAlgebra      eq)    (\t, ctx, tm =>      tmRelSym (\_ => MkSymmetric symmetric) $ -    bindUnique (renameBodyFunc reflexive) idHomo (\i => Done' $ sym $ curryUncurry id i) $ +    bindUnique (renameBodyFunc reflexive) id (\i => Done' $ sym $ curryUncurry id i) $      tm)    (\t, f, g, tm =>      tmRelSym (\_ => MkSymmetric symmetric) $      bindUnique        {a = FreeAlgebra (isetoid (flip Elem _))}        (renameBodyFunc (transitive g f)) -      (compHomo (bindHomo (renameBodyFunc f)) (bindHomo (renameBodyFunc g))) +      (bindHomo (renameBodyFunc f) . bindHomo (renameBodyFunc g))        (\i => Done' $ sym $ curryUncurry (curry f . curry g) i) $      tm)    (\f, (MkOp (Op op)), tms => @@ -172,7 +172,7 @@ InitialIsAlgebra sig = MkIsAlgebra      bindUnique        {a = FreeAlgebra (isetoid (flip Elem _))}        (indexFunc _) -      (compHomo (bindHomo (renameBodyFunc f)) (bindHomo (indexFunc tms))) +      (bindHomo (renameBodyFunc f) . bindHomo (indexFunc tms))        (\i =>          tmRelReflexive (\_ => MkReflexive reflexive) $          sym $ @@ -182,7 +182,7 @@ InitialIsAlgebra sig = MkIsAlgebra      bindUnique        {a = FreeAlgebra (isetoid (flip Elem _))}        (indexFunc _) -      (compHomo (bindHomo (indexFunc tms)) (bindHomo (renameBodyFunc f))) +      (bindHomo (indexFunc tms) . bindHomo (renameBodyFunc f))        (\i =>          tmRelReflexive (\_ => MkReflexive reflexive) $          sym $ @@ -192,7 +192,7 @@ InitialIsAlgebra sig = MkIsAlgebra      bindUnique        {a = FreeAlgebra (isetoid (flip Elem _))}        (indexFunc _) -      (compHomo (bindHomo (indexFunc tms')) (bindHomo (indexFunc tms))) +      (bindHomo (indexFunc tms') . bindHomo (indexFunc tms))        (\i =>          tmRelReflexive (\_ => MkReflexive reflexive) $          sym $ @@ -204,7 +204,7 @@ InitialIsAlgebra sig = MkIsAlgebra      bindUnique        {a = FreeAlgebra (isetoid (flip Elem _))}        (indexFunc _) -      idHomo +      id        (\i =>          tmRelReflexive (\_ => MkReflexive reflexive) $          sym $ @@ -229,7 +229,7 @@ InitialIsAlgebra sig = MkIsAlgebra              (bindUnique                 {a = FreeAlgebra (isetoid (flip Elem _))}                 (renameBodyFunc _) -               idHomo +               id                 (\i =>                   Done' $                   sym $ @@ -269,8 +269,8 @@ fromInitialHomo a = MkHomomorphism    (\t, f => bindUnique'      {v = isetoid (flip Elem _)}      {a = projectAlgebra sig a _} -    (compHomo (bindHomo (a.varFunc _)) (bindHomo (renameBodyFunc f))) -    (compHomo (a.renameHomo f) (bindHomo (a.varFunc _))) +    (bindHomo (a.varFunc _) . bindHomo (renameBodyFunc f)) +    (a.renameHomo f . bindHomo (a.varFunc _))      (\i => (a.algebra.equivalence _).symmetric $ a.algebra.varNat f i))    (\ctx, (MkOp (Op op)), tms =>      a.algebra.semCong ctx (MkOp (Op op)) $ @@ -286,8 +286,8 @@ fromInitialHomo a = MkHomomorphism    (\t, ctx, tm, tms => bindUnique'      {v = isetoid (flip Elem _)}      {a = projectAlgebra sig a _} -    (compHomo (bindHomo (a.varFunc _)) (bindHomo (indexFunc tms))) -    (compHomo (a.substHomo1 ctx _) (bindHomo (a.varFunc _))) +    (bindHomo (a.varFunc _) . bindHomo (indexFunc tms)) +    (a.substHomo1 ctx _ . bindHomo (a.varFunc _))      (\i =>        (a.algebra.equivalence _).transitive          (bindUnique @@ -313,5 +313,5 @@ fromInitialUnique {sig = sig} {a = a} f t ctx = bindUnique    {v = isetoid (flip Elem _)}    {a = projectAlgebra sig a ctx}    (a.varFunc ctx) -  (compHomo (projectHomo f ctx) (freeToInitialHomo sig ctx)) +  (projectHomo f ctx . freeToInitialHomo sig ctx)    f.varHomo | 
