No title

1
2
3
4
5
6
7
8
9
-- | Determine the most relevant cause-effect relationship.
--
-- >>> makeSummary [789, 621, 109, 65, 45, 30, 27, 15, 12, 9]
makeSummary values = fromMaybe fallback best
  where
    relations = makeRelations values
    relevant  = getRelevant $ getMajors relations
    best      = pickBest relevant -- pickBest :: [(Rational, Rational, Rational)] -> Maybe (Rational, Rational, Rational)
    fallback  = gcdFrac relations