state_vars = list(var("H, P, G"))
n = 12
system = (
1/(1 + G^n) - 0.2*H,
H - 0.2*P,
P - 0.2*G,
)
field(H, P, G) = system
initial_state = (0.5, 1, 1)
t_range = srange(0, 200, 0.05)
solution = desolve_odeint(field, initial_state, t_range, state_vars)
solution = np.insert(solution, 0, t_range, axis=1)
p = list_plot(solution[:,(0,1)], plotjoined=True, color="blue", legend_label="$H$")
p += list_plot(solution[:,(0,2)], plotjoined=True, color="red", legend_label="$P$")
p += list_plot(solution[:,(0,3)], plotjoined=True, color="gold", legend_label="$G$")
p.show(ymin=0, ymax=5, axes_labels=("$t$", "State variables"))