first distribution assumed to be higher now, some debug code added