Commit 3d8f8383 authored by mschaper's avatar mschaper
Browse files

comment on shift strategy

parent a3b4e8cf
......@@ -267,6 +267,11 @@ extractRanking body i c g f = do
<|> (logMsg "multiplicative" >> pure multiplicative)
rankFromBExp <-
(logMsg "optimistic" >> pure (ranksFromBExpWith optimistic))
-- MS: not a solution, but shift is not working as intended
-- before we could compare norms; now we have reduced expression
<|> (logMsg "optimistic2" >> pure (ranksFromBExpWith (optimistic' 2)))
<|> (logMsg "optimistic4" >> pure (ranksFromBExpWith (optimistic' 4)))
<|> (logMsg "optimistic8" >> pure (ranksFromBExpWith (optimistic' 8)))
<|> (logMsg "shift" >> pure (ranksFromBExpWith shift))
<|> (logMsg "squared-optimistic" >> pure (squared (ranksFromBExpWith optimistic)))
gRanks <- combine <$> rankFromBExp (i .&& c) <*> pure (rankFromCExp g)
......@@ -280,6 +285,7 @@ extractRanking body i c g f = do
multiplicative gs1 gs2 = [C.mulG g1 g2 | g1 <- gs1, g2 <- gs2]
optimistic (a :>=: b) = pure $ C.norm (a .>= b) (a - b + 1)
optimistic' i (a :>=: b) = pure $ C.norm (a .>= b) (a - b + i)
squared m x = do
gs <- m x
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment