This example checks whether the function derivative is implemented correctly. If the derivative implementation is not correct, the model will stop with an assert statement.