First time here? Check out the FAQ!

Ask Your Question
0

Polynomial command

asked 12 years ago

Neda gravatar image

Hello How can I write a polynomial such as f(x^2-4,x^2-2*x) in sage?

Preview: (hide)

Comments

2

What do you mean ? You have a polynomial of two variables and you want to substitute a polynomial in x for each variable ?

vdelecroix gravatar imagevdelecroix ( 12 years ago )

I have a polynomial f= x^*y^2+x^3*y^2-y+1 and I want to compute the remainder on division of the given polynomial f by the order set F using grlex order ,but F is F=(x*y^2-x,x-y^3) that has two part, I don't know how to introduce F in sage for division algorithm.

Neda gravatar imageNeda ( 12 years ago )

1 Answer

Sort by » oldest newest most voted
1

answered 12 years ago

slelievre gravatar image

Not sure what x^y^2 was supposed to be in your polynomial f. Anyway, try something like this.

sage: R.<x,y> = PolynomialRing(ZZ, order='deglex')
sage: f = x^5 * y^2 + x^3 * y^2 - y + 1
sage: F = (x * y^2 - x, x - y^3)
sage: f.reduce(F)
x^5 + x^3 - y + 1
Preview: (hide)
link

Comments

sorry,it was my mistake, it was supposed to be x*y^2.. thank you for helping

Neda gravatar imageNeda ( 12 years ago )

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Question Tools

1 follower

Stats

Asked: 12 years ago

Seen: 428 times

Last updated: Apr 15 '13