Horner's method on subexpressions
- To: mathgroup at smc.vnet.net
- Subject: [mg17351] Horner's method on subexpressions
- From: Ben Raphael <braphael at ucsd.edu>
- Date: Mon, 3 May 1999 01:45:54 -0400
- Organization: Univ of Calif San Diego
- Sender: owner-wri-mathgroup at wolfram.com
I have a sequence of expressions that contain polynomials and other terms. An example is an expression of the form: 1/2 Re[-2/x^28 + 2(1+x)^56 / x^28] + Re[(1 / (-1 + 2x)^29) (high degree polynomial in x)]/483298748 The polynomials that appear have integer coefficients. What I would like to do is rewrite this expression by applying the Horner[] function to the polynomial, in order to speed up evaluation. However, the Horner function only takes polynomial arguments, so one way to proceed is to extract the polynomial term, apply Horner and then reconstruct the expression. Does anyone know an efficient way to do this, or have method to suggest? Thanks, Ben Raphael braphael at ucsd.edu