#XsPuzzleCorner, 20250907

This week the #puzzle is: Fine, Maybe Tiling Problems Can Be Fun… #tiling

Question row A:

You have an infinite square grid. Each cell in this grid is either red or blue.
Can you create a pattern in which every red cell has exactly:
zero red neighbors,
one red neighbor,
two red neighbors,

eight red neighbors?
Neighbors include any cell that is directly adjacent or corner-adjacent. To avoid admitting degenerate solutions, your pattern must have at least some fraction 0<r≤1 of the total board composed of red cells.

Question row B:

Now we will consider patterns in which every red and every blue cell has exactly the same number—nr and nb, respectively—of same colored neighbors. For example, the image above is not a valid pattern since some of the blue cells have 4 blue neighbors while others have 6.
For which pairs (nr, nb) can we construct valid patterns?

Fine, Maybe Tiling Problems Can Be Fun…

Highlight to reveal (possibly incorrect) solution:

Solutions to 1, 2, 3, 4, 5, 5, 6, 7 and 8 neighbors. (Solution for 0 was already given.)

Question row B:

Program

Some more solutions:

nr \ nb01234567
0imageimageimageimageimageimageimage(image)
1imageimageimageimageimageimage(image)image
2imageimageimageimageimageimageimageimage
3imageimageimageimageimageimageimageimage
4imageimage(image)(image)imageimageimageimage
5imageimageimageimageimageimageimageimage
6(image)image(image)imageimageimageimageimage
7imageimageimageimageimageimageimageimage

#ThisWeeksFiddler, 20250905

This week the #puzzle is: How Low (or High) Can You Go? #probabilities #volume #area #random

You’re playing a game of “high-low,” which proceeds as follows:
First, you are presented with a random number, x1, which is between 0 and 1.
A new number, x2, is about to be randomly selected between 0 and 1, independent of the first number. But before it’s selected, you must guess how x2 will compare to x1. If you think x2 will be greater than x1 you guess “high.” If you think x2 will be less than x1, you guess “low.” If you guess correctly, you earn a point and advance to the next round. Otherwise, the game is over.
If you correctly guessed how x2 compared to x1 then another random number, x3, will be selected between 0 and 1. This time, you must compare x3 to x2, guessing whether it will be “high” or “low.” If you guess correctly, you earn a point and advance to the next round. Otherwise, the game is over.
You continue playing as many rounds as you can, as long as you keep guessing correctly.
You quickly realize that the best strategy is to guess “high” whenever the previous number is less than 0.5, and “low” whenever the previous number is greater than 0.5.
With this strategy, what is the probability you will earn at least two points? That is, what are your chances of correctly comparing x2 to x1 and then also correctly comparing x3 to x2?

And for extra credit:

Your friend is playing an epic game of “high-low” and has made it incredibly far, having racked up a huge number of points.
Given this information, and only this information, what is the probability that your friend wins the next round of the game?

How Low (or High) Can You Go?

Highlight to reveal (possibly incorrect) solution:

Desmos

And for extra credit:

Program Spreadsheet

#ThisWeeksFiddler, 20250822

This week the #puzzle is: How Far Can You Run Before Sundown? #maximum #strategy #recursion

You’re participating in a trail run that ends at sundown at 7 p.m. There are four loops: 1 mile, 3 miles, 3.5 miles, and 4.5 miles. After completing any given loop, you are randomly assigned another loop to run—this next loop could be the same as the previous one you just ran, or it could be one of the other three. Being assigned your next loop doesn’t take a meaningful amount of time; assume all your time is spent running.
Your “score” in the race is the total distance you run among all completed loops you are assigned. If you’re still out on a loop at 7 p.m., any completed distance on that loop does not count toward your score!
It is now 5:55 p.m. and you have just completed a loop. So far, you’ve been running 10-minute miles the whole way. You’ll maintain that pace until 7 p.m.
On average, what score can you expect to earn between 5:55 p.m. and 7 p.m.?

And for extra credit:

Now let’s add one more wrinkle. At some point during the race, if you’re unhappy with the loop you’ve just been randomly assigned, you’re granted a “mulligan,” allowing you to get another random assignment. (Note that there’s a 25 percent chance you’ll be assigned the same loop again.) You don’t have to use your mulligan, but you can’t use it more than once.
As before, the time is 5:55 p.m. You have just completed a loop, and you haven’t used your mulligan yet.
With an optimal strategy (i.e., using the mulligan at the right moment, if at all), on average, what score can you expect to earn between 5:55 p.m. and 7 p.m.?

How Far Can You Run Before Sundown?

Intermission:

So. I didn’t get the extra credit last week. No shame in that. I had all the points from the previous puzzles of Q3. We were a group of 10 persons able to say that. I am now in the group of 6 persons, who dropped out from that max points group, now counting 4 members.

Still. It made me wonder. What was required to solve the extra credit? How does one find a strategy?

  • Make a list of all the strategies you can think of. Remember to include the optimal one. 😉
  • Test every item on the list.
  • Declare a winner.

This requires good brainstorming skills. Also in this case I couldn’t leap this hurdle:

  • A strategy is a list of “given voucher situation A, choose bet option B”.

As it turned out, the strategy also needed to include “is this the 1st bet, yes or no”.

Because I actually had the pieces. I had the $55 strategy for the 1st bet. And I had the $35 strategy for having all vouchers. I could just have combined them to get the correct extra credit result.

Ah well.

Highlight to reveal (possibly incorrect) solution:

Program

And for extra credit:

Mindomo Program Image

Moralkuglen

Jeg har læst “The Moral Bullet”, #BruceSterling og #JohnKessel. Quick fix. Spoilers.

Nogen har opfundet en foryngelseskur. Eftersom alle jo gerne vil være yngre, så bliver den en del af samfundet, og alle kan få de indsprøjtninger, de har brug for. Effektivt er det udødelighed. Man startede med de gamle. Det her er simpelthen bare en god ting.

Men uvægerligt er der nogen, der begynder at mistænke, at doserne ikke er jævnt fordelt. Så verden bryder sammen, mens bander kæmper mod hinanden. (Måske er det en faktor her, at en verden af unge mennesker er let at ophidse.) Dødeligheden stiger voldsomt. Ups. Det første quick fix i den her historie virkede altså ikke i første forsøg.

Hele det her rod startede i USA. Ovre i Europa har de gjort en ny opdagelse, nemlig at man også kan indsprøjte moral i folk. Europæerne er derfor ved at få styr på sagerne igen. De mest skydeglade får sådan en dosis, og så bliver der ro. Nu er planen 1) at finde den oprindelige opfinder, der jo er et geni, 2) fylde ham med moral (folk med moral opfinder ikke bare evig ungdom, og lader verden forfalde som resultat), 3) importere ham til Europa, 4) få opfundet en kombination af ungdom og moral, 5) udbrede denne version af indsprøjtningerne.

Men amerikanerne, der jo altså stadig er ret paranoide, hopper absolut ikke bare med på den plan.

Kan planen gennemføres, når geniet ikke giver samtykke? Er samtykke nødvendigt? Er det en god plan? En moralsk plan? Er det faktisk moral på sprøjte, man har opfundet? Det er en historie, der tager fat i de her spørgsmål, men ikke besvarer dem.

Warp på din egen måde

Anmeldelse af Warp Your Own Way, af #RyanNorth. #GraphicNovel. 2024. Hugo-vinder. #StarTrek

Skitse: Ombord på Cerritos vågner Mariner desværre. Hendes sambo skal tidligt på arbejde, mens hun selv kan sove et par timer til. Skidt pyt. Man falder jo bare i søvn igen. Men der bliver ved med at være forstyrrelser, så til sidst opgiver hun, står op, laver noget kaffe og går ud for selv at forstyrre nogle andre.

Er det science fiction? Ja! 🖖🏻🖖🏻🖖🏻

Temaer: Lynhurtigt kommer vi i gang med du-er-helten-delen. Hvilken kaffe skal det være? Og hvem skal forstyrres? Fordi jeg har prøvet det her før, så skrev jeg mine valg ned, så en “blind vej” bare kunne blive rullet tilbage. Og det var der behov for. Rigtig mange af vejene er nemlig blinde. Og der dukker også elementer op, der vist ikke plejer at høre til i den her genre. Et par gange måtte jeg ændre min forståelse af tingene. En mindre doven læser lavede et diagram over bogen og forklarede et par ting, jeg ikke havde fanget.

Det her føles virkelig som en integreret del af Star Trek. Visuelt ligner det 100 %, og det er flot. De forskellige personer opfører sig som de plejer. Plottet er også indenfor skiven, og moralen til sidst er vist en gentagelse fra et af afsnittene, der var det vist bare Rutherford, der viste os, hvordan man bør ordne tingene.

Plottet har en skurk, der på sin egen måde bryder en af “lovene”, og derfor taber. Jeg vil ikke afsløre hvilken lov. Men det kan sammenlignes med, at hvis de var kommet til en paradisisk planet, så ville loven sige, at Tingene Er I Virkeligheden Som Helvede, og at vores helte derfor skulle vælte tyrannen eller ødelægge computeren eller sådan noget. Den slags lov.

Oprindeligt var det her en papirbog, men den virker også fint som pdf på en tablet. Bogstaverne er store nok. Dobbeltsider kan man se ved at blade lidt frem og tilbage. Man kan ikke bare klikke på en boks og hoppe til den side, hvor historien fortsætter (i hvert fald ikke med lige min pdf-læser), men der er en fin indholdsfortegnelse, så skiftet trods alt kan ske hurtigt. Hele bogen tog mig 2-3 timer.

Er det godt? Ja! 🖖🏻🖖🏻🖖🏻 Det er en af de bedste oplevelser, jeg har haft med franchiset i papirform. Og medmindre Paramount får fundet ud af at lave episoder, der kopierer Black Mirrors interaktive film, så kunne det her kun laves som papir- eller computerspil. Og det er charmerende, at de valgte papir. 👽👽👽

#ThisWeeksFiddler, 20250815

This week the #puzzle is: How Much Free Money Can You Win? #probabilities #bets #minimum #maximum

A casino offers you $55 worth of “free play vouchers.” You specifically receive three $10 vouchers and one $25 voucher.
You can play any or all vouchers on either side of an even-money game (think red vs. black in roulette, without those pesky green pockets) as many times as you want (or can). You keep the vouchers wagered on any winning bet and get a corresponding cash amount equal to the vouchers for the win. But you lose the vouchers wagered on any losing bet, with no cash award. Vouchers cannot be split into smaller amounts, and you can only wager vouchers (not cash).
What is the guaranteed minimum amount of money you can surely win, no matter how bad your luck? And what betting strategy always gets you at least that amount?
Hint: You can play vouchers on both sides of the even money game at the same time!

And for extra credit:

You have the same $55 worth of vouchers from the casino in the same denominations. But this time, you’re not interested in guaranteed winnings. Instead, you set your betting strategy so that you will have at least a 50 percent chance of winning W dollars or more. As before, you cannot split vouchers and cannot wager cash.
What is the maximum possible value of W? In other words, what is the greatest amount of money you can have at least a 50 percent chance of winning from the outset, with an appropriate strategy? And what is that betting strategy?

How Much Free Money Can You Win?

Highlight to reveal (possibly incorrect) solution:

PDF Image

And for extra credit:

PDF Image Program

Addendum.

Program

#ThisWeeksFiddler, 20250808

This week the #puzzle is: Can You Canoodle at the Coldplay Concert? #probabilities #geometry #integral #estimat #montecarlo

All the many attendees at a particular Coldplay concert are couples. As the CEO of Astrometrics, Inc., you are in attendance with your romantic partner, who is definitely not the head of HR at Astrometrics, Inc. During the concert, the two of you spend half the time canoodling.
The camera operators love to show people on the jumbotron during the concert, but time is limited and there are many attendees. As a result, the camera operators show just 1 percent of couples during the concert. Couples are chosen randomly, but never repeat at any given concert.
You and your partner are shy when it comes to public displays of affection. While you don’t mind being shown on the jumbotron, you don’t want to be shown canoodling on the jumbotron.
How many Coldplay shows can the two of you expect to attend without having more than a 50 percent chance of ever being shown canoodling on the jumbotron?

And for extra credit:

Now, everyone at the concert spends at least some time canoodling. In particular, each member of a couple wants to spend some fraction of the time canoodling, where this fraction is randomly and uniformly selected between 0 and 1. This value is chosen independently for the two members of each couple, and the actual time spent canoodling is the product of these values. For example, if you want to canoodle during half the concert and your partner wants to canoodle during a third of the concert, you will actually canoodle during a sixth of the concert.
Meanwhile, the camera operators love to show canoodling couples. So instead of randomly picking couples to show on the jumbotron, they randomly pick from among the currently canoodling couples. (The time shown on the jumbotron is very short, so a couple’s probability of being selected is proportional to how much time they spend canoodling.)
Looking around the concert, you notice that the kinds of couples who most frequently appear on the jumbotron aren’t constantly canoodling, since there are very few such couples. Indeed, the couples who most frequently appear on the jumbotron spend a particular fraction C of the concert canoodling. What is the value of C?

Can You Canoodle at the Coldplay Concert?

Highlight to reveal (possibly incorrect) solution:

Program

And for extra credit:

Spreadsheet Desmos Program

Ladehus-effekten, en rapport

Jeg har læst “The Report on the Barnhouse Effect”, #KurtVonnegut. Quick fix. Spoilers.

Ved et tilfælde opdager en videnskabeligt orienteret person, at han kan noget i retning af telekinese. Han øver sig, og han noterer sig, hvordan det virker, så andre evt. kan oplæres også. Det er naturligt at forestille sig, at regeringen bør bruge denne nye teknik.

Efter et skuffende møde med militæret går vor helt under jorden. Hans egen mission bliver at ødelægge moderne våben, når han opdager dem. Pacifistiske allierede råber gerne højt, når de finder en ny base.

Det ser ud til at virke. Konflikter må fremover afgøres med køller, og det er et stort fremskridt. Så de 2 tilbageværende spørgsmål er: Kan missionen videreføres efter mandens død (ja), og er der noget at stille op mod sådan en enegænger? Det sidste må man gøre op med sig selv. Kan det blive et våben at påstå, at min fjendes hospital er en våbenfabrik? Kan fremstilling og oplagring af våben decentraliseres? Hvad synes du?

#ThisWeeksFiddler, 20250801

This week the #puzzle is: Can You Squeeze the Squares? #optimal #placements #packing

There’s a square board with side length A. Your friend cleverly places a unit square on the board and challenges you to place another unit square on the board—without moving the first one—so that it too is entirely on the board and the squares don’t overlap. (The unit squares can touch each other.)
Alas, it’s impossible for you to do so! But there’s some minimum value of A for which you can always place a second unit square on the board, no matter how cleverly your friend places the first one.
What is this minimum value of A?

And for extra credit:

Now there’s another square board with side length B. This time, your friend cleverly places three unit squares (which can touch but not overlap) and issues a similar challenge, asking you to place one more unit square on the board.
Once again, it’s impossible for you to do so! But there’s some minimum value of B for which you can always place a fourth unit square on the board, no matter how cleverly your friend places the first three squares.
What is this minimum value of B?

Can You Squeeze the Squares?

***

“Last Week’s Fiddler. Congratulations to the (randomly selected) winner from last week: 🎻 Lise Andreasen 🎻 from Valby, Copenhagen, Denmark.” 😁😁😁

***

Highlight to reveal (possibly incorrect) solution:

Desmos 1 Desmos pictures 1 and 2.

And for extra credit:

Desmos 2

#ThisWeeksFiddler, 20250725

This week the #puzzle is: Can You Sprint to the Finish? #probabilities #strategy #optimal

… you and a competitor are approaching the finish of a grueling stage of the Tour de Fiddler. One of you will win the stage, the other will come in second. As you approach the finish, each of you will test the feeling of your legs, which will be somewhere between 0 percent (“I can barely go on!”) and 100 percent (“I can do this all day!”). For the purposes of this puzzle, these values are chosen randomly, uniformly, and independently.
Immediately after feeling your legs, you and your opponent each have a decision to make. Do you maintain your current pace, or do you sprint to the finish? Among those who sprint for the finish, whoever’s legs are feeling the best will win the stage. But if no one sprints for the finish, everyone has an equal chance of winning the stage. In the Tour de Fiddler, you must each decide independently whether to sprint for the finish based on your legs—you don’t have time to react to your opponent’s decision.
Normally, teams at the Tour de Fiddler keep their strategy and tactics close to the vest. But earlier today, your opponent’s manager declared on international television that if (and only if) your opponent’s legs were feeling 50 percent or better, they’d sprint for the finish.
As you are about to test your legs for the final sprint and see how they feel, what are your chances of winning the stage, assuming an optimal strategy?

And for extra credit:

Instead of one opponent, now you have two—meaning three riders in total. As luck would have it, the managers for both other riders proclaimed that they’d sprint for the finish if (and only if) their legs were feeling 50 percent or better. Note that your opponents’ feelings are independent of each other.
As the three of you near the finish, your own team manager radios you the following message: “If your legs feel <garbled> percent or better, sprint for the finish!”
You can’t make out what the garbled part of the message is, and you’re too tired to radio back for confirmation. Instead, you somehow muster the energy to randomly, uniformly pick a number between 0 and 100 to fill in the blank from your manager’s message, thereby determining your racing strategy—optimization be damned!
Right before you choose your random strategy and test your legs, what are your chances of winning the stage against both opponents?

Can You Sprint to the Finish?

Highlight to reveal (possibly incorrect) solution:

And for extra credit:

Program