# diff2 is intended to take partial derivatves and return a function. # # Example: # # > f := x^2 + y^2; # # > diff2(f,x,x,y); # (x,y) -> 2x; # # Note that you have to tell diff2 what the # variables are. # # Definition of diff2: diff2 := (func,var,var1,var2) -> unapply(diff(func(var1,var2),var),(var1,var2)):