Hi Thomas! (sorry, previously I made a wrong guess on your name)

On Jul 29, 10:02 am, eggartmumie <eggartmu...@googlemail.com> wrote:
> ...
> Later I need the coefficients of the Goppa polynomial as linear
> combination of monomials.

I don't understand what that means. Please provide explicit examples!

Currently I can only jump from assumption to vague interpretation to
guess; that makes it very difficult to provide any help.
Thus, I think I should ask you more precise questions as well.

So far, I thought we are talking about a univariate polynomial,
something like
  sage: R.<x> = QQ[]
  sage: p = R.random_element()
  sage: p
  -x^2 + 4/9*x - 2

Question 1:
Is that your setting, or what exactly is the ring you are working
with?

Concerning coefficients:
  sage: p.coefficients()
  [-2, 4/9, -1]

A "coefficient" is an element of the base ring (QQ, in my example).
I know two conventions for monomials:
1) Some people say that a monomial is a power product of variables,
like x^3.
2) Other people say that a monomial is the product of a coefficient
with some power product of variables, like 4/9*x (the first sort of
people would call this a "term") :/

In either case, I really don't see what it could mean to express "the
coefficients as linear combinations of monomials". The best I can come
up with are some associations.

First association:
Get the part of the polynomial that is divisible by a certain monomial
 sage: p>>1
 -x + 4/9
Meaning: p == x*(-x+4/9)+remaining terms not divisible by x.

Second association:
Start with a multivariate polynomial
 sage: R.<x,y,z> = GF(3)[]
 sage: p = R.random_element(6)
 sage: p
 -x*y^5 + x^4*y*z + x^2*z^2 - y^2*z
 sage: p.coefficient(z)
 x^4*y - y^2
So, here we have a coefficient that, itself, is a linear combination
of monomials.

Third association:
A polynomial ring over a polynomial ring
 sage: R.<x> = ZZ['t'][]
 sage: R
 Univariate Polynomial Ring in x over Univariate Polynomial Ring in t
over Integer Ring
 sage: p = R.random_element()
 sage: p
 (-3*t^2 - t - 1)*x^2 + (t^2 - t + 1)*x - 3*t - 2
 sage: p.coeffs()
 [-3*t - 2, t^2 - t + 1, -3*t^2 - t - 1]
So, again, each coefficient is a polynomial (but in a different ring).

Question 2:
Is any of my associations close to what you mean? Otherwise, please
provide an example.

> In order to be able to once define the Goppa polynomial in a function
> I tried to compute the coefficients from the given function goppapolynomial.

Question 3:
What exactly is the "function" goppapolynomial supposed to do / to
be?
Is it a function that returns a polynomial? Or is it a polynomial
function, itself?
Please specify input and output. Is it really just returning X^(N-K)
(what are N and K, anyway?)?

Cheers,
Simon

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

Reply via email to