Example

> restart:f:=x->ln(cos(x));

[Maple Math]

> df:=D(f):ddf:=D(df):dddf:=D(ddf):ddddf:=D(dddf):dddddf:=D(ddddf);

[Maple Math]

> plot(dddddf,-1..1);

[Maple Plot]

So that the fifth derivative is bounded by 400.

>

> for i from 1 to 2 do h:=10.^(-i): df1:=1/(12*h)*(f(0.4-2*h)-8*f(0.4-h)+8*f(0.4+h)-f(0.4+2*h)): maxerr:=(h^4)*400./30:acterr:=abs(df1-df(0.4)): print(h,df1,maxerr,acterr); od:

[Maple Math]

[Maple Math]

Again, the increased accuracy is evident.