Artifact 0bee8f6500559e1df8ea4e521bec9a0e967b0394727f2fe12f4c0c05226c20e7:
- Executable file
r37/packages/algint/jhddiff.red
— part of check-in
[f2fda60abd]
at
2011-09-02 18:13:33
on branch master
— Some historical releases purely for archival purposes
git-svn-id: https://svn.code.sf.net/p/reduce-algebra/code/trunk/historical@1375 2bfe0521-f11c-4a00-b80e-6202646ff360 (user: arthurcnorman@users.sourceforge.net, size: 1177) [annotate] [blame] [check-ins using] [more...]
- Executable file
r38/packages/algint/jhddiff.red
— part of check-in
[f2fda60abd]
at
2011-09-02 18:13:33
on branch master
— Some historical releases purely for archival purposes
git-svn-id: https://svn.code.sf.net/p/reduce-algebra/code/trunk/historical@1375 2bfe0521-f11c-4a00-b80e-6202646ff360 (user: arthurcnorman@users.sourceforge.net, size: 1177) [annotate] [blame] [check-ins using]
MODULE JHDDIFF; % Author: James H. Davenport. % Differentiation routines for algebraic expressions; SYMBOLIC PROCEDURE !*DIFFSQ(U,V); %U is a standard quotient, V a kernel. %Value is the standard quotient derivative of U wrt V. %Algorithm: df(x/y,z)= (x'-(x/y)*y')/y; !*MULTSQ(!*ADDSQ(!*DIFFF(NUMR U,V), NEGSQ !*MULTSQ(U,!*DIFFF(DENR U,V))), 1 ./ DENR U); SYMBOLIC PROCEDURE !*DIFFF(U,V); %U is a standard form, V a kernel. %Value is the standard quotient derivative of U wrt V; IF DOMAINP U THEN NIL ./ 1 ELSE !*ADDSQ(!*ADDSQ(MULTPQ(LPOW U,!*DIFFF(LC U,V)), !*MULTSQ(LC U ./ 1,!*DIFFP(LPOW U,V))), !*DIFFF(RED U,V)); SYMBOLIC PROCEDURE !*DIFFP(U,V); % Special treatment of SQRT's (JHD is not sure why, % but it seems to be necessary); IF ATOM (CAR U) THEN DIFFP(U,V) ELSE IF NOT(CAAR U EQ 'SQRT) THEN DIFFP(U,V) ELSE BEGIN SCALAR W,DW; W:=SIMP ARGOF CAR U; DW:= !*DIFFSQ(W,V); IF NULL NUMR DW THEN RETURN DW; RETURN !*MULTSQ(!*MULTSQ(DW,INVSQ W), !*MULTF(CDR U,MKSP(CAR U,1) .* 1 .+ NIL)./ 2) END; ENDMODULE; END;