14 May
2001
14 May
'01
3:02 a.m.
The following appears to work, (@\@) :: (Num a) => Polynomial a -> Polynomial a -> Polynomial a f @\@ g = applyrec pp g 0 where pp = map (\x -> toPolynomial [x]) (fromPolynomial f) applyrec (f:fs) g m = f * g^m + applyrec fs g (m+1) applyrec [] _ _ = 0 Sorry for the original email, although I would be interested in a better solution if there is any commentary. Ben. On Sun, May 13, 2001 at 09:43:31PM -0500, Ben wrote:
Hello, I hope that a question here wont be too much of a bother.
Yesterday I wrote a library for polynomial manipulation. Everything is fine except for the composition operator. Which I having problems with, probably trivial, but as I don't program in Haskell everyday a solution isn't clear. ...etc.