Since it’s the time of year when you might be looking for mathematical gifts to buy for your friends, colleagues and loves ones, I thought I’d share some recommendations and suggestions for places to find gifts online.
You're reading: Columns
Carnival of Mathematics 222
The next issue of the Carnival of Mathematics, rounding up blog posts from the month of November 2023, is now online at John D Cook’s blog.

The Carnival rounds up maths blog posts from all over the internet, including some from our own Aperiodical. See our Carnival of Mathematics page for more information.
Primes, reversals and concatenations
In the last Finite Group livestream, Katie told us about emirps. If a number p is prime, and reversing its digits is also prime, the reversal is an emirp (‘prime’ backwards, geddit?).
For example, 13, 3541 and 9999713 are prime. Reversing their digits we get the primes 31, 1453 and 3179999, so these are all emirps. It doesn’t work for all primes – for example, 19 is prime, but 91 is \(7 \times 13 \).
In the livestream chat the concept of primemirp emerged. This would be a concatenation of a prime with its emirp. There’s a niggle here: just like in the word ‘primemirp’ the ‘e’ is both the end of ‘prime’ and the start of ’emirp’, so too in the number the middle digit is end of the prime and the start of its emirp.
Why? Say the digits of a prime number are \( a_1 a_2 \dots a_n \), and its reversal \( a_n \dots a_2 a_1 \) is also a prime. Then the straight concatenation would be \( a_1 a_2 \dots a_n a_n \dots a_2 a_1 \). Each number \(a_i\) is in an even numbered place and an odd numbered place. Now, since
\[ 10^k \pmod{11} = \begin{cases}
10, & \text{if } k \text{ is even;}\\
1, & \text{otherwise,}
\end{cases} \]
it follows that each \(a_i \) contributes a multiple of eleven to the concatenation. A mismatched central digit breaks this pattern, allowing for the possibility of a prime.
I wrote some code to search for primemirps by finding primes, reversing them and checking whether they were emirps, then concatenating them and checking the concatenation. I found a few! Then I did what is perfectly natural to do when a sequence of integers appears in front of you – I put it into the OEIS search box.
Imagine my surprise to learn that the concept exists and is already included in the OEIS! It was added by Patrick De Geest in February 2000, based on an idea from G. L. Honaker, Jr. But there was no program code to find these primes and only the first 32 examples were given. I edited the entry to include a Python program to search for primemirps and added entries up to the 8,668th, which I believe is all primemirps where the underlying prime is less than ten million. My edits to the entry just went live at A054218: Palindromic primes of the form ‘primemirp’.
The 8,668th primemirp is 9,999,713,179,999.
Mathematical Drawing Hacks

At this year’s MathsJam UK Gathering, I had the pleasure of running one of the Saturday Night Tables – a chance to invite attendees at the Gathering to drop by and play with something. Together with fellow Manchester MathsJam regular Andrew Taylor, I ran a table of Mathematical Drawing Hacks – ways to make drawing complex mathematical objects and shapes easier.
21X competition – results

A while ago we announced a competition to win a copy of algebraic blackjack game 21X, which was recently successful on Kickstarter, smashing its funding target by an order of magnitude. If you’d like to pre-order a copy of the game, you can sign up to be notified when that’s possible.
We had over 30 entries in the competition, of which 20 achieved correct answers, and have picked a random set of winners to pass on to Naylor Games, who should be in touch with them by email in the next few days.
For anyone interested in seeing the answers, here’s what they were. As a reminder, the challenge here is to find a value for \(x\), given that \(n\) represents the number of cards, to get the total of all the card values closest to 21.
Carnival of Mathematics 221
The next issue of the Carnival of Mathematics, rounding up blog posts from the month of October 2023, is now online at Beauty of Mathematics.

The Carnival rounds up maths blog posts from all over the internet, including some from our own Aperiodical. See our Carnival of Mathematics page for more information.
2. Four bugs
Reminder: I’m occasionally working to (sort of) recreate Martin Gardner’s cover images from Scientific American, the so-called Gardner’s Dozen.
This time I’m looking at the cover image from the July 1965 issue, accompanying the column on ‘op art’ (which became chapter 24 in Martin Gardner’s Sixth Book of Mathematical Diversions from Scientific American).
