Remove optional from distribution algorithm, Close #7.