> ... how would I walk an expression to find the integrate and diff
operators ?
Try this:
====================
F(f):=block(
[E,r:[]],
local(S),
S(E):=block([e],
if string(op(E))="diff" then r:endcons(part(E,1),r),
for e in E do
if not atom(e) then S(e)
),
S(f),
r
)$
F('diff(3*f-2*h,x,3)*'diff(f*'diff(x*h,x),x,2));
=> [3*f-2*h,f*('diff((h*x),x,1)),h*x]