Odysseus burns an offering for the gods because there is an extra ram left over after the men have divided up the Cyclops's sheep among them, and because Odysseus hopes that the gods will heed his sacrifice and protect him and his crew on their way home.
When Odysseus and his men finally return to the island where they have left the rest of their ships, they divide the sheep they have stolen from the Cyclops among themselves, giving each man an equal share so that none would complain. There is an extra ram, and the men decide it should go to Odysseus; Odysseus sacrifices this ram on the shore to the god Zeus. Odysseus prays that Zeus, who is lord over all, will grant them his protection on their journey home, especially since Cyclops has prayed to his own father Poseidon to avenge him against Odysseus, who has stolen his flock and put out his eye. Unfortunately, Zeus does not heed Odysseus's sacrifice, only thinking how "he might destroy both (Odysseus's) ships and (his) comrades" (Book IX).
The sacrifice of the extra ram, in a way, represents the trust and respect that Odysseus's men have for him. It is also representative of the ill-fated journey, because even though Odysseus does right by sacrificing the sheep to Zeus, he still encounters many trials. In fact, by the end of the epic, all of his men have been killed in various ordeals.