ASKSAGE: Sage Q&A Forum - Latest question feedhttp://ask.sagemath.org/questions/Q&A Forum for SageenCopyright Sage, 2010. Some rights reserved under creative commons license.Sat, 18 Jul 2020 06:53:37 -0500Pre-set memory limit reached - Gaperrorhttp://ask.sagemath.org/question/52555/pre-set-memory-limit-reached-gaperror/ Hello everyone, I am using a Sage code to compute galois group of a polynomial of degree 24. It is a symbolic polynomial so this code gives possible galois groups. When I run it for lower degrees it gives output but when the polynomial has degree 24 it doesn't compute. Because it computes subgroups of a group of order over 264 million. I know it is very hard to find these groups but i need it. I tried so hard for 3 weeks or more. I use sagemathcell, cocalc and Oracle Virtual Box. I tried so many things but they didn't work. It gives GAPerror: reached pre-set memory limit OR runtime error Gap produced error output, error, variable $sage37 must have a value. I guess the problem is computing conjugacy classes of subgroups. How can I eliminate this Gap error?
P.S1: I am very beginner at Sage. My knowledge about coding, programming etc. is very small.
P.S2: I cannot write the code here because it doesn't belong to me. I found it on internet. But if you want to see I can send you the link.nomaddSat, 18 Jul 2020 06:53:37 -0500http://ask.sagemath.org/question/52555/Representing sboxes by using smaller GF multiplicationshttp://ask.sagemath.org/question/51036/representing-sboxes-by-using-smaller-gf-multiplications/Hello,
Up to now, I work on representing the PRESENT sbox in different ways. I tried to compute the algebraic normal form (ANF) which returns 4 output equations. Each output equation processes 4 input variables in GF(2) and returns one output variable in GF(2) while using single AND gates. After that, I used Lagrange interpolation which returned one function with one GF(2^4) input and one GF(2^4) output while using GF(2^4) multipliers. Since both equations are not very helpful for solving my problem, I look for a method to represent the sbox as two polynomials with two GF(2^2) input variables and two GF(2^2) outputs. So more detailed I want to redesign the PRESENT by only using GF(2^2) multiplications and linear components. Is there any method in SAGE to get such a representation? Dirk0579Sun, 26 Apr 2020 04:07:10 -0500http://ask.sagemath.org/question/51036/How to handle elements of two different Galois fields simultaneously?http://ask.sagemath.org/question/46758/how-to-handle-elements-of-two-different-galois-fields-simultaneously/I would like to operate the elements of two different fields simultaneously. I have used the following codes, both are not working at the same time whereas only one work at a time.
G.<x> = GF(2^8, name='x', modulus=x^8 + x^5 + x^3 + x + 1)
F.<x> = GF(2^3, name='x', modulus=x^3 + x^2 + 1)
for i in range(2^3):
print G.fetch_int(i).integer_representation(), '=', G.fetch_int(i)
print F.fetch_int(i).integer_representation(), '=', F.fetch_int(i)BSFUSat, 01 Jun 2019 03:45:13 -0500http://ask.sagemath.org/question/46758/kernel of a matrix defined over polynomial ringshttp://ask.sagemath.org/question/42453/kernel-of-a-matrix-defined-over-polynomial-rings/ I have a matrix defined as a function of variables in a polynomial ring defined over finite field as follows-
Gr.<xp,yp>=LaurentPolynomialRing(GF(2));
M=Matrix(Gr,[[xp-1,0],
[yp-1,0],
[0,(yp^(-1))-1],
[0,-(xp^(-1))+1]]);
I want to calculate the kernel of this matrix but the kernel function
M.kernel()
gives an error. What am I doing wrong?arpitSun, 27 May 2018 17:40:42 -0500http://ask.sagemath.org/question/42453/Correct way to construct a field with i adjoined?http://ask.sagemath.org/question/42420/correct-way-to-construct-a-field-with-i-adjoined/Hello,
I'm an undergrad maths student looking to understand how I successfully adjoin elements to a finite field in sagemath, to explore some of my university topics.
I can construct a base field, for example:
B = GF(2**3-1)
and I can construct an extension to this by adjoining I, which is equivalent to using the minimum polynomial x^2+1 like so:
reset('i') # make sure we haven't clobbered the imaginary constant
E = B[i]
This does what I want (I think), creating a field E that is an extension of B. We can even list the elements:
[e for e in enumerate(E)]
and this looks correct. However, things get messy when I try to use a larger field, for example:
C = GF(2**127-1)
F = C[i]
This gives the error:
> I already exists with incompatible valence
I haven't tried to redefine i at all, so far as I can tell, so, my questions are:
1. How do I correctly extend a given finite field ?
2. Following on from this, I tried the following:
A = GF(2**3-1)
B = A[i]
C = A.extension(x^2+1, 'i')
B==C
So it appears I can't successfully adjoin 'i' using a minimum irr poly either. Printing B and C give:
sage: B
Finite Field in I of size 7^2
sage: C
Finite Field in i of size 7^2
which would explain why they aren't equal... except i and I should be equal.
In short, I would like to construct the quotient field PRIME BASE FIELD[x]/x^2-1 and have the arbitrary x treated as complex values ("adjoining sqrt(-1)") but I'm unclear from sage's documentation on how to achieve this.
3. I see the notation
R.<x> = GF(blah)
quite a lot. Can someone please explain it? I can't find anything in the documentation that might help me understand what this is and why it is necessary.
You can assume I understand most of an undergraduate galois theory course and have a basic understanding of algebraic number theory - what I don't understand is how this maps into sage.zahllosThu, 24 May 2018 08:52:10 -0500http://ask.sagemath.org/question/42420/Factorization of $f \in \mathbb{Q}[X]$ in field extension $\mathbb{Q}(\alpha)$.http://ask.sagemath.org/question/40374/factorization-of-f-in-mathbbqx-in-field-extension-mathbbqalpha/I'm given an irreducible polynomial $f \in \mathbb{Q}[X]$ of degree 5 and I want to determine its Galois group without using the predefined functions of sage. The method I want to follow takes a root $\alpha_1$ of $f$ and studies the factorization of $f$ in the field extension $\mathbb{Q}(\alpha_1)$.
I believe this is possible with other software. How can I do it with sage?
**Edit**
Apparently, Abstract Algebra: An Interactive Approach, Second Edition but they use InitDomain function which is not recognized by my notebook.
Apparently the book gives a CD where an interface between sage and gap is done. So probably the solution requires using gap commands.Rodrigo RayaSat, 30 Dec 2017 12:14:54 -0600http://ask.sagemath.org/question/40374/Finding a $\gamma$ to define a number field like $E=\mathbb{Q}(\zeta_5)(X^5-\gamma)$http://ask.sagemath.org/question/33638/finding-a-gamma-to-define-a-number-field-like-emathbbqzeta_5x5-gamma/ By working with eliptic curves, I found that the extension E defined by:
E.<a> = NumberField(x^20 - 2*x^19 - 2*x^18 + 18*x^17 - 32*x^16 + 88*x^15 + 58*x^14 -
782*x^13 + 1538*x^12 + 1348*x^11 - 466*x^10 - 894*x^9 + 346*x^8 -
114*x^7 - 424*x^6 - 88*x^5 + 214*x^4 + 54*x^3 + 14*x^2 + 4*x + 1)
Is a cyclic Kummer extension of degree $5$ over $\mathbb{Q}(\zeta_5)$, thus by the clasification of Kummer extensions, there exists $\gamma \in \mathbb{Q}(\zeta_5)$ such that $E=\mathbb{Q}(\sqrt[5]{\gamma})$.
So, about all the polynomials $f$ that define $E$ how do I find $\gamma$ such that the polynomial $X^5-\gamma$ also defines $E$?belvedereThu, 02 Jun 2016 02:13:29 -0500http://ask.sagemath.org/question/33638/Transform a list of coefficients to polynomial (in GF(2^8))http://ask.sagemath.org/question/29465/transform-a-list-of-coefficients-to-polynomial-in-gf28/ Hi there,
Currently i'm trying to convert a list of coefficients automatically to a polynom. I got a list of zeros and ones and want to transform this list to a polynom in GF(2^8). First I set up the GF(2^8) with the reduction polynom
P2.<x> = GF(2)[];
p = x^8 + x^4 + x^3 + x + 1;
GF256 = GF(2^8, 'x', modulus=p)
Next I get a list of coefficients:
coeff = [0, 1, 0, 1, 1, 1, 0, 1]
which should be the polynom:
x^6 + x^4 + x^3 + x^2 + 1
How do I get this transformation from list to polynom automatically? The native thing I think about is I set up a string and fill in the coeff. like this:
polyString = str(coeff[7])+'*x^7 + '+str(coeff[6])...
And then cast it in GF256
poly = GF256(polyString)
But I think they are smarter ways out there.. Any ideas ? :)
nablaheroWed, 16 Sep 2015 08:19:32 -0500http://ask.sagemath.org/question/29465/Compute Galois closure of an extension of a function fieldhttp://ask.sagemath.org/question/7875/compute-galois-closure-of-an-extension-of-a-function-field/Say I want to look at the field extension $Quot(\mathbb{Q}[x,y]/y^7-x)$ over $\mathbb{Q}(x)$ and then compute its Galois closure. How do I do that?
Ideally it could be done on the scheme-level (to define the scheme-morphism: (the projectivization of the affine plane curve $y^7-x$) mapping to (the projective $x$-line); and then compute its Galois closure -- a scheme!). But I don't know how to implement either version.OliverSat, 15 Jan 2011 14:11:48 -0600http://ask.sagemath.org/question/7875/question about galoisgroup of show(G[1](a)) of Q(x^6)http://ask.sagemath.org/question/10921/question-about-galoisgroup-of-showg1a-of-qx6/https://sage.math.uni-goettingen.de/home/cjsh/31/
G[1] = (126453) why G[1](a) is a Polynomial?
cjshWed, 15 Jan 2014 23:45:39 -0600http://ask.sagemath.org/question/10921/