aboutsummaryrefslogtreecommitdiff
path: root/src/maple/Diff.maple
diff options
context:
space:
mode:
authorjthorn <jthorn@f88db872-0e4f-0410-b76b-b9085cfa78c5>2002-04-13 16:52:39 +0000
committerjthorn <jthorn@f88db872-0e4f-0410-b76b-b9085cfa78c5>2002-04-13 16:52:39 +0000
commitfc79a77f60a3eb527a40b53b343f40f01fbd3da9 (patch)
tree9e3f3498cb5bd88d8d0f4253d009ed192dd63061 /src/maple/Diff.maple
parent1196c0f45cec5a877d7b7f2576879388da3c84a7 (diff)
many changes
--> now works with Maple 7 correctly generates C code for AH LHS function git-svn-id: http://svn.einsteintoolkit.org/cactus/EinsteinAnalysis/AHFinderDirect/trunk@511 f88db872-0e4f-0410-b76b-b9085cfa78c5
Diffstat (limited to 'src/maple/Diff.maple')
-rw-r--r--src/maple/Diff.maple7
1 files changed, 5 insertions, 2 deletions
diff --git a/src/maple/Diff.maple b/src/maple/Diff.maple
index 8755611..3740bb4 100644
--- a/src/maple/Diff.maple
+++ b/src/maple/Diff.maple
@@ -235,6 +235,9 @@ end proc;
# It currently knows about the following simplifications:
# - Diff(X_ud[u,i], x_xyz[j]) --> X_udd[u,i,j]
#
+# Anything else is returned unchanged. (To avoid infinite recursion,
+# such a return is *unevaluated*.)
+#
# Arguments:
# operand = (in) The thing to be differentiated.
# var_seq = (in) (varargs) An expression sequence of the variables to
@@ -253,8 +256,8 @@ var_list := [args[2..nargs]];
if ( type(operand, indexed) and (op(0,operand) = 'X_ud')
and (nops(var_list) = 1) and member(var_list[1],x_xyz_list,'posn') )
then return X_udd[op(operand), posn];
- else return 'Diff'(operand, op(var_list)); # return is *unevaluated*
- # to avoid infinite recursion!
end if;
+# unevaluated return to avoid infinite recursion
+return 'Diff'(operand, op(var_list));
end proc;