On Jan 29, 2:22 pm, Willem Jan Palenstijn <w...@usecode.org> wrote:
> On Fri, Jan 29, 2010 at 05:58:39AM -0800, Sebastian Pancratz wrote:
> > The value of m is set by the call "fmpz_poly_pseudo_divrem(quo, r.num,
> > &m, a.num, b.num)", where as the output above shows we have a.num and
> > b.num both equal the polynomial 9*t-2.  From the FLINT (1.5.0) manual,
> > this call should set quo=Q, r.num=R and m such that
>
> >     lead(B)^m*A = B*Q + R
>
> > and the degree of R is less than the degree of B, where a.num=A,
> > b.num=B and lead(B) is the leading coefficient of B.  Here we have A =
> > B = 9*t-2 and lead(B) = 9.  The output above shows that Q and R are
> > computed correctly as 1 and 0, but I would expect that m should be set
> > to 0 rather than 120658626.
>
> fmpz_poly_pseudo_divrem has a bug in the special case for A == B, where it 
> sets
> d instead of *d to 0.
>
> -Willem Jan

Thanks!

Later tonight I'll update the patch on ticket #4000 to work around
that.  By the way, it seems the problem only appears when A == B, not
when they are different objects in memory merely representing the same
integer polynomials.

Sebastian

-- 
To post to this group, send an email to sage-devel@googlegroups.com
To unsubscribe from this group, send an email to 
sage-devel+unsubscr...@googlegroups.com
For more options, visit this group at http://groups.google.com/group/sage-devel
URL: http://www.sagemath.org

Reply via email to