We can find the average rate of change with the following formula

Which is defined inside the interval

In other words, this formula allows us to calculate the average rate of change inside the interval [a,b], which in this case is [4,7].
First, we find f(a) and f(b):

Now, we use the formula

Therefore, the average rate of change of f(x) from x=4 to x=7 is 3.