well let us say f = g(ax +- bt)
df/dx = a . (dg/dx)
d2f/dx2(second derivative) = a^2 . (d2g/dx2)
similarly,
d2f/dt2 = -+ b^2 . (d2g/dt2)
which clearly points to the differential eqn. of a wave.
only see that :
1: it is differentiable at every point
2: it is continuous at all points
3: it is defined at all points
this is all necessary for double differentiating.
i hope i have cleared your doubts.