Implementing Division of Streams (where it's a stream of polynomial coefficients)
There are a couple of cases where using where isn't gaining us anything. For instance, combineStreams can just be written as

combineStreams :: (a -&gt; b -&gt; c) -&gt; Stream a -&gt; Stream b -&gt; Stream c
combineStreams f (Cons x xs) (Cons y ys) = Cons (f x y) (combineStreams f xs ys)


Same goes for streamMap.

If you're not using combineStreams anywhere else, we can just write

instance Num (Stream Integer) where
    (Cons x xs) + (Cons y ys) = Cons (x + y) (xs + ys)




I just want to repeat the definition given in the homework, for clarity:


  If \$A = a_0 + x A'\$ and \$B = b_0 + x B'\$, then \$A / B = Q\$,
  where \$Q\$ is defined as
  
  \begin{align} Q = (a_0 / b_0) + x((1 / b_0)(A' - QB')). \end{align}


Your definition of divStreams is very close to this, but we can use the following trick where q refers to itself, just as in the formula above:

divStreams :: Stream Integer -&gt; Stream Integer -&gt; Stream Integer
divStreams (Cons x xs) (Cons y ys) = 
    let q = Cons (x `div` y) (streamMap ((1 `div` y) *) (xs - q * ys)) in q


assuming you have defined * to be multStreams.