Change expand to expand_end and move to binary_matrix_utilities.rb