<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def Gax(x, ax):
 """ Compute gradient of `x` along axis `ax`. Parameters x : array_like Input array ax : int Axis on which gradient is to be computed Returns ------- xg : ndarray Output array """


    slc = (slice(None),)*ax + (slice(-1, None),)
    xg = np.roll(x, -1, axis=ax) - x
    xg[slc] = 0.0
    return xg