Is this what you mean? sage: R.<x> = PolynomialRing(ZZ,"x") sage: f = 2*x**2-x sage: f.factor() x * (2*x - 1)
On Tue, Jun 16, 2009 at 11:12 AM, Mikie<[email protected]> wrote: > > When I use Sage to factor lets say 2*x**2-x it factors the 2 out and > leaves a fraction in the expression. I would like to have it not > factor the polynomial unless their is an integer factor. By the way I > have created a Twisted API that works. > > On Jun 15, 4:51 pm, William Stein <[email protected]> wrote: >> On Mon, Jun 15, 2009 at 10:54 PM, Mikie<[email protected]> wrote: >> >> > Is there anyway to get the factor function to factor an expression >> > without using QQ['x'].0? I want just integer factors. >> >> I don't understand what you mean by "integer factors"? Can you give an >> example? >> >> > I have created a Twisted server using Sage to do calculations from a >> > form. >> > When I put QQ['x'].0 into the sage script I get a systax on the >> > period. It does work from the command line. >> > Thanx >> >> -- >> William Stein >> Associate Professor of Mathematics >> University of Washingtonhttp://wstein.org > > > --~--~---------~--~----~------------~-------~--~----~ To post to this group, send email to [email protected] To unsubscribe from this group, send email to [email protected] For more options, visit this group at http://groups.google.com/group/sage-support URLs: http://www.sagemath.org -~----------~----~----~----~------~----~------~--~---
