Game theory shows why political parties may gravitate to the centre in the quest for the median voter.