[Blindmath] new member... with a question!
Alex Hall
mehgcap at gmail.com
Fri Oct 9 23:11:45 UTC 2009
Hi all,
My name is Alex. I am in college for computer science, in my third year. In
reading the description of this list I realize that the below is not quite
in keeping with the usual topics on this list, however I am hoping that
someone on here can point me to a list which would better suit my question.
Here goes...
I am working on the problems at http://www.projecteuler.net and am on
problem 3, which asks for the highest prime factor of some very large number
(over six hundred billion). I am writing a small program to give me the
answer, however the number is too large to (A) be stored in the usual
variable type or (B) return an answer in anything approaching a fast time
(if I use the old "try them all" method by dividing every number up to n/2
into n and seeing if the result is 0, my time will be n/2-2). I tried
getting the square and factoring that, but the square is a decimal that
looks infinite. I know some numbers lend themselves to being prime-factored
by getting the square root of the square above the number then finding the
gcf of the number and the square root +1 and minus 1, but this does not work
for all numbers and I am not sure what the trick to figuring out if it will
work or not is.
So... is there a fast (ish) way to factor some number that is well over
three hundred billion? I use JAWS, so an explanation in words supported by
math, instead of all math symbols, would be great. As I said at the
beginning of this message, I expect that this question is not what this list
is for, but I hope that asking it will tell people what kind of list I am
looking for and, if they know of one, they can tell me what it is. Thanks
for any help!
Have a great day,
Alex
New email address: mehgcap at gmail.com
More information about the BlindMath
mailing list