I'm not sure what exactly your instructor wants you to understand by "state transition matrix". However, this sounds similar at least in purpose to a state diagram.
A state diagram shows states of a state machine, which transitions between states are possible, and what conditions cause those transitions. Usually the states are drawn as blobs and the transitions as arrows between the blobs. The blobs are labeled according to what it means to be in that state, and the arrows are labeled by the condition that causes that state transition. Each transition gets its own arrow, just like each state gets its own blob.
The purpose of such a diagram is to help design, clarify, and document a state machine. Once you have a good state diagram, writing the state machine code is usually pretty straight forward.
As a aside, I notice we are getting a unusually large number of homework questions here recently, all from people with names that suggest they are from India. Are you in a particular phase of the education cycle there now, like nearing end of term where projects are due, standard exams, or something like that? Why are so many students from India suddenly asking homework questions here?