Mercurial > emacs
comparison lisp/calc/calcalg2.el @ 58027:771eb065ad11
(math-do-integral-methods): Try linear, then non-linear, substitutions.
author | Jay Belanger <jay.p.belanger@gmail.com> |
---|---|
date | Mon, 08 Nov 2004 02:21:11 +0000 |
parents | 768b8e4f123b |
children | 7f5b01c17652 cb7f41387eb3 |
comparison
equal
deleted
inserted
replaced
58026:07a92f2a7e6e | 58027:771eb065ad11 |
---|---|
979 (let ((so-far math-integ-var-list-list) | 979 (let ((so-far math-integ-var-list-list) |
980 rat-in) | 980 rat-in) |
981 | 981 |
982 ;; Integration by substitution, for various likely sub-expressions. | 982 ;; Integration by substitution, for various likely sub-expressions. |
983 ;; (In first pass, we look only for sub-exprs that are linear in X.) | 983 ;; (In first pass, we look only for sub-exprs that are linear in X.) |
984 (or (if math-linear-subst-tried | 984 (or (math-integ-try-linear-substitutions expr) |
985 (math-integ-try-substitutions expr) | 985 (math-integ-try-substitutions expr) |
986 (math-integ-try-linear-substitutions expr)) | |
987 | 986 |
988 ;; If function has sines and cosines, try tan(x/2) substitution. | 987 ;; If function has sines and cosines, try tan(x/2) substitution. |
989 (and (let ((p (setq rat-in (math-expr-rational-in expr)))) | 988 (and (let ((p (setq rat-in (math-expr-rational-in expr)))) |
990 (while (and p | 989 (while (and p |
991 (memq (car (car p)) '(calcFunc-sin | 990 (memq (car (car p)) '(calcFunc-sin |