In Oedipus Rex, what seems to be the function of each Ode in response to the preceding scene?
It is important to focus on how the Odes that the Chorus offers provide a commentary on the action that has just passed. They clearly provide a much wider insight and context into the action of the play as a whole, giving us an awareness of the "common man" of Thebes with his worries, preoccupations, superstitions and religious concerns. Therefore, in Ode 2, following Jocasta's denunciation of Oracles and the power of Gods to work in the lives of humans, the Chorus are sharply critical of her stance in this respect:
Haughtiness and the high hand of disdain
Tempt and outrage God's holy law;
And any mortal who dares hold
No immortal Power in awe
Will be caught up in a net of pain.
Clearly, the Chorus is shocked with the ease that Jocasta "disproves" the Oracle concerning Laius and the way she dismisses Oracles in general, and thus their comments act as an alternative commentary on the action in the play.
So, in order to proceed with your assignment I suggest that you examine each Ode carefully and consider how it comments upon, supports or contradicts views, characters and the action that immediately precede it. Good luck!