Schulze¶
-
class
svvamp.
Schulze
(population, **kwargs)[source]¶ Schulze method.
Inherits functions and optional parameters from superclasses
ElectionResult
andElection
.Example: >>> import svvamp >>> pop = svvamp.PopulationSpheroid(V=100, C=5) >>> election = svvamp.Schulze(pop)
scores
[c, d]
is equal to the width of the widest path from candidatec
to candidated
in the capacited graph defined bymatrix_duels_rk
. We say thatc
is better thand
ifscores[c, d]
>scores[d, c]
. Candidatec
is a potential winner if no candidated
is better thanc
.Among the potential winners, the candidate with lowest index is declared the winner.
Note
In the original Schulze method, ties are broken at random. However, this feature is not supported by SVVAMP because it leads to difficulties for the definition of manipulation itself (and all the more for its implementation).
CM()
:ICM()
: Exact in polynomial time.IM()
:not_IIA()
: Exact in polynomial time.TM()
: Exact in polynomial time.UM()
:References:
‘A new monotonic, clone-independent, reversal symmetric, and Condorcet-consistent single-winner election method ‘, Markus Schulze, 2011.
‘Schulze and Ranked-Pairs Voting are Fixed-Parameter Tractable to Bribe, Manipulate, and Control’, Lane A. Hemaspaandra, Rahman Lavaee and Curtis Menton, 2012.
‘Manipulation and Control Complexity of Schulze Voting’, Curtis Menton and Preetjot Singh, 2012.
‘A Complexity-of-Strategic-Behavior Comparison between Schulze’s Rule and Ranked Pairs’, David Parkes and Lirong Xia, 2012.
‘Coalitional Manipulation for Schulze’s Rule’, Serge Gaspers, Thomas Kalinowski, Nina Narodytska and Toby Walsh, 2013.
-
candidates_by_scores_best_to_worst
¶ 1d array of integers.
candidates_by_scores_best_to_worst[k]
is thek
th candidate by number of Schulze-victories, i.e. the number of candidatesd
such thatc
is better thand
.By definition,
candidates_by_scores_best_to_worst[0]
=w
.
-
scores
¶ 2d array of integers.
scores[c, d]
is equal to the width of the widest path fromc
tod
.Note
Unlike for most other voting systems,
scores
matrix must be read in rows, in order to comply with our convention for the matrix of duels:c
‘s score vector isscores[c, :]
.
-
scores_best_to_worst
¶ 2d array.
scores_best_to_worst
is the scores of the candidates, from the winner to the last candidate of the election.scores_best_to_worst[k, j]
is the width of the widest path from thek
th best candidate of the election to thej
th.
-
w
¶ Integer (winning candidate).
-