Author Topic: A question about primes  (Read 1872 times)

A question about primes
« on: 12 June, 2012, 03:42:24 pm »
We were doing some math revision with the kids on the weekend and the youngest asked if there was a rule for adding two exponents, like this:



He'd gotten a little confused with the rules for multiplying exponents.

Anyway, it got me thinking. For an equation of the following form:



Where:

a is an even number

b is an odd number

Is the result always a prime number?
<i>Marmite slave</i>

A question about primes
« Reply #1 on: 12 June, 2012, 04:05:42 pm »
We were doing some math revision with the kids on the weekend and the youngest asked if there was a rule for adding two exponents, like this:



He'd gotten a little confused with the rules for multiplying exponents.

Anyway, it got me thinking. For an equation of the following form:



Where:

a is an even number

b is an odd number

Is the result always a prime number?

Not if n=0 and b=1

vorsprung

  • Opposites Attract
    • Audaxing
Re: A question about primes
« Reply #2 on: 12 June, 2012, 04:07:26 pm »
You mean (a to the n plus b to the n+1) -1 ?

No.  Unless I misunderstand you entirely, which given my appreciation of Maths is highly likely  ;D

perl -le '$n=3;for ($i=0; $i<30; $i+=2) { print "a=$i,","b=",$i+1, " "; $s=($i**$n+($i**($n+1)))-1; print $s, " ", fact($s);} sub fact {my $s=shift;  for (2..$s-1) { push @f,$_ if int($s/$_)==$s/$_; } print "@f";}'

Sorry my factor finder doesn't use a sieve

Re: A question about primes
« Reply #3 on: 12 June, 2012, 04:17:31 pm »
Anyway, it got me thinking. For an equation of the following form:



Where a is an even number and b is an odd number, is the result always a prime number?

If a and b have a common factor then any sum of their powers will be divisible by that factor. For example, if a = 6 and b = 9 then any sum of their powers will be divisible by 3.

But even if a and b have no common factor, there are still lots of counterexamples. For example, if a = 2 and b = 5, then an + bn+1 is divisible by 3.*

* Exercise for the reader: prove this!

Re: A question about primes
« Reply #4 on: 12 June, 2012, 04:23:23 pm »
Anyway, it got me thinking. For an equation of the following form:



Where a is an even number and b is an odd number, is the result always a prime number?

If a and b have a common factor then any sum of their powers will be divisible by that factor. For example, if a = 6 and b = 9 then any sum of their powers will be divisible by 3.
Ah, I should have thought of that.
But even if a and b have no common factor, there are still lots of counterexamples. For example, if a = 2 and b = 5, then an + bn+1 is divisible by 3.
hmm. ok, ta
<i>Marmite slave</i>

Re: A question about primes
« Reply #5 on: 13 June, 2012, 12:20:10 pm »
There is no known formula for generating primes. It's one of the things that all modern computer security is based on.
I think you'll find it's a bit more complicated than that.

Re: A question about primes
« Reply #6 on: 13 June, 2012, 02:44:50 pm »
I believe that there are formula for generating primes - but no known formula for generating all primes.
<i>Marmite slave</i>

Re: A question about primes
« Reply #7 on: 13 June, 2012, 04:45:15 pm »
I believe that there are formula for generating primes - but no known formula for generating all primes.

It depends on what you mean by formula—there are systems of Diophantine equations that take on positive integer values for the prime numbers (all the primes, and only the primes).

It's one of the things that all modern computer security is based on.

The RSA public-key cryptographic system depends for its security on the fact that there's no known efficient* algorithm for factorizing an integer n into primes**. But there are other public-key systems that depend on the hardness of other mathematical problems, e.g. DSA depends on the hardness of the discrete logarithm problem.

* For mathematicians: by efficient I mean O(polylog n).
** On classical computers, anyway.

Re: A question about primes
« Reply #8 on: 15 June, 2012, 08:56:53 am »
Is it just me or does anyone else not have a clue what they are talking about? ???
Cancer changes your outlook on life. Change yours before it changes you.

Jaded

  • The Codfather
  • Formerly known as Jaded
Re: A question about primes
« Reply #9 on: 15 June, 2012, 09:16:20 am »
vorsprung's post did it for me  ;D
It is simpler than it looks.

clarion

  • Tyke
Re: A question about primes
« Reply #10 on: 15 June, 2012, 09:17:51 am »
I was following vorsprung for the first two paragraphs.  Then I think his keyboard broke.
Getting there...

Pancho

  • لَا أَعْبُدُ مَا تَعْبُدُونَ
Re: A question about primes
« Reply #11 on: 15 June, 2012, 09:31:31 am »
I've become fearful of homework assistance and revision. While I may be able to haul up dusty memories of some subjects, I can't compete on everything. And if I get something wrong, they tell me off and call me thick; "don't be such an idiot Daddy; the stables were Hercules' fifth labour" was yesterday's bringing to heel. Actually I'm going to check that as I'm still pretty convinced the stables were one of the first.

clarion

  • Tyke
Re: A question about primes
« Reply #12 on: 15 June, 2012, 09:46:26 am »
Wikipedia has it as the fifth, so you ain't gonna win that one.  If it's on t'internet, it must be true! ::-)
Getting there...

Re: A question about primes
« Reply #13 on: 15 June, 2012, 09:57:28 am »
Wikipedia has it as the fifth, so you ain't gonna win that one.  If it's on t'internet, it must be true! ::-)
<edits wikipedia to make the stables the 2nd labour>

lol

I get a few of the same problems. My get out is "Let me just look at your revision book to remind me of the terminology used."

<i>Marmite slave</i>

Woofage

  • Tofu-eating Wokerati
  • Ain't no hooves on my bike.
Re: A question about primes
« Reply #14 on: 15 June, 2012, 10:22:37 am »
I believe that there are formula for generating primes - but no known formula for generating all primes.

I think Fermat had a go.
Pen Pusher

Re: A question about primes
« Reply #15 on: 15 June, 2012, 10:58:57 am »
I believe that there are formula for generating primes - but no known formula for generating all primes.

I think Fermat had a go.

Nah he was just winding up all the mathematicians that came after him.
I think you'll find it's a bit more complicated than that.