Editor
Joined: 11/3/2013
Posts: 506
There isn't, as far as I'm aware, a particularly efficient way to cut down the candidates for Mersenne primes. GIMPS, I think, tests candidates for relatively small prime factors (which can be optimised a little by the fact that any factor of 2^p-1 must be one more than a multiple of p). But the majority of the computational work is performing the Lucas-Lehmer test on very large numbers. In order to check if 2^p-1 is prime, you have to multiply together two numbers of the order of 2^p, and you have to do it p times. Overall that is of the order of p^3 bit operations of the sort a logic gate might perform (I think). So when you get up to p being 10^8, you have to do 10^24 calculations. Which is far, far less than the 2^(5*10^7) calculations you'd need for trial division, but still quite large.
Banned User
Joined: 3/10/2004
Posts: 7698
Location: Finland
Famously, lim(x → ∞) (1+1/x)x = e. But what is lim(x → 0) (1+1/x)x?
Editor
Joined: 11/3/2013
Posts: 506
lim(x → 0) (1+1/x)x = lim(y → ∞) (1+y)1/y (using the substitution y=1/x) = lim(z → ∞) z1/(z-1) (using the substitution z=1+y) = lim(z → ∞) eln(z)/(z-1) = elim(z → ∞) (ln(z)/(z-1)) = elim(z → ∞) (1/z)/1 (differentiating ln(z) and z-1 using l'Hôpital's rule) = elim(z → ∞) (1/z) = e0 = 1
Editor
Joined: 11/3/2013
Posts: 506
Actually, there is a common-sense way of interpreting this. e is often introduced in terms of compound interest. If I put $1 into a bank, and the bank pays 100% interest a year, how much do i have after a year? Well, if the bank pays interest once a year, I have (1+1/1)1 = $2. If the bank pays twice a year, I have (1+1/2)2 = $2.25. Three times a year and it's (1+1/3)3 = $2.37... In the limit where the bank is paying me interest continuously, then after one year I have $2.71..., and we call this number e. Now let's run this question in the other direction. What if the bank pays interest every two years? Now I only get (1+2)1/2 = $1.73..., and if it only pays every three years I get (1+3)1/3 = $1.59... What happens in the limit when the bank never pays interest? Well, without doing any maths at all, it should be pretty self-evident that I still have the dollar I started with.
Banned User
Joined: 3/10/2004
Posts: 7698
Location: Finland
Mathologer made a wonderful YouTube video about the (in)famous sum 1+2+3+4+... and its connection to the value -1/12. Is that sum equal to that value? The answer is complicated. I suppose that one way to answer it is "yes and no". In normal arithmetic it's not equal to that, because the same rules that apply to convergent infinite sums cannot be used with divergent infinite sums. However extended summation methods can be defined. Most prominently in this case, the analytic continuations of the eta and zeta functions (which are well-defined and unique) give a sensible expansion to the summation. I think he does a great job at explaining all this in terms that can be easily understood even by laypeople. https://www.youtube.com/watch?v=YuIIjLr6vUA
Banned User
Joined: 3/10/2004
Posts: 7698
Location: Finland
The youtuber blackpenredpen made a video about the integral from 0 to 1 of the function ln(x)ln(1-x)dx. Calculating the exact value seemed to be quite laborious. I find the function itself quite interesting. It's almost like a semi-circle, but not quite.
Editor
Joined: 11/3/2013
Posts: 506
It also reminds me of the entropy of mixing formula, which has a similar shape, and a formula with stuff like ln(x) and ln(1-x) in it. In fact when I saw this I thought "ah, that's the entropy of mixing" (but it turns out I'm rusty and the actual formula is actually a bit different).
Editor, Expert player (2372)
Joined: 5/15/2007
Posts: 3940
Location: Germany
Editor
Joined: 11/3/2013
Posts: 506
y=log x is upside-down and y=sin x is back-to-front.
Editor, Skilled player (1348)
Joined: 12/28/2013
Posts: 396
Location: Rio de Janeiro, Brasil
thatguy wrote:
y=log x is upside-down and y=sin x is back-to-front.
y = log(a) x would be correct if a is smaller than 1.
My YouTube channel: https://www.youtube.com/channel/UCVoUfT49xN9TU-gDMHv57sw Projects: SMW 96 exit. SDW any%, with Amaraticando. SMA2 SMW small only Kaizo Mario World 3
Banned User
Joined: 3/10/2004
Posts: 7698
Location: Finland
Usually definite integral problems are given like: integral from -∞ to ∞ of e-x^2 dx = ? I was wondering if such problems are ever presented in such a way that what's asked is not the value of the integral, but the value of one (or both) of the limits. For example: For which value of A does the integral from 0 to A of e-x^2 dx = 0.5? I suppose it becomes even more difficult if both limits are variables, and you are asked for a function of one in terms of the other. In other words, for which values of A and B does the integral from A to B of e-x^2 dx = 0.5?
Editor
Joined: 11/3/2013
Posts: 506
Okay, let's pick a simpler function like x2 ∫(0 -> A) x2 dx = 72 {x3/3}(0 -> A) = 72 A3/3 = 72 A3 = 72 x 3 = 216 A = 2161/3 = 6 But you knew all that, of course. I'm assuming you chose the function deliberately not to have an elementary antiderivative. It has a closed-form value when the integral is evaluated over the entire number line, but in general the indefinite integral cannot be expressed as a combination of the standard polynomial, exponential, logarithmic and trigonometric functions we are used to. So, going through the same process, you aren't going to get anything nicer-looking than B = erf-1(erf(A) + 0.5) (where erf is the indefinite integral of e-x2).
Player (80)
Joined: 8/5/2007
Posts: 865
This week's Riddler challenges were kind of interesting and I'm still working on the first one. The second one is mostly a matter of patience and it's pretty clear what you're supposed to do. Regarding the first one, however... I was stumped for a good long while until I loaded the image into MS Paint and flipped it vertically so that I could see precisely what was being graphed. I placed the flipped image in the upper-left corner so that the bottom-left corner of the original image corresponds to the point (0,0). I also noticed that some of the pixels have colors associated with them. I then used OEIS to find out exactly what the patterns were. Here are my findings:
  • The first row and first column contain black pixels if they are prime numbers such that p+1 is divisible by 4. I haven't yet figured out the significance of this, as it does not fit the pattern of the other rows or columns.
  • Coordinates (x,y) are black if x^2 + y^2 is prime. Incidentally, this explains why the black pixels are symmetrical about the main diagonal and why the main diagonal is white. It probably also explains why you never see five or more black pixels along any diagonal, but I'll work that out another time.
  • Colored pixels are not prime. Of course, this means they're begging to be prime factored...
  • Computing x^2 + y^2 for each colored pixel, we see that they each have exactly two distinct prime factors. (Two of the orange pixels and one of the purple pixels are divisible by 9 = 3^2.)
  • These prime factors seem to show up repeatedly. For example, the prime factors for the orange pixels are 3^2*5, 3^2*17, 5*13, and 13*17. These can be "chained" along: 3^2 --> 5 --> 13 --> 17 --> 3^2. Unfortunately, some of the primes can't be strung along in this manner and are isolated.
And at this point, I'm stuck. Any thoughts? Edit: All of the prime factors (or prime powers, in the case of 3^2) are multiples of 4 plus 1. Hmmm...
Editor, Expert player (2080)
Joined: 6/15/2005
Posts: 3284
The black pixels represent the Gaussian primes, where bottom left is 0=0+0i. I know that's not the entirety of the question but I didn't bother figuring out what the colored pixels do so I stopped there.
Banned User
Joined: 3/10/2004
Posts: 7698
Location: Finland
Here's a small puzzle for you. How does the series continue? 15, 35, 77, 143, 221, 323, 437, 667, 899, 1147, 1517, 1763, 2021, 2491, 3127, 3599, 4087, 4757, ...
Player (36)
Joined: 9/11/2004
Posts: 2631
You forgot 6.
Build a man a fire, warm him for a day, Set a man on fire, warm him for the rest of his life.
Banned User
Joined: 3/10/2004
Posts: 7698
Location: Finland
I didn't forget it. I just didn't want to give too many hints.
Player (36)
Joined: 9/11/2004
Posts: 2631
Oh ok! I get it then. The next number in the series is 4758. The series is just the natural numbers, and you're just omitting numbers at random so it's not too obvious. ;P
Build a man a fire, warm him for a day, Set a man on fire, warm him for the rest of his life.
Amaraticando
It/Its
Editor, Player (162)
Joined: 1/10/2012
Posts: 673
Location: Brazil
The next number s(19) is 69. This sequence clearly obeys the following polynomial:
Player (80)
Joined: 8/5/2007
Posts: 865
Amaraticando wrote:
The next number s(19) is 69. This sequence clearly obeys the following polynomial:
No joke, I was thinking of doing the same thing. Then you actually went there. (By the way, is there any reason that this polynomial evaluates to an integer when x=19? Is that true in general? It seems like a wild coincidence.)
Amaraticando
It/Its
Editor, Player (162)
Joined: 1/10/2012
Posts: 673
Location: Brazil
Bobo the King wrote:
No joke, I was thinking of doing the same thing. Then you actually went there. (By the way, is there any reason that this polynomial evaluates to an integer when x=19? Is that true in general? It seems like a wild coincidence.)
I just added the value that I wanted as the 19th term and incremented the degree of the polynomial.
Player (80)
Joined: 8/5/2007
Posts: 865
Amaraticando wrote:
Bobo the King wrote:
No joke, I was thinking of doing the same thing. Then you actually went there. (By the way, is there any reason that this polynomial evaluates to an integer when x=19? Is that true in general? It seems like a wild coincidence.)
I just added the value that I wanted as the 19th term and incremented the degree of the polynomial.
Oh, oops. I should have noticed that a 17th degree polynomial can be fit to 18 points.
Banned User
Joined: 3/10/2004
Posts: 7698
Location: Finland
OmnipotentEntity wrote:
Oh ok! I get it then. The next number in the series is 4758. The series is just the natural numbers, and you're just omitting numbers at random so it's not too obvious. ;P
The formula still makes sense even when omitting the 6 from the beginning. For those who might still be wondering about that series, the formula to get it is quite simple. It's not something super-complicated or contrived.
Experienced player (642)
Joined: 11/30/2008
Posts: 650
Location: a little city in the middle of nowhere
You're right, it's not contrived. Check the GCD between one number and the next in the series.
Measure once. Cut twice.
Banned User
Joined: 3/10/2004
Posts: 7698
Location: Finland
I'll just write the answer in spoiler tags, if somebody wants to know: The series consists of the products of every pair of consecutive odd primes. In other words, 3*5=15, 5*7=35, 7*11=77, and so on.