Thanks, Marco. The Brexit referendum question is only binary in legal terms (invoke article 50 or not) but it is not binary in terms of policy (how one would want to Remain or Leave). 17% put Remain between options of Leave, and voting then becomes guessing what kind of option for Leave would likely be happening.
(1) My discussion on UK preferences on Brexit and an application on voting rules is in the October Newsletter of the Royal Economic Society: http://www.res.org.uk/view/art2Oct17Features.html
A problem in the UK is that many who voted Remain now actually "respect" the referendum outcome, even though it can be shown that the referendum question was flawed in design, and would not be used in a proper statistical questionnaire. My suggestion is that the scientific community explains to the people what is amiss here.
(2) Subsequently, my diagnosis on Brexit is here: https://boycottholland.wordpress.com/2017/12/01/dealing-with-denial-cause-and-cure-of-brexit/
(3) The following might interest readers in the USA as well. My suggestion is to re-engineer "political science on electoral systems". My diagnosis is that the current approach in "political science on electoral systems" is actually still pre-science, belonging to the Humanities. See my paper: "One woman, one vote. Though not in the USA, UK and France" at: https://mpra.ub.uni-muenchen.de/82513/
(4) I fully agree that Mathematica is a wonderful environment to program and use voting routines. I wrote a whole book on single seat elections. See the online PDF though the software is not open access: https://zenodo.org/record/291985