-1

$40 \cdot 40 + 40 + 41 = 40(40 + 1) + 41 = 40 \cdot 41 + 41 = 41(40 + 1) = 41^2$, so $f(40)$ is composite.

Suppose $f(n) = n^2 + n + 41$ is prime for $0 \le n \le 38$. But $f(n + 1)$ is also prime: $39^2 +39 + 41 = 1601$. So, $f(n)$ is prime for $0 \le n \le 39$.

Does the solution to the problem look something like that?

edit: like some users noted I might have to check all nonnegative $n < 40$ manually. The other post didn't solve my problem because I have no idea what's going on there. So, all I want to do is to see how strong induction fails here.

  • 1
    I think you literally have to evaluate all 40 values, $n=0,\dots,39$ and show they are prime, then evaluate $f(40)$ and show it is composite. – Gregory Grant May 05 '15 at 00:22
  • I think the only way to really check is to plug and check. Writing a program might help. –  May 05 '15 at 00:22
  • @martycohen That question is a different one. –  May 05 '15 at 00:23
  • Oh, wow. But aside the solution itself, I am also interested if the strong induction is used correctly. – very inoffensive May 05 '15 at 00:23
  • 1
    No, the second paragraph is nonsense. –  May 05 '15 at 00:24
  • Yeah, but it is subsumed in it and the OP obviously did no research, and I was annoyed. – marty cohen May 05 '15 at 00:24
  • Can you suggest alternatives? – very inoffensive May 05 '15 at 00:25
  • @ Mirko, I see where the problem is. Suppose in the alternate universe, there are no integers greater than 39. Would the inductive step be airtight in that universe? – very inoffensive May 05 '15 at 00:42
  • How can you assume that $f(n)$ is prime for $n=1,2,3\ldots,38$ without ever checking this? The induction hypotesis is never used anywhere. To show that $f(39)$ is prime you use direct computation. – Winther May 05 '15 at 00:43
  • @ Winther, I modeled it after the proof of existence part of Fundamental Theorem Of Arithmetic: By induction: assume it is true for all numbers between $1$ and $n$. If $n$ is prime, there is nothing more to prove (a prime is a trivial product of primes, a "product" with only one factor). Otherwise, there are integers $a$ and $b$, where $n = ab$ and $1 < a ≤ b < n$. By the induction hypothesis, $a = p_1p_2...p_j$ and $b = q_1q_2...q_k$ are products of primes. But then $n = ab = p_1p_2...p_jq_1q_2...q_k$ is a product of primes. – very inoffensive May 05 '15 at 00:48
  • There is an implict assumption in that proof: that we know that the theorem holds for the first few values (i.e. we can by direct computation check that $1,2,3,4,5,6$ has a unique factorization). If this was not true then the proof does not work. – Winther May 05 '15 at 01:07

1 Answers1

1

I can do half of the problem: $x^2+x+41=x(x+1)+41$. plugging in $x=40$ gives $40(41)+41=41^2$, which is clearly composite.

Asinomás
  • 107,565
  • Can we use strong induction on $n$ to show $f(n)$ is prime for $0 \le n \le 39$? – very inoffensive May 05 '15 at 00:26
  • No ${}{}{}{}{}{}{}$ – Asinomás May 05 '15 at 00:28
  • Ok, can you point out all the mistakes in the inductive step in the OP, please? I really want to see my mistake. – very inoffensive May 05 '15 at 00:36
  • You assumed $f(n)$ is prime for $1\leq n\leq 39$, you didn't prove it. You have to prove it, not assume it. – Asinomás May 05 '15 at 00:42
  • Why are we allowed to assume all numbers between $1$ and $n$ are prime when proving the existence part of this proof here: http://en.wikipedia.org/wiki/Fundamental_theorem_of_arithmetic Is it because we can't prove every number between $1$ and $n$ (not included) is prime? – very inoffensive May 05 '15 at 00:54
  • You didn't do your induction correctly. You have to prove that if a statement is true for all positive integers smaller than $n$ then it is also true for $n+1$. You just proved the particular case when $n$ is $39$. You have to prove it for arbitrary values of $n$ so that the induction works. Of course it is impossible to prove it for arbitrary values of $n$, since it is not true for all valuse of $n$. Induction is used to prove statements for all natural numbers, you only want to prove the statement for some values of $n$, this is why induction won't work. – Asinomás May 05 '15 at 00:56
  • Just to confirm I actually understand what you're saying I have a silly question. Suppose I am an alien from an alternate universe where there are no integers greater than 39. Would my induction proof work there? – very inoffensive May 05 '15 at 01:08
  • No, because you didn't prove the induction can help you prove it for $n=5$ by assuming it is true for $n=1,2,3,4$. You only proved it when the assumption is that it is true for $n=1,2,3\dots 38$ and you want to prove it for $39$. So the induction never even starts. – Asinomás May 05 '15 at 01:10
  • 1
    @veryinoffensive: Just a quick reminder of why induction works. You typically prove two statements: (1) a base case: "$P(1)$ is true"; and (2) an inductive step: "[$P(k)$ true for $k=1,\ldots,n$] implies [$P(n)$ true]". Then you have a cascade of implications: (1), together with (2) with $n=1$, implies $P(2)$ is true. Then this, together with (2) with $n=2$, implies $P(3)$ is true. One proceeds indefinitely, concluding eventually that $P(n)$ is true for all $n\in \mathbb N$. – MPW May 05 '15 at 01:50