Re: [sage-devel] ERROR In function "is_prime"

41 views
Skip to first unread message

Vincent Delecroix

unread,
Apr 2, 2022, 3:28:39 AM4/2/22
to sage-...@googlegroups.com
Which version of sage are you using?

In a console I get

sage: k=ZZ(18878585599102049192211644417)
sage: k.is_prime()
True
sage: GF(k)
Finite Field of size 18878585599102049192211644417


Le 02/04/2022 à 02:30, carlos ortiz a écrit :
> The number:
>
> 18878585599102049192211644417 = 61*2^88+1
>
> but in sage:
>
> k=ZZ(18878585599102049192211644417)
>
> k.is_prime()
>
> True
>
> k.factor()
>
> 18878585599102049192211644417
>
> F = FiniteField(18)
>
> raise ValueError("the order of a finite field must be a prime power")
>
>
> Howeve,
>
> F=FiniteField(18878585599102049192211644417)
>
> F
>
> Finite Field of size 18878585599102049192211644417
>
> The above functions generate error for this number
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>

Andry Rabenantoandro

unread,
Apr 2, 2022, 3:55:44 AM4/2/22
to sage-...@googlegroups.com
It seems this number is a prime number and 18878585599102049192211644417 = 61*2^88+1 is not a factorization of the number. Hence, everything is fine. Am I missing something here?

cheers,
Andry

Le sam. 2 avr. 2022 à 02:33, carlos ortiz <pep...@gmail.com> a écrit :
The number:

18878585599102049192211644417 = 61*2^88+1

but in sage:

k=ZZ(18878585599102049192211644417)

k.is_prime()

True

k.factor()

18878585599102049192211644417

F = FiniteField(18)

raise ValueError("the order of a finite field must be a prime power")


Howeve, 

F=FiniteField(18878585599102049192211644417)

F

Finite Field of size 18878585599102049192211644417

The above functions generate error for this number















--
You received this message because you are subscribed to the Google Groups "sage-devel" group.
To unsubscribe from this group and stop receiving emails from it, send an email to sage-devel+...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/sage-devel/a919429d-900d-4dbe-9106-52f7ddb84600n%40googlegroups.com.


--
Andry Nirina Rabenantoandro, PhD.


Andrew

unread,
Apr 2, 2022, 5:50:45 AM4/2/22
to sage-devel
There does seem to be a problem:

sage: k = 61*2^88+1 ; k
18878585599102049192211644417
sage: k.is_prime()
True
sage: k.factor()
18878585599102049192211644417
sage: k == 61*2^88+1
True
sage: GF(k)

Finite Field of size 18878585599102049192211644417

John Cremona

unread,
Apr 2, 2022, 6:57:17 AM4/2/22
to SAGE devel


On Sat, 2 Apr 2022, 10:50 Andrew, <andrew...@gmail.com> wrote:
There does seem to be a problem:

sage: k = 61*2^88+1 ; k
18878585599102049192211644417
sage: k.is_prime()
True
sage: k.factor()
18878585599102049192211644417
sage: k == 61*2^88+1
True
sage: GF(k)
Finite Field of size 18878585599102049192211644417

What on earth is supposed to be the problem?  The only error message I have seen in this thread is in the original post where an attempt was made to construct GF(18).


G. M.-S.

unread,
Apr 2, 2022, 8:41:18 AM4/2/22
to sage-...@googlegroups.com

Perhaps this is a hint?  The first message was sent on

Date: Fri, 1 Apr 2022 17:30:21 -0700 (PDT)

Guillermo
Reply all
Reply to author
Forward
0 new messages