Lucas - what errors are you observing? Please copy and paste the full error message to your question. Do you need to use the Symbolic Toolbox? Can't you define df as just
df = @(x)2*x;
Note how your code isn't using epsilon. How are you supposed to be using this value?
