Guys, please help me figure this out:
1) how to calculate the largest prime less than 300
2) why 35 and 37 are not twin primes?
3) the smallest number divisible by five different primes
Any input would be greatly appreciated)
this is the program which i wrote:
#include<iostream.h>
#include<conio.h>
#include<stdlib.h>
void prime(int p)
{
if(p==0||p==1)
{
cout<<"neither prime nor composite"<<endl;
getch();
exit(1);
}
for(int i=2;i<p/2;i++)
{
if(p%i==0)
{
cout<<"composite"<<endl;
break;
}
else...
I talked with an old friend of mine. We discussed prime numbers and Ulams Spiral, and the mathematical patterns that surround us all. He brought up something called the Zeta-Function and something about -1 1/2 and how this all related to prime numbers. I did a google search and found some...
An easy question.
All "odd" number can be expressed as a sum of consecutive natural numbers.
Example:
35=17+18
35=5+6+7+8+9
35=2+3+4+5+6+7+8Question:
Demonstrate that prime numbers (except for the "2"), can only be expressed as the sum of two consecutive natural numbers.
Homework Statement
use Eular's formula to find the greatest prime number under :
If I wasn't forced to use this method I would set up a program to loop through checking for primes
Homework Equations
F(n) = n^2 + n + 41(0 to 39)
or depending on your PoV
f(n) = n^2 - n + 41(1 to...
It is known that prime numbers become sparser and sparser, with the average distance between one prime number and the next increasing as n approaches infinity. Dividing an even number by 2 results in a bottom half from 1 to n / 2 and a top half from n / 2 to n. For a particular sufficiently...
I imagine most everyone here's familiar with the proof that there's an infinite number of primes:
If there were a largest prime
you could take the product of all prime factors
add (or take away) 1 and get another large prime (a contradiction)
So what if you search for larger primes this...
Hi everyone,
I've been bumping on this problem for a while and wondered if any of you had any clue on how to approach it. My question is whether the following equality is possible for 4 distinct prime numbers :
PxPy + Pw = PwPz + Px
where Px, Py, Pw, Pz are odd prime numbers, and each...
I took the prime numbers from this link:
http://nl.wikibooks.org/wiki/Wiskunde/Getallen/Lijst_priemgetallen
I did take the first three lines
I did the following with the numbers
The prime 11 = 1+1 = 2
The prime 13 = 1+3 = 4
The prime 17 = 1+7 = 8 and so on
This is the result for the...
Hey guys, just looking for an explanation for the following algorithm. It is in my textbook, and there isn't really an explanation. I don't really see how the algorithm works, but I will add what I do know, and hopefully one of you can help. Thanks.
//this initial declarations produces an...
(For the following problem I don't just want a flat out answer, but steps and Ideas on how to solve it. The problem was given by my Universities newspaper and for solving it you get free Loot and stuff)...
f(x) will give us the smallest integer m such that y^m \equiv 1 \bmod{x} given that x and y are coprime
how would one go about showing that this function is multiplicative? I'm trying to do some Number Theory self study, and the problems I'm encountering are quite difficult to figure out from...
Homework Statement
This is a question i just got in the coursera material.
Euclid's proof that there are infinitely many primes uses the fact that if p1…,pn are the first n primes, then the number N=(p1...pn)+1 is prime. True or False.
The answer was False
I answered true and i THINK i...
I was just wondering what are some applications of prime numbers other than cryptography?
Also i heard that there is no certain *equation or prediction of Prime numbers?
For example, there is no way to explain prime numbers with an equation.
What happens if one was able to find one...
Hello, this is rather vague but I had a lecture around a year ago about prime numbers and how a mathematician (Hardy or Euler?) found a proof to do with prime numbers and then this lead on to cryptography and internet security...
That's all I can particularly remember but I'm wondering on...
Homework Statement
Prove by Contradiction: For all Prime Numbers a, b, and c, a^2 + b^2 =/= c^2
Homework Equations
Prime number is a number whose only factors are one and itself.
Proof by contradiction means that you take a statement's negation as a starting point, and find a...
Hello everybody , I'm Adrian , new stupid among apes :biggrin:
This might sound silly or obvious according to a viewer's point of view and knowledge on the matter but,is there any visible undeniable linear order or logical distinguishable pattern in the distribution of primes of which humanity...
Hi everybody.
I would like to find a book about the Distribution of Prime Numbers and the Riemann's Zeta Function.
I know about the "classical" books:
1) Titchmarsh's "The Theory of the Riemann Zeta-Function"
2) Ingham's "The Distribution of Prime Numbers"
3) Ivic's "The Riemann...
I know that one of Goldbach's conjectures is that every even number is the sum of 2 primes.
So, I was wondering if there was a definite, largest prime number ever possible. I know that as a number gets larger, there are more numbers that can be tried to divide it (At least I think so), and I...
What is the probability that the stability of strings depends on prime quantities in order to be unique?
Without prime numbers, would the strings break into composite states.
I'm trying to find a general formula for an algebraic equation, I'm studying the behavior of ∏_{i=2}^n(1-\frac{1}{i^m}) for m=3 and so far I've seen that I can find a general formula if n^2 + n + 1 produces only prime numbers. if not, it would get way harder to find a general formula for it by...
Homework Statement
Write a program that takes a command line argument N and a sequence of N positive integers and prints the numbers that are prime only, followed by their sum.
Homework Equations
for loop
The Attempt at a Solution
This has been a vexing program to think of. We...
Hi guys,
I always wanted to know if one could generate prime numbers according to an equation,so I wanted to go and study prime numbers little bit and know how exactly its gets formed and its logic.
So as we all know that prime number is any natural number that is divisable by itself and 1...
According to the prime number theorem, the number of prime numbers that are less than N is approximately N\ln(N) for a sufficiently large N. But can we find the product of prime numbers that are less than N?
(For example, N=20 then 2x3x5x7x11x13x17x19 although I think 20 isn't large enough haha)
A positive integer is called an additive prime number if it is prime and the sum of its digits is also prime. For example, 11 and 83 are additive prime numbers. OEIS gives the sequence of additive primes the number http://oeis.org/A046704" for that info).
I've done many Google and...
I have read several books on the Riemann Hypothesis and have a general understanding of the non-trivial zeros and their real part 1/2. In my own studies I have devised a root system based upon some of Euclid’s ideas and congruence that identifies some interesting properties of the square roots...
Homework Statement
Euclid's proof
Euclid offered the following proof published in his work Elements (Book IX, Proposition 20)[1] and paraphrased here.
Take any finite list of prime numbers p1, p2, ..., pn. It will be shown that some additional prime numbers not in this list exist. Let P be...
Homework Statement
If G is an abelian simple group then G is isomorphic to Zp for some prime p (do not assume G is a finite group).Homework Equations
In class, we were told an example of a simple group is a cyclic group of prime order.The Attempt at a Solution
Let G be an abelian simple...
Is there a rule governing the frequency of prime numbers?
Also, I've heard that all primes greater than 3 are of the form 6k+1 or 6k-1. I'm assuming that this is because 6 is the lcm of 2 and 3 (the two primes lesser than 3), and the +1,-1 is because if the number was in a range greater than...
how many prime numbers have we actually solved,,, how can we say that there is no end to prime when we can't even count that high, i think sooner or later all numbers higher than primegod would be not prime
The question states prove,
If p is prime and p | a^n then p^n | a^n
I am pretty sure I have i just may need someone to help clean it up.
There are two relevant theorems i have for this.
the first says p is prime if and if p has the property that if p | ab then p | a or p | b
the...
Homework Statement
Hello, i want to calculate and print prime numbers from 1 to 20. I've provided my code below, and the program compiles but its just printing all numbers from 1 to 20, why?
also have i used the continue statement correctly, since if it is found that a number is not prime then...
Prove, if p and q are distinct prime numbers, then sqrt(p/q) is irrational. I know how to prove that if p is a distinct prime number, then sqrt(p) is irrational. From there let sqrt(p) = q/r and then prove but for this I'm stuck. Do we let sqrt(p/q) = (a/b)/(c/d).Thanks.
Homework Statement
Let's take a prime number p not equal to 5.
Now let's take three integers a,b,c.
Prove that if p | (a + b + c) \wedge p | (a^5 + b^5 + c^5), then
p | (a^2 + b^2 + c^2) \vee p | (a^3 + b^3 + c^3)
Homework Equations
I think:
(a + b + c)^2 = a^2 + b^2 + c^2 +...
Hi all,
I'm reviewing some problems that involve finding the prime factors of composite numbers (e.g. prime factors of 44 are 2, 2, 11) and I had two questions about prime numbers and factors of composite numbers:
1) Is there some sort of quick test to tell if a number is prime? Or, does...