Optimized Degree Distributions for Binary and Non