ASKSAGE: Sage Q&A Forum - Latest question feedhttps://ask.sagemath.org/questions/Q&A Forum for SageenCopyright Sage, 2010. Some rights reserved under creative commons license.Mon, 11 Mar 2019 21:07:03 -0500How to compute the sums of squares of elements of a quotient ring?https://ask.sagemath.org/question/45767/how-to-compute-the-sums-of-squares-of-elements-of-a-quotient-ring/ Hi,
I'm new to Sage, and I would like to be able to test, given some $q$, whether $$\sum_{p(t) \in \mathbb{F}_{q}[t]/(f)}^{}{p^2(t)}=k \bmod (f)$$
for some fixed $f \in \mathbb{F}_q [t]$ and $k \in \mathbb{F}_q$.
I can get as far as (for $q=3$ and $f=x^2+1$):
sage: R = PolynomialRing(GF(3),'x'); x = R.gen()
sage: S = R.quotient(x^2 + 1)
But I'm not sure how to sum over all the elements of the quotient ring, let alone their squares.
Any hints?
LlewMon, 11 Mar 2019 21:07:03 -0500https://ask.sagemath.org/question/45767/Multivariate rational function field of rank 3 over Rational Fieldhttps://ask.sagemath.org/question/37584/multivariate-rational-function-field-of-rank-3-over-rational-field/I'm want to rewrite a small Magma code in Sage, and I want to define a multivariate rational function field of rank 3 over rational field. Simply, I have the following Magma code:
aInv<a2,a4,a6> := FunctionField(Rationals(), 3);
_<X> := PolynomialRing(aInv);
f := X^3 + a2*X^2 + a4*X + a6;
fprim := Derivative(f);
I started doing something like this:
aInv<a2,a4,a6> = FunctionField(QQ['a2,a4,a6'])
But, I get a TypeError, more specifically, I get:
> TypeError: constant_field must be a
Any idea how to achieve what I want?
> field.ninhoSat, 13 May 2017 08:38:07 -0500https://ask.sagemath.org/question/37584/what different equation_order of FunctionField and order of a FunctionField?https://ask.sagemath.org/question/23428/what-different-equation_order-of-functionfield-and-order-of-a-functionfield/ http://sagemath.org/doc/reference/function_fields/sage/rings/function_field/function_field.html#sage.rings.function_field.function_field.FunctionField_polymod.equation_order
there are a function named equation_order(),what meaning about it?
I know order is a subring of maximal ring in a field,ther no equation_order define in all google.....cjshWed, 16 Jul 2014 01:19:27 -0500https://ask.sagemath.org/question/23428/