implemented create_matrix_spiral_form algorithm