Python Forum
How do I code this equation in python (factor ceiling(2^127-1))
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
How do I code this equation in python (factor ceiling(2^127-1))
#4
(Apr-22-2018, 05:15 AM)Skaperen Wrote: how do you write ceiling(2^127-1)-1? i can understand (2^127-1)-1 but i don't understand ceiling() in the context of factoring. ceiling(170141183460469231731687303715884105727)-1?

are you trying to compile a list of Mersenne Primes?

Skaperen I'm trying to predict Mersenne Primes and I know that is nuts, but I have spare time so what the heck lol.

(Apr-22-2018, 05:57 AM)Gribouillis Wrote: cypari gives some result:
 >>> import cypari >>> cypari.pari('factor({})'.format(2**127-2)) [2, 1; 3, 3; 7, 2; 19, 1; 43, 1; 73, 1; 127, 1; 337, 1; 5419, 1; 92737, 1; 649657, 1; 77158673929, 1] 
Hi,
I'm now trying to do this calculation at the interpreter and I get this error. Maybe in 10 years I'll see the answer to this one. No bad on you, but this is very complex.
My computer is running the latest version of mpmath 1.0.0

ERROR_
3**1279 % 19.1
OverflowError: int too large to convert to float
Reply


Messages In This Thread
RE: How do I code this equation in python (factor ceiling(2^127-1)) - by Pleiades - Apr-22-2018, 07:39 AM

Possibly Related Threads…
Thread Author Replies Views Last Post
  Find factor to match test curve to golden curve SriRajesh 0 1,566 Jun-17-2021, 04:39 AM
Last Post: SriRajesh
  Solve simple equation in Python kmll 4 3,113 Nov-01-2020, 04:34 PM
Last Post: deanhystad
  Python gives " -0.0 " as solution for an equation akar 2 1,794 Aug-27-2020, 12:15 PM
Last Post: akar
  Asking for help in solving a single variable nonlinear equation using Python ! NDP 0 1,994 Feb-15-2019, 12:03 PM
Last Post: NDP
  parsing text for common factor metulburr 4 4,985 Apr-28-2017, 11:04 PM
Last Post: Larz60+

Forum Jump:

User Panel Messages

Announcements
Announcement #1 8/1/2020
Announcement #2 8/2/2020
Announcement #3 8/6/2020