The United States and Iran have offered sharply different accounts of the sinking of an Iranian warship in the Indian Ocean.