If the values of f(x) for different values of x is given, it is possible to determine if the function is linear or non-linear by calculating the average rate of change between any two values of f(x).
For x = x1 and x = x2, the average rate of change between x1 and x2 is `(f(x2) - f(x1))/(x2 - x1)`
If the function f(x) is linear the rate of change between any two points should be the same. If this is not the case the function is non linear.
For a linear function f(x), the average rate of change of f(x) between any two points is the same.