G is a vector of length nr_of_states