ASKSAGE: Sage Q&A Forum - Individual question feedhttp://ask.sagemath.org/questions/Q&A Forum for SageenCopyright Sage, 2010. Some rights reserved under creative commons license.Wed, 11 Dec 2013 15:52:05 -0600Working with very large integershttp://ask.sagemath.org/question/10803/working-with-very-large-integers/I would like to perform a fermat factorization on a number that is 600+ digits. Currently when I try to use that in sage I get "Python int too large to convert to C long." Is there an additional library or a specific sage function that I have to use in order to make this work?
ThanksThu, 05 Dec 2013 17:23:35 -0600http://ask.sagemath.org/question/10803/working-with-very-large-integers/Comment by kcrisman for <p>I would like to perform a fermat factorization on a number that is 600+ digits. Currently when I try to use that in sage I get "Python int too large to convert to C long." Is there an additional library or a specific sage function that I have to use in order to make this work?</p>
<p>Thanks</p>
http://ask.sagemath.org/question/10803/working-with-very-large-integers/?comment=16547#post-id-16547That said, Fermat factorization should work okay (if it would work at all, of course) as long as one uses Sage `Integers` in custom-written code, shouldn't it?Wed, 11 Dec 2013 15:52:05 -0600http://ask.sagemath.org/question/10803/working-with-very-large-integers/?comment=16547#post-id-16547Comment by kcrisman for <p>I would like to perform a fermat factorization on a number that is 600+ digits. Currently when I try to use that in sage I get "Python int too large to convert to C long." Is there an additional library or a specific sage function that I have to use in order to make this work?</p>
<p>Thanks</p>
http://ask.sagemath.org/question/10803/working-with-very-large-integers/?comment=16548#post-id-16548I thought about what I must have meant, and what I must have meant was finding **a** factor, for most such integers. You are right that 600-digit numbers are not factoring nicely for me; I must have been too zealous! I thought that big crypto stuff wanted 1000-digit stuff now, but maybe it's 1000-bit... or maybe my expectations were too high.Wed, 11 Dec 2013 15:51:28 -0600http://ask.sagemath.org/question/10803/working-with-very-large-integers/?comment=16548#post-id-16548Comment by kcrisman for <p>I would like to perform a fermat factorization on a number that is 600+ digits. Currently when I try to use that in sage I get "Python int too large to convert to C long." Is there an additional library or a specific sage function that I have to use in order to make this work?</p>
<p>Thanks</p>
http://ask.sagemath.org/question/10803/working-with-very-large-integers/?comment=16562#post-id-16562My guess is that your code somehow implicitly is using Python `int`s and not Sage `Integer`s. If you post (or link to) code, we can see where that happens and fix it. 600 digit integer factorization is not a problem for Sage.Fri, 06 Dec 2013 03:48:36 -0600http://ask.sagemath.org/question/10803/working-with-very-large-integers/?comment=16562#post-id-16562Comment by John Cremona for <p>I would like to perform a fermat factorization on a number that is 600+ digits. Currently when I try to use that in sage I get "Python int too large to convert to C long." Is there an additional library or a specific sage function that I have to use in order to make this work?</p>
<p>Thanks</p>
http://ask.sagemath.org/question/10803/working-with-very-large-integers/?comment=16549#post-id-16549"600 digit factorization is not a problem for Sage"?! I think that most 600-digit factorizations would be too hard.Wed, 11 Dec 2013 05:47:23 -0600http://ask.sagemath.org/question/10803/working-with-very-large-integers/?comment=16549#post-id-16549