Suppose when searching for a large prime, our first step is to sieve by eliminating the...
50.1K
Verified Solution
Question
Advance Math
Suppose when searching for a large prime, our first step is tosieve by eliminating the first n primes. How large should n be tospeed up our search by a factor of 10? This requires carefulthought and inventiveness before doing a computation.
How to approach this: Eliminating all odd numbers speeds up ourprogram by a factor of 2, since we've eliminated half of thechoices that are composite. If we also immediately disqualifymultiples of 3, then we speed up our program by a factor of 3,since we have eliminated 2/3 of all composites. Check that thatargument is correct. Now see what happens when you eliminate all of2, 3 and 5. Again for 2,3,5,7. Now try to figure out themathematical result and use it to solve for n.
Suppose when searching for a large prime, our first step is tosieve by eliminating the first n primes. How large should n be tospeed up our search by a factor of 10? This requires carefulthought and inventiveness before doing a computation.
How to approach this: Eliminating all odd numbers speeds up ourprogram by a factor of 2, since we've eliminated half of thechoices that are composite. If we also immediately disqualifymultiples of 3, then we speed up our program by a factor of 3,since we have eliminated 2/3 of all composites. Check that thatargument is correct. Now see what happens when you eliminate all of2, 3 and 5. Again for 2,3,5,7. Now try to figure out themathematical result and use it to solve for n.
Answer & Explanation Solved by verified expert
Get Answers to Unlimited Questions
Join us to gain access to millions of questions and expert answers. Enjoy exclusive benefits tailored just for you!
Membership Benefits:
- Unlimited Question Access with detailed Answers
- Zin AI - 3 Million Words
- 10 Dall-E 3 Images
- 20 Plot Generations
- Conversation with Dialogue Memory
- No Ads, Ever!
- Access to Our Best AI Platform: Flex AI - Your personal assistant for all your inquiries!
Other questions asked by students
StudyZin's Question Purchase
1 Answer
$0.99
(Save $1 )
One time Pay
- No Ads
- Answer to 1 Question
- Get free Zin AI - 50 Thousand Words per Month
Unlimited
$4.99*
(Save $5 )
Billed Monthly
- No Ads
- Answers to Unlimited Questions
- Get free Zin AI - 3 Million Words per Month
*First month only
Free
$0
- Get this answer for free!
- Sign up now to unlock the answer instantly
You can see the logs in the Dashboard.