matlab add value to array in loop