Description |
APPORT Political Apportionment
SEATS = APPORT(VOTES,NUM,METHOD) takes the array of VOTES for each member and allocates seats according to METHOD until NUM seats have been allocated.
APPORT(...,MINSEATS) pre-allocates MINSEATS to each member first, guaranteeing that each member has at least MINSEATS number of SEATS. MINSEATS can either be a vector, with length equal to the number of members, or a scalar which is the same for all members. (Default is 0)
If either NUM or METHOD is multivalued it will enumerate all combinations within those parameters. An error will be given if both are multivalued.
Below is a list of available methods. METHOD can either be written out in full ('Greatest Divisor') or in abbreviated form ('GD'). Also listed are common names for the same method.
Methods available:
------------------
Greatest Divisor : d'Hondt; Jefferson; Highest Average
Smallest Divisor : Adams
Equal Proportions : Huntington; Hill; Geometric Mean
Harmonic Mean : Dean
Major Fractions : Sainte-Lague; Webster; Arithmetic Mean; Odd Numbers
Largest Remainders : Vinton; Hamilton; Hare
Abbreviated form:
-----------------
ALL : All six unique methods
A : Adams
AM : Arithmetic Mean
D : Dean
DH : d'Hont
EP : Equal Proportions
GD : Greatest Divisor
GM : Geometric Mean
HH : Huntington OR Hill (equivalent)
HA : Highest Average
HAM : Hamilton OR Hare (equivalent)
HM : Harmonic Mean
J : Jefferson
LR : Largest Remainders
MF : Major Fractions
ON : Odd Numbers
SD : Smallest Divisor
SL : Sainte-Lague
V : Vinton
W : Webster
EXAMPLE 1
Allocate 80 seats among four parties with votes of [100 80 30 20], with minimum of 3 seats each. Compare all methods.
apport([100 80 30 20],80,'All',3)
EXAMPLE 2
Compare method of Greatest Divisor with the method of Smallest Divisor of allocating 15 seats among four parties with votes of [104 62; 34 55]
apport([104 62; 34 55],15,{'GD','SD'})
EXAMPLE 3
'Alabama Paradox'
"increasing the total number of items would decrease one of the shares"
apport([2 6 6],10:13,'Hamilton')
Notice first party decreased representation from 2 to 1, even with an increase in total number of shares
EXAMPLE 4
'New states paradox'
"it is possible for an existing state to get more representatives than if the new state were not added"
apport([27 39 68 ],23,'Largest Remainders')
apport([27 39 68 6],23,'Largest Remainders')
Notice first state increased representation from 4 to 5, at the expense of one of the other two original states |