I'm still slow. How do those numbers help us know the annihilation order? Suppose there are 4 bullets, with velocities 2/5, 4/5, 3/5, 1/5 Don't I still need to compute collision times to discover whether it's zilch or escape? I gather from your note that these numbers are sufficient to recognize the pattern.
Bubbled, no I don't. You've done what I was suggesting. And the results match Bonanova's formula! Amazing! I sure wish I understood what must be a VERY SIMPLE model of this that allows such a simple formula. i'm not seeing it, given that rank ordering of velocities doesn't even fully determine (zilch vs. escape). This is an exciting puzzle. Thanks for writing this program.
I agree with bubbled about Jasen's statement: Bubbled, I agree that you have to recognize that bullets disappear, but I disagree that you have to simulate each second; merely calculate collision timestamps
Error! I left out a case: corrected cases are: 20000 samples of this yields 0.371. This is close enough to bonanova's statement of 3/8 being spot on, that I'm looking forward EAGERLY to the simple analytical explanation :-)
I'm surprised that the choice of annihilation is so simple as these programs suggest. Perhaps there's a constraint I haven't comprehended yet. Suppose the bullets fired on one second intervals are b0, b1, b2, and b3, And suppose their velocities are v0, v1, v2, v3. Even the 4-bullet case seems to have several outcomes, one of which is that b2 catches b1 before b1 catches b0. Nowhere in these code bodies is there a three-bullet comparison. In fact, even that comparison isn't quite enough, as it's possible that b3 could catch b2 before b1 catches b0. Am I missing something in the code? or am i missing something in the problem?
I assume that ( 1 ) as the number of flags is bounded (between 100 and 1000), we can require enough memory to store a record for each found flag, and can declare how long a record is ( 2 ) a memory cell has finite precision, and that the dimensions of the maze could be arbitrarily greater than the largest value of a cell. So, although we could store some information about each found flag, we could NOT store coordinates. In fact we cannot even store coordinates of one spot (after all, we may have walked a googolplex number of steps in a straight line). ( 3 ) we are NOT permitted to leave anything in a square except a flag, and are not permitted to distinguish the orientation of the flag. Are these all true assumptions about the rules?