Implementing Schulze STV
Thus far, my implementation of Schulze STV has worked fairly well. The downside I’ve recently run into is in simulating real world multiple winner elections. Take Vancouver’s 2008 municipal election as an example, in which 32 candidates ran for 10 seats. The problem-space we’re looking at consists of 32 choose 10 nodes and (32 choose 10) x 11 edges. For those unfamiliar with binomial coefficients, that’s roughly 64 million nodes and 709 million edges. Exponential runtime is a bitch.
For the purposes of heuristic development, let’s look at Tideman’s A03. It’s a set of 989 ballots to elect 7 winners from 15 candidates. Schulze STV computes the winning set as B/D/E/F/H/K/N by looking at 6435 nodes and 51480 edges. How do we best prune the number of candidates down so as to look at a smaller subset, yet still produce the same winning set in most cases? Well, what’s quickly available? We can easily calculate the sum of all votes, standard deviation, and whatnot.

If we wanted to prune off the least preferred by sum (indicated by larger sums), we’d be cutting off one of a winner Schulze STV would want to elect. Alternatively, let’s look at the number of voters that mark each candidate in first place. If a voter marks two candidates in first place, split their vote between the two.

That heuristic seems great at first as it didn’t accidentally eliminate winning candidates and it reduced the number of nodes to 120, a 98% reduction in problem space size. However, the winning set would now be computed by SchulzeSTV as A/B/D/E/G/L/N, which is significantly different. Furthermore, the heuristic is going to incentivize tactical voting. Sometimes there aren’t any easy shortcuts and the best thing to do is just optimize the implementation.
3 Responses to “Implementing Schulze STV”
Leave a Reply
Markus Schulze on January 26th, 2010
The winners of the Schulze STV method are almost always identical to the first candidates of the Schulze proportional ranking. Therefore, when the number of seats M is large, it makes sense to recommend that the Schulze proportional ranking should be calculated and that the first M candidates of this ranking should be elected.
Actually, here in Germany, I promote the Schulze proportional ranking method rather than the Schulze STV method. The reason: In Germany, house monotonicity is considered very important; and proportional ranking methods are house monotonic while STV methods are not house monotonic.
See:
http://en.wikipedia.org/wiki/Apportionment_paradox
Brad Beattie on January 26th, 2010
In practice, how many seats do you find are necessary for the results to match up in most cases? German parliament is something around 600+, but I start to notice a slowness when M>5.
Markus Schulze on January 26th, 2010
Here in Germany, I promote districts with 8-13 seats each, plus a proportional compensation on the national level.
See:
http://home.versanet.de/~chris1-schulze/schulze4.pdf
http://home.versanet.de/~chris1-schulze/schulze5.pdf