hjugement-2.0.2.20190414: Majority Judgment.

Majority.Gauge

Description

WARNING: the MajorityGauge is a simplified MajorityValue which is sufficient to determine the MajorityRanking when the number of judges is large. It is an approximation, it can perfectly lead to a wrong ranking wrt. the MajorityRanking done by using majorityValue.

Synopsis

# Type MajorityGauge

data MajorityGauge g Source #

The MajorityGauge is a simplification of the majorityValue from which may be deduced the majorityRanking among the propositions in many cases; in particular, when there are many judges.

However, when two propositions are tied with the same MajorityGauge, they are not necessarily tied according to their majorityValues.

Constructors

 MajorityGauge FieldsmgLower :: ShareNumber of grades given which are worse than mgGrade.mgGrade :: gmajorityGrade.mgHigher :: ShareNumber of grades given which are better than mgGrade.
Instances
 Eq g => Eq (MajorityGauge g) Source # Instance detailsDefined in Majority.Gauge Methods(==) :: MajorityGauge g -> MajorityGauge g -> Bool #(/=) :: MajorityGauge g -> MajorityGauge g -> Bool # Ord g => Ord (MajorityGauge g) Source # The MajorityGauge-ranking, first tries to rank according to the majorityGrade mgGrade.If both MajorityGauges have the same mgGrade, it tries to rank according to the mgSign of both MajorityGauges: a Plus is ahead of a Minus.If both mgSign are Plus, the one having the higher mgHigher is ahead, or if both mgSign are Minus, the one having the higher mgLower is behind.Otherwise, the MajorityGauge-ranking is a tie. Instance detailsDefined in Majority.Gauge Methods(<) :: MajorityGauge g -> MajorityGauge g -> Bool #(<=) :: MajorityGauge g -> MajorityGauge g -> Bool #(>) :: MajorityGauge g -> MajorityGauge g -> Bool #(>=) :: MajorityGauge g -> MajorityGauge g -> Bool #max :: MajorityGauge g -> MajorityGauge g -> MajorityGauge g #min :: MajorityGauge g -> MajorityGauge g -> MajorityGauge g # Show g => Show (MajorityGauge g) Source # Instance detailsDefined in Majority.Gauge MethodsshowsPrec :: Int -> MajorityGauge g -> ShowS #show :: MajorityGauge g -> String #showList :: [MajorityGauge g] -> ShowS #

## Type Sign

data Sign Source #

Constructors

 Minus Plus
Instances
 Source # Instance detailsDefined in Majority.Gauge Methods(==) :: Sign -> Sign -> Bool #(/=) :: Sign -> Sign -> Bool # Source # Instance detailsDefined in Majority.Gauge MethodsshowsPrec :: Int -> Sign -> ShowS #show :: Sign -> String #showList :: [Sign] -> ShowS #

If mgHigher is higher than mgLower then the majorityGrade is completed by a Plus; otherwise the majorityGrade is completed by a Minus.

This indicates the side of the next majorityGrade which is different than the current one: Minus when it is lower and Plus otherwise.