fix lengths of distributions