Scientists have solved the mystery of the strange rock on Mars that suddenly appeared next to the Opportunity rover.