Threading the state can also mean using the STATE monad as suggested Earlier.

On Nov 4, 2014 3:54 AM, "Hiromi ISHII" <konn.jinro@gmail.com> wrote:
Hi,


On 2014/11/02 18:50, Travis Cardwell <travis.cardwell@extellisys.com> wrote:

> Indeed: many algorithms merely require values from a uniform distribution,
> not necessarily random numbers.  I was hopeful that Cantor-Zassenhaus
> would be one of them.
>
> Looking at your code [1], I see that you are exporting both
> `equalDegreeSplitM`, which uses `uniform` from `Control.Monad.Random`, and
> `equalDegreeFactorM`, which iteratively calls `equalDegreeSplitM`.  One of
> the challenges of using a pure uniform stream is threading the state:
> since both functions are exported, implementation details would leak anyway.

"Threading the state" means "using ST monad", right?
If so, I think we can use algebraic numbers only within ST monad, so it would be too restrictive to do some calculation.

> Great work, by the way! :)

Thanks!

-- Hiromi ISHII
konn.jinro@gmail.com




_______________________________________________
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe