[Math] How to find an integer value for which an expression is non-prime

algebra-precalculuselementary-number-theoryprime numbers

I've just begun Robert S. Wolf's, Proof, Logic and Conjecture. At the end of the first chapter there are some exercises to warm you up for the proof techniques he will eventually introduce. I only mention this so that you are aware that I have yet to encounter formal proof techniques.

The first part of the question simply asks you to substitute small values of $n$ into the expression $n^2-n+41$ and to test if these values are prime. I did this for $n=1$ to $12$, and all the values seemed prime. This leads me onto the second part of the question where I am stuck.

I'll paraphrase the question:

(1)(b)
Find a positive integer value of $n$ for which the expression $n^2-n+41$ is not a prime number.


My attempt

I will decompose the expression $n^2-n+41$ into symbolic and numeric parts i.e. $n^2-n$ and $41$, in order to obtain a better understanding of it.

The symbolic part of the expression $n^2-n$ can be factorised to $n(n-1)$. From this it is apparent that this portion of the expression will only ever return even values, because it will always be of the form where we have an odd number multiplied by an even number. For example: for $n=5$, an odd number, we have $5(5-1)=5(4)=20$; similarly for $n=4$, an even number, we have $4(4-1)=4(3)=12$.

The addition of an odd number and even number returns an odd number, thus the addition of $41$ (an odd number) to $n^2-n$ (an expression which always returns even numbers) will give an odd number for all integer values of $n$.

As $n^2-n+41$ always returns odd numbers, it then stands to reason that if we are to find any non-prime value of this expression it will also be odd.

The only way I could think of doing this was by defining the odd numbers as $2n+1$, (where $2n$ is an even number and $n$ is an integer) and equating this to the expression in the hope that the intersection would return values that are odd and non-prime, however it is not the case that this equivalence returned an integer value of $n$ for which this expression is not prime.

Where have I gone wrong?

Best Answer

How about $n=41$?

In general, if you choose $n$ so that all of the terms in a sum are divisible by the same number, then the whole sum will be divisible by that number.

Edit: My understanding is that your approach was to set $n^2-n+41 = 2n+1$ and look for integer solutions. But this is quite a strong condition: you're saying not just that $n^2-n+41$ is odd, but that it's the particular odd number $2n+1$. This is a quadratic in $n$, so it has at most $2$ solutions - it's not particularly surprising that it doesn't have integer solutions.

But for any integer value of $n$, $n^2-n+41$ is odd. If you just want to express that $n^2-n+41$ is odd, the relevant equation is $n^2 -n +41 = 2k+1$. This equation has exactly one integer solution for every value of $n$: an example is $n = 41$, $k = 840$.

Related Question