GTG consists finite number of states, at least one of which is start state and some (maybe none) final states.Informally a generalized transition graph is a collection of three things are as follows A finite set, δ of transitions, (directed edge labels) (u, s, v), where u, v ∈ Q and s is a regular expression over Σ.Īlso check: Bellman ford algorithm in data structure.F : A set of final or accepting states F ⊆.S : A non-empty set set of start states, S ⊆.