# Question:How do I reduce this in Maple?

## Question:How do I reduce this in Maple?

Maple 2016

Good day. Please can someone kindly help to reduce the result of this code. Thank you and kind regards

```restart:
s:=(sum(a[j]*x^j,j=0..3)+sum(a[j]*exp(-(j-3)*x),j=4..7)):
F:=diff(s,x):
p1:=simplify(eval(s,x=q))=y[n]:
p2:=simplify(eval(F,x=q))=f[n]:
p3:=simplify(eval(F,x=q+h/3))=f[n+1/3]:
p4:=simplify(eval(F,x=q+h))=f[n+1]:
p5:=simplify(eval(F,x=q+5*h/3))=f[n+5/3]:
p6:=simplify(eval(F,x=q+2*h))=f[n+2]:
p7:=simplify(eval(F,x=q+7*h/3))=f[n+7/3]:
p8:=simplify(eval(F,x=q+3*h))=f[n+3]:

vars:= seq(a[i],i=0..7):
Cc:=eval(<vars>, solve({p||(1..8)}, {vars})):
for i from 1 to 8 do
a[i-1]:=Cc[i]:
end do:
Cf:=s:
L:=collect(simplify(simplify(expand(eval(Cf,x=q+3*h)),size)), [y[n],f[n],f[n+1/3],f[n+1],f[n+5/3],f[n+2],f[n+7/3],f[n+3]], factor):
length(L);
H := ee -> collect(numer(ee),[exp],h->simplify(simplify(h),size))/collect(denom(ee),[exp],h->simplify(simplify(h),size)):
M:=y[n+3]=(H@expand)(L);
length(M);```

﻿