Heads up?

Andrew Cowan

Senior Member
Apparently, if you toss a UK penny 10,000 times, it will land as heads 4950 times, and tails 5050 times. I realise that this result isn't statistically significant, and a MUCH larger sample size is needed. This question purely theoretically - I don't plan to do it as I don't have the time or resources.

Here's the question:
How would one make a penny flipping machine (robot?), which must:
  1. Flip a penny, in an entirely random manner.
  2. Collect the propped coin.
  3. Determine if it is heads or tails.
  4. Increment a counter
  5. Repeat

Problem 1 - Flipping the coin
To flip the coin without bias is a hard thing to do. My current thought is to drop the coin from a vertical position, then let it fall a short distance (~1m), where it lands on its side.

Problem 2 - Collecting the coin
The base of the platform could tilt, sliding the coin to the measurement area.

Problem 3 - Determining the side
I can't think of anything other than colouring one side black with a pen, then checking to see how much light each side reflects

Problem 4 - Repeating
Either the coin needs to get back to the drop rig, or there needs to be a large supply of coins. If there are lots of coins, then this makes my answer to problem 3 very time consuming!

As I said, I see that this isn't possible to do, but how could you do this test with 50,000 coins?

A
 

Dippy

Moderator
How about a conveyor belt?
Contrary to rumours I haven't much experience with tossing.

"As I said, I see that this isn't possible to do, but how could you do this test with 50,000 coins?"
- that reads strangely, is that what you mean?
50,000 coins will mean quite a few trips to the bank ;)
 

hippy

Technical Support
Staff member
I seem to recall a project which may have been PICAXE controlled but can also be entirely manual - the "Penguins forever going round a helter sketer". A variant on that could work, conveyor belt picking up coins and taking them back to the top.

1) Coin flipping - Should it be random or consistent ? For consistent then perhaps let it roll down a long, tight chute so it should be rolling on its edge when it leaves.

2) Collecting the coin - A number of mechanical solutions will work.

3) Determining the side - Any alteration or addition to the coin will introduce bias. Perhaps a PC with vision processing giving a heads or tails result.

4) Repeating - Really part of 3, the mechanical issue. Not sure if using multiple coins would invalidate the results. If it takes one minute per test, you'll get 50,000 done in about a month.

I think a lot boils down to what you are really attempting to measure. Perhaps the whole thing needs to be done in a sealed vacuum to take out effects of breeze and butterflies flapping wings miles away.
 

slimplynth

Senior Member
I love these "How would you do it?" questions.

Penny coins are magnetic so i would opt to include an electromagnetic arm in the design (only because it sounds more Wallace & Gromit :))... it would have to be enclosed in a decent sized container to stop the penny rolling away too far but not too small so as to influence the result. (Void all results were the penny strikes the outer edge of the container - how would that be detected?)

Not sure about how to relocate the penny but if the chamber was enclosed and lit from the bottom the penny would appear dark on the light floor, not sure if a doghnut shaped electromagnet would collect it properly. but a doughnut shape would allow an LDR to be used to determine:

i) when to stop searching and turn on the magnetic hand. (how long would this take each time?)

ii) to take a picture using a mounted webcam.

I know from previous postings on here that there are people on the forum who can deal with image recognition software.. either using or creating (neither of which I've ever used or created). But would have to tell the picaxe or PC whether it was heads or tails.

but

I have written scripts that can use the output from a picaxe to rename files... the pictures would only need to be named Heads[n].jpg or Tails[n].jpg

Leave it running for a week.

then click 'arrange by name' in the relevant PC folder and see the highest filenames for Heads[n].jpg and Tails[n].jpg.

It would also be handy to have the arm be returned to the same co-ordinates for re-throwings... and be able to move into a position, unlikely to interfere with the result i.e. not being struck.
 
Last edited:

slimplynth

Senior Member
Good point hippy, it would have to be ran twice; always flipping from the same side... run once always flipping with Tails face up and a second run always flipping Heads faced up.
 

BeanieBots

Moderator
I think a lot boils down to what you are really attempting to measure. Perhaps the whole thing needs to be done in a sealed vacuum to take out effects of breeze and butterflies flapping wings miles away.
I'd guess that it's partly due to aerodynamics that gives the unballanced result.
How about a good analysis of the air drag on each side and an accurate calculation for its CoG to do a detailed prediction of what the results would be. Then, armed with numbers from a scientific calculation, get someone else to disprove it;)
 

hippy

Technical Support
Staff member
get someone else to disprove it

I think this is the fundamental 'real question' - Starting from the premise that "a coin flipped from the same starting condition with the same external influences will always land with a particular predictable outcome".

Is the intent to disprove that or is it to prove something else ?

Is it to prove that 'there is no such thing as randomness', that the expected random outcome does not match the believed randomness of starting condition and random external influences ? When introducing randomness it's often important to define what 'random' means up front.
 

slimplynth

Senior Member
Oooh this is bringing back painful memories from '97 and a class coursework title: "The Spontanious Random Decay of Strontium 90"

What is Random?
 

Haku

Senior Member
Collecting the penny from the area it lands could easily be done by having it land on a large piece of wood or something with a V shape at the bottom so all you do is tilt the wood and the coin slides down and always ends up at the bottom of the V, without flipping over so you can then find out which side the coin laned on.

Determining which side the coin lands, you could use a security marker pen on one side of the coin, this would make it glow up under some UV LEDs and a simple LDR could be used to 'look' at the coin. Though the test would have to be carried out in the dark and I don't know if the UV ink would affect the weight of the penny enough to skew the results.

The simpler you keep the contraption the less there is to go wrong ;)
 

slimplynth

Senior Member
"What is Random? "
- most of the replies on this thread.
What is not Random then? :)

Edit: Thought about marking with dye but the ink would have a miniscule effect on the outcome? (Perhaps colour one side UV and the other black: do the same for a blank coin of the same material/dimensions etc but no heads or tails marking and compare the data)

Like the tilting floor, feeding coin into a couple of counter rotating wheels, to fire into the air.
 
Last edited:

SAborn

Senior Member
A method that comes to mind for the contraption is to use a cylinder with baffles in it to make the coin flip or bounce side to side as it fell down the cylinder.

Each end of the cylinder have a sensor to read the coin side as discussed prevoius.

Then rotate the cyclinder end for end and let the coin fall back down the other way.

The only mechanical device needed would be a motor to flip the cyclinder end for end.

A stepper would work fine and you could even give it a little shake with the motor if needed.

This way you should get 2-3 flips a minute quite easy, the coin is always encapulated.

Or flip the cylinder around several times without baffles then take your reading.

As pointed out, random is only a factor that applies to the coin, all other factors should be close to repeditive.

A picaxe would handle the motor driving and coin detection, with the results data logged to a computer for easy viewing of the results.

Should be a easy project once a detection method of the coin was worked out.
If a coat of ink on one side of the coin was a issue than use a different colour ink on the other.
 

manuka

Senior Member
In the spirit of global currency puns,I'll offer that even fingering a UK pound coin may increasingly mean it'll simply vanish. No doubt many "happy hour" Brits have already experienced the phenomena.
 

boriz

Senior Member
If you don’t separate the steps (and you don’t need too), you can get about 1 flip per second.

Use only one coin. Put a patch of fluorescent paint on one side (and an identical patch of non fluorescent paint on the other, if you really need to). Inverted cone shaped chamber. The hole at the bottom of the chamber is a little larger than coin sized (so that it doesn’t always rest exactly in the centre). Beneath that, a transparent coin rest with a solenoid kicker shaft in a hole in the middle. The coin rest is made to vibrate/jiggle to ensure the coin always ends up flat in the coin rest. And last but not least, a UV light and a phototransistor, both placed beneath the transparent coin rest to determine the result.

Quick and dirty side cross section:


BLACK: Conical chamber to catch the coin.
GREY: The coin, ready to be flipped.
BLUE: Transparent coin rest.
GREEN: Kicker shaft, passing freely through the coin rest, operated by solenoid beneath.
 

SAborn

Senior Member
You would have to think about the kicker wearing the uv patch off the coin and giving false readings.

The mechanics is easy regardless of what method is used.

The real problem is reading the coin face, We think uv will work ....but Will it?

If there was a standard way to read the coin i would consider building a counter if someone else also wanted to, so as to compare results.
 

Haku

Senior Member
You could ditch the idea of UV ink and simply go with normal permanent marker pens, the current new 1p's in the UK are extremely shiny so you could put red ink on one side and black ink on the other which would have the effect of making one side reflect notably more red light than the other.
 

hippy

Technical Support
Staff member
When looking for very small differences one would have to be very careful not to influence the outcome in any way and a very small influence could have a large distorting affect on outcome. There's also the question of what affect on-going damage during testing would have. To have validity it could need to be an experiment which has to be done in a clean room environment using mint coins and each used only once although, again, it comes down to what it is that is intended to be proven or disproven.
 

BeanieBots

Moderator
and if every single result of the 10,000 tries turned out to be heads, what does that prove? Nothing. It's statistically possible even if there is zero bias., just low probability.
 

Dippy

Moderator
And going back to post#1... why do you want to do it?
It's been an interesting 'journey', but whatever you do people will statistically pick holes in it.
Statistics is a monster subject and often contrary to human 'gut instinct' hence they'll never believe you ;)
I wonder how many people choose 1,2,3,4,5,6 in the lottery?

And what is the probability of being able to say "statistics" after 5 pints of scrumpy?
Certainly after 9 pints it is easy to demonstrate a non-Gaussian distribution :)
 

boriz

Senior Member
“You would have to think about the kicker wearing the uv patch off the coin and giving false readings.”

As long as your patch of paint is bigger than the area of potential kick points, you should always have enough UV paint to read. Drawing it in a circle would mean the readability does not change over time. Rather than paint, use a UV pen, it should leave a thinner and lighter layer. Insignificant effect when compared to dirt + fingerprints + humidity etc..
 

Andrew Cowan

Senior Member
My figures came from a different trivia website, however, I am pretty sure they are made up and not measured or based on fact.

I agree with hippy in post 21 - if one were to do this experiment, there cannot be ANY influencing factors. I think that nearly any test will have a small amount of vias in it towards one result.

Assuming the coin lasts the duration of the experiment, I think post 15 or post 18 would be the simplest to carry out (not that I plan to). However, I'm not convinced that either would be truly random (whatever that is) - as each coin will bounce a similar number of times/be flicked up in roughly the same way. You need no external influences to ensure the weight of the coin is the only factor, but you also need to ensure that the results are totally random, and not influenced by the same force each time.

To ensure it is random, I don't think the experiment is possible. Maybe dropping the coin out of a plane (in a vacuum?) would give proper results?

A
 

Dippy

Moderator
Don't book the ticket with BA.

Actually, that would be a good test for statistics.
If you book a ticket with BA when will you fly?
Calculate probability and uncertainty.
 

BeanieBots

Moderator
I think you're beginning to see the irony of the situation.
If the experiment is fully controlled and the 'flip' is always identical with zero external influences, the result will always be the same. ie always heads or always tails until some 'random' external influence makes it different.

Dropping from a height in a vacuum being a good example. The number of rotations during the fall being a constant, the landing spot being consistant etc. etc.
 

Dippy

Moderator
A variable power tosser plus landing on a bouncy surface should deal with that :)
Safest solution; just use figures done by people who have tossed a million times and then think of another project.
 

boriz

Senior Member
From post #18 - “The hole at the bottom of the chamber is a little larger than coin sized (so that it doesn’t always rest exactly in the centre).”

This is the same as saying that when the coin has come to rest, the kicker is extremely unlikely to ever be in the same exact spot. If the coin rest is, say, 20% larger than the coin, then the kicker can hit the coin anywhere in a circular patch about 20% of the coins diameter. The way/speed/direction the coin flips is mainly down to the relationship between its centre of gravity and the kick point. If the coin were to be kicked EXACTLY on its CG, then it probably still wouldn’t go up flat/level due to the tiny influences of the angle of contact, and flexing/resonant properties of the kicker. And this 20% area has an infinite number of potential kick points!

Add to that the effect of bouncing around the cone before coming to rest (each contact having the same infinite number of possible effects on the coins trajectory), this experiment should be more than random enough for the purpose.
 
Top