Sure, go for it!
On 3/2/07, Robert Bradshaw <[EMAIL PROTECTED]> wrote:
>
> It's always bugged me that the default distribution for integers (and
> rationals) is just a uniform distribution over some small range. What
> if instead we chose the distribution ZZ.random_element() = floor(1/r)
> where
It's always bugged me that the default distribution for integers (and
rationals) is just a uniform distribution over some small range. What
if instead we chose the distribution ZZ.random_element() = floor(1/r)
where r is uniformly distributed in (-1,1). Then P(n) = 1 / (2 |n| (|
n| + 1)) fo
On 3/1/07, didier deshommes <[EMAIL PROTECTED]> wrote:
> On 2/25/07, Craig Citro <[EMAIL PROTECTED]> wrote:
> > Hey all,
> >
> > So I tried to generate a random polynomial today, and ran into some trouble.
> > Here's what I did:
> >
> > sage: R. = ZZ['x']
> > sage: R.random_element(3)
> >
>
> That
On 2/25/07, Craig Citro <[EMAIL PROTECTED]> wrote:
> Hey all,
>
> So I tried to generate a random polynomial today, and ran into some trouble.
> Here's what I did:
>
> sage: R. = ZZ['x']
> sage: R.random_element(3)
>
That is a nice edge case. I would say that or you just return 0
everytime. Othe