<div dir="auto">Boo!</div><br><div class="gmail_quote gmail_quote_container"><div dir="ltr" class="gmail_attr">On Thu, 18 June 2026, 12:28 am Kristofer Munsterhjelm, <<a href="mailto:km-elmet@munsterhjelm.no">km-elmet@munsterhjelm.no</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">On 2026-06-02 23:11, Toby Pereira wrote:<br>
> I see yes, thanks. In that case, Schulze STV seems to do pretty <br>
> terribly, not just a bit worse than other STV methods. And looking at <br>
> your whole list, considerably worse than things like (Bloc) Borda! It's <br>
> definitely not broken in your simulation?<br>
<br>
I added some tests to Schulze STV and found an election where quadelect <br>
would return the wrong outcome.<br>
<br>
The bug appears to have been caused by undefined behavior in Schulze's <br>
own code, where a line does something that has no clear order of <br>
execution, and different compilers resolve the ambiguity differently. I <br>
tested Schulze's prog01 compiled with a modern gcc and got the same bug.<br>
<br>
After fixing the bug, I tested the example elections referenced in <br>
"Implementing the Schulze STV Method"[1], table 2, and the Schulze STV <br>
code used by my simulator now gives the correct outcome - i.e. the ones <br>
listed in the paper - for all of them.<br>
<br>
I then ran my multiwinner simulations and got much better results. <br>
Sorry, Etjon :-)<br>
<br>
Droop spatial proportionality:<br>
<br>
Two seats, 10 candidates, 14400 elections:<br>
<br>
Name Droop goodness-of-fit VSE<br>
Meek/Warren 0.7932<br>
Harmonic (S-L) 0.9254<br>
Schulze STV 0.9997<br>
<br>
Three seats:<br>
<br>
Warren 0.8712<br>
Meek 0.8713<br>
Harmonic (S-L) 0.8925<br>
Schulze STV 0.9992<br>
<br>
Four seats:<br>
<br>
Harmonic (S-L) 0.8880<br>
Warren 0.9184<br>
Meek 0.9185<br>
Schulze STV 0.9954<br>
<br>
Five seats:<br>
<br>
Harmonic (S-L) 0.8809<br>
Warren 0.9426<br>
Meek 0.9428<br>
Schulze STV 0.9874<br>
<br>
Six seats:<br>
<br>
Harmonic (S-L) 0.8779<br>
Meek 0.9598<br>
Warren 0.9598<br>
Schulze STV 0.9758<br>
<br>
Nine seats:<br>
<br>
Harmonic (S-L) 0.9450<br>
Schulze STV 0.9497<br>
Meek 0.9979<br>
Warren 0.9980<br>
<br>
<br>
The quantile fits for two out of ten are (288k elections):<br>
<br>
Name Prop. quantile Goodness-of-fit VSE<br>
Schulze STV 0.3377 0.9961<br>
Harmonic (S-L) 0.3498 0.9223<br>
Meek/Warren 0.3344 0.8090<br>
<br>
and for the 2-of-4 CFC-Kemeny comparison (5760 elections):<br>
<br>
Name Prop. quantile Goodness-of-fit VSE<br>
Harmonic (S-L) 0.3317 0.9414<br>
Meek/Warren 0.3321 0.9602<br>
Schulze STV 0.3345 0.9989<br>
CFC-Kemeny 0.2493 0.9998<br>
<br>
as well as 2-of-5 (7200 elections):<br>
<br>
Name Prop. quantile Goodness-of-fit VSE<br>
Meek/Warren 0.3346 0.9208<br>
Harmonic (S-L) 0.3383 0.9294<br>
CFC-Kemeny 0.2441 0.9967<br>
Schulze STV 0.3371 0.9967<br>
<br>
So Schulze STV seems to be pretty good, but its margin over other <br>
methods shrinks as seats/candidates ratio increases, to the point where <br>
Meek and Warren beats it with nine seats.<br>
<br>
Perhaps this has something to do with how Schulze STV's main calculation <br>
is on sets that differ by one candidate, that it then uses widest path <br>
to extrapolate; if there are more winners, such paths may have more <br>
steps. But I don't know for sure.<br>
<br>
I also found a few crash-inducing memory access bugs in Schulze's <br>
implementation, but the code is difficult enough to understand that I'm <br>
unsure how to fix them. I'll probably give more details in another post.<br>
<br>
-km<br>
<br>
[1] <br>
<a href="https://sites.math.duke.edu/~bray/Courses/49s/Additional%20Reading/Schulze/Schulze3/schulze3.pdf" rel="noreferrer noreferrer" target="_blank">https://sites.math.duke.edu/~bray/Courses/49s/Additional%20Reading/Schulze/Schulze3/schulze3.pdf</a><br>
</blockquote></div>