Wednesday, April 04, 2007

The Prisoner's Dilemma Demystified

We all have at some point in life faced major dilemmas. The ones which can make your life interesting to say the least, when you would suddenly start to understand that Heisenberg with his uncertainty principles was not such a big fool after all or why was the word vacillating added into the English language. But what concerns us on a day to day basis and seems largely inexplicable is not something that cannot be quantized and is very much tangible. It seems that those geeky scientists who seem to be so preoccupied with their great unsolved problems, weird hypothesis, earth shattering researches and ground breaking procedures also seem to look into the dark labyrinth of the human mind and fish out something so funny, interesting and yet life changing that will leave us surprised. It makes us realize that we are living in a vicious circle. First simplify the complex things and then use science to complexify( couldn't think of a word actually !!!) them. Well the purpose of my post is to allow one to have a peek into the classical prisoner’s dilemma problem and yet demystify it and see its applications in day to day life. For the uninitiated, here is the problem.

The Prisoner's dilemma was originally framed by Merrill Flood and Melvin Dresher working at RAND ( the same place John Nash worked for some time) in 1950. Albert W. Tucker formalized the game with prison sentence payoffs and gave it the "Prisoner's Dilemma" name

The classical prisoner's dilemma (PD) is as follows:

Two suspects, A and B, are arrested by the police. The police have insufficient evidence for a conviction, and, having separated both prisoners, visit each of them to offer the same deal: if one testifies for the prosecution against the other and the other remains silent, the betrayer goes free and the silent accomplice receives the full 10-year sentence. If both stay silent, both prisoners are sentenced to only six months in jail for a minor charge. If each betrays the other, each receives a two-year sentence. Each prisoner must make the choice of whether to betray the other or to remain silent. However, neither prisoner knows for sure what choice the other prisoner will make. So this dilemma poses the question: How should the prisoners act?

The dilemma can be summarized thus:


Prisoner B Stays Silent

Prisoner B Betrays

Prisoner A Stays Silent

Both serve six months

Prisoner A serves ten years
Prisoner B goes free

Prisoner A Betrays

Prisoner A goes free
Prisoner B serves ten years

Both serve two years

The dilemma arises when one assumes that both prisoners only care about minimizing their own jail terms. Each prisoner has two options: to cooperate with his accomplice and stay quiet, or to defect from their implied pact and betray his accomplice in return for a lighter sentence. The outcome of each choice depends on the choice of the accomplice, but each prisoner must choose without knowing what his accomplice has chosen to do.

Applications of Prisoner’s Dilemma in real life

Warning: These ideas move from the very serious to the downright crappy!! , so choose your order of reading, at your own risk

The Jews

If you look at the time line of Jews as a community, ever wondered why they had faced prosecution at the hands of various communities without putting up a fight and actually submitted themselves as slaves. The answer may lie in our analysis of the prisoner’s dilemma

Throughout history, the Jews have lived under the shadow of an immense future, believing in the promise of them being the chosen people, of their belief of a second coming. They lived as scattered communities in areas that were hostile to them or around people who initially saw them as a nuisance. Any sort of action, which was either “non cooperative” or even mildly unfriendly was dealt with severely. So they actually had a better chance surviving without putting up a fight or in PD terms cooperating and not defecting

This strategy worked well for two thousand years until they met the Nazis who seemed to have a mania to purge the world of Jews and carried out their systematic extermination for years to come. The hatred they had faced before had been less deeply rooted, or more inconsistent, or less violent.

That’s why today we see a more violent Israel than they had been in the past as Jewish people. The instinctive action would have been cooperation with the Nazis, which would have resulted in their extinction as race.


The Arms Race

The PD scenario is often used to illustrate the problem of two states engaged in an arms race. Both will reason that they have two options, either to increase military expenditure or to make an agreement to reduce weapons. Neither state can be certain that the other one will keep to such an agreement; therefore, they both incline towards military expansion. The paradox is that both states are acting "rationally", but producing an apparently "irrational" result.

Tour De France


Consider two cyclists halfway in a race, with a large group at great distance behind them. The two cyclists often work together (mutual cooperation) by sharing the tough load of the front position, where there is no shelter from the wind. If neither of the cyclists makes an effort to stay ahead, the group will soon catch up. An often-seen scenario is one cyclist doing the hard work alone (cooperating), keeping the two ahead of the group. In the end, this will likely lead to a victory for the second cyclist (defecting) who has an easy ride in the first cyclist's slipstream.

Advertising

Consider two companies A and B. If both Firm A and Firm B chose to advertise during a given period the advertising cancels out, sales remain constant, and expenses increase due to the cost of advertising. Both firms would benefit from a reduction in advertising. However, should Firm B choose not to advertise, Firm A could benefit greatly by advertising. Nevertheless, the optimal amount of advertising by one firm depends on how much advertising the other undertakes. As the best strategy is dependent of what the other firm chooses there is no dominant strategy and this is not a prisoner's dilemma. The outcome is though similar in that both firms would be better off were they to advertise less than in the equilibrium.

Relationships


From my (in)experience about love, the PD is very much applicable. We all have our dirty secrets, the skeletons waiting to tumble out of the closet. What would happen if two people in love want to share some secrets about their past they wouldn’t normally do

The dilemma can be summarized thus: *


Girl remains silent

Girl shares

Boy remains silent

And they live happily ever after

She will go along thinking all her life that all men are some breed of sexual perverts, with sex on their minds all the time ( err…hmm .ooh ) looking only for relationships as a way to show off his machismo and would be very apprehensive next time she commits.

Boy shares

His life is screwed, he will probably go mad for some time, in special cases turn to spirituality, start some sort of secret society which in extreme cases can lead to mass paranoia or run a helpline for relationship advice or look for another girl

If sensibility prevails, they stay together, with lots of guilt off their shoulders.

* Please see end of page. In case you don’t have the patience to read through or have already closed this window, the above observations are purely speculatory in nature

Engineering Vivas

I can already see a smile on your face. This reminds me of the countless vivas I have given to my really fundoo and esteemed Profs and to the moronic; linguistically challenged maniacally mugging machines called Ad- hocs. Here is a not so unfamiliar encounter of a fundoo ( albeit depressed in the end ) Prof and 3 engineers.

If you have been a true engineer, which I need’nt explain, but eventually will, knows nothing about his field of engineering, is always on the brink of getting into the short attendance list, occasionally making it there too, never did a journal on his own, believes that glass was made solely for the purpose of a glass trace and to taste other earthly liquid delights and serves no known scientific or industrial purpose, studied for the exam on the last night, or even better in the morning, doesn’t know where most of his laboratories are located, ends up sitting in the canteen all day ogling at god’s best creation, his fair draft of human beings after creating, man. He is the enlightened one who sincerely believes that the Vivas are places to learn, show off his spontaneous idea guzzling abilities, undo the work all those poor scientists have done by giving out of the world explanations to the most basic of questions. The very fact the you are reading this shows that you have loads of time to kill .Enough, I am already sympathising for the poor Profs. Back to prisoners dilemma and cut to Viva scene

Moi : Good morning Sir

P: good morning all, have a seat

P: it seems you have copied the readings. These do not match with the experiments we did in the lab .


Classic PD …what should the others do, keep shut and let hope float or bring down the house


E 1 : No sir, these are the same readings……..all others nod ( Huraay!! They have cooperated, I knew I could trust you guys )

Suddenly T1 (topper no 1 aka the Ghissoo, insatiable grade earner and GPA hungry, ready to exploit the system to screw his peers…classic PD again )

T 1: no sir, we have copied the readings from the senior’s journal.

All: ( Wtf!! I think we need to talk …and this one is going to be unpleasant. Hostel main mil…. Saari sincerity aur honesty nikaal denge..It seems he had an overdose of morality and ethics . )

P: I thought so. But at least you could have been honest with me. See T 1 had the courage to at least tell the truth. you $^%)%@)(!_&^@%

All : Its all over, CC pakka, now we shall re enroll in the elite 6 pointers club we have been so proud of, a heritage that will die only in our placement and B school interviews, inspired by 300, we decide to fight back )

P: anyways, what is the significance of the Nusselt number (don’t bother, neither did I)

T 1: starts off as if he has very few moments to live on this earth and he feels that he must share his pearls of wisdom with the ignorant, early man-ish, unintelligible, gibberish crowd giving him company at the teachers cabin. He follows his divine duty of enlightening us with ideas even nusslet hadn’t thought of, ensuring that his knowledge has a bearing on the generations to come


Prof is beaming, we are feeling like possessed men with blood shot eyes ready for the kill, only to be killed soon by the prof .

The rest is the question and question session between prof and students (physically available, mentally retarded) which might look very familiar to you, so I am not taking the pains to put you through all that

So basically each time the topper defects and the poor others end up screwing their GPA, their life and never the topper. Classic PD isn’t it?

P.S The prisoner's dilemma can be applied in economics, politics and sociology, as well as to the biological sciences such as ethnology and evolutionary biology. And I sincerely hope that coming this far and after being through 1953 words which make some sense, you don’t expect me to know all the above mentioned stuff.

10 comments:

Siddhartha Prakash said...

In your table you have analysed the theory in the context of two persons. This is very much true. This first thing that comes to my mind is consider the two persons (convicts or lovers) as one single entity to calculate total gain or loss. Common analysis shows that the maximum benefit for this entity as a whole is when both of them cooperate or both of them betray.
This theory will not hold for group. I dont agree with the generalisation for the group. consider a group where everyone betrays with each other. The example which you have given is not proper in the context in which the theory is developed. You have again divided the class into two entities and tried to define the gain and loss of one group of students versus one student. So you are able to derive correct result.
Since you have not considered the class where each one is betraying each other you have not really considered group. In group more dynamics come into play. For example say a group of 5 people A, B, C, D, E. There might be condition where A can cooperate with B but for this he has to betray C. This means that the case of total cooperation doesn't arise and is not possible. Then what is the solution. The solution is treating each and every pair of people in a group seperately and considering the total gain or loss of each pair.
Thus is A cooperates with B and betrays with C let the total gain for pair AB is 10 and the total gain for pair AC is -5(betrayal will lead to negative gain of course) and the net gain of BC is 0( because they didnt interact) and the net gain of all other pairs is 0 ( because they dont interact). In this case by the group theory A should go and betray C and cooperate with C. In simple terms this is called trade off and this determines our decision to betray Iraq and cooperate with US. This also holds true in war when you have to decide which one you want to save and in computer programming when we have to consider interdependence of functions and make a risk assessment of which one to change so that least others are affected and the total gain is maximum.
Read about the genius Dr. John Nash to learn more on group theory.

Thanks
Sid

ps: Its difficult to get a positive response from me on anything you write. All my friends know that. I feel my criticism will be more helpful than hypocrisy in your improvement.

2T aka Vamsee said...

I still remain mystified!

Utsav Mamoria said...

@ sid

i would appreciate your critical analysis. I didn't start this blog to earn praise and appreciation, i started it to put myself in a public domain and allow people to dissect my writings and help me improve. So i expect such critical comments in the future too. An insight from an educated mind always helps. So you needn't justify your criticism, it is more than welcome.

regarding your concept of group theory, what i meant was that in a classic case of a viva of what i have seen, its always the topper V/s the others. My assumption of considering the others as one entity, albeit flawed, holds true as we average students who are more or less on the same level, tend to cooperate by keeping our mouth shut and our behavior can be seen in actual scenarios.We do not betray each other as we are aware that co operation is the key to ensure maximum gain for all of us ( except the topper of course). I have strictly applied it to a scenario where all but one student are at an even keel. Hence, i am able to derive the correct result. I have not generalized it to other groups and scenarios as it will not be so simple and moreover i will then need to incorporate more variables and behaviors, which coming from my limited and nascent knowledge of the field, will not hold true.

anubhav said...

I slightly disagree with the jews and two nations theory.More factually in jews part and analytically in the nations part. In nations part the group theory(which SP says will be more applicable).

btw the moment I read the start of SP's comment,remembered that beautiful dialogue in the 'beautiful mind' when Russel crowe says "Adam smith was wrong"..and the explanation that followed was simply most brilliant way to explain the theory.

cheers,

yesha said...

ok ......now i get wat u keep on doing in surat other than studying .....nwaz cum 2 think of it we can assoiciate yure PD theory with half of the things that go around in the world .........but pls think bout it in jewish context .........and yeah we all know who real engii students are ha ha ha ha well wasent it enuf wen u pored all yure great epics in ccd ( just kiiding ....we all love listening 2 yure bakar ) nwaz cuming 2 the serious aspects ........do gimme more info on this PD thing ......yeh well the boi gal thing was a little speculatory as well ...try bringing it on more realistic terms ....the thing is if the gal speaks and the guy remains silent...he ll not say thing for the present but throw that same past in her face in future (only in anger while rowing furiously coz he aint got n thing better 2 defend himself)
else yure engii stuff was real entertainment .......i guess that should be enuf ......rest of it i ll post wen i find other flaws ...

Venky said...

finally read ur post..was postponing..well cudnt get too much into the PD. You diverted me many times..so no comments..it was fun readin though.. esp the viva thing..

Amlan Nanda said...

game theory rocks every time :)
though u found some very interesting fields of its application!!

Partha said...

Hey! I am better late than never being present on this forum where everyone has given so many comments!

Good one! U did some real good work!

I will give u two examples:

1. The Airlines Industry in India:
The emergence of the low cost airlines is causing great head aches for the established players like Indian and Jet-Sahara.

Now, divide the airlines into two parts... One: The established... Second: The Low frills and the new ones...

Now the case is that if both these groups cooperate with each other, then the losses in the revenues will decrease but that is not the case... The low cost carriers are not ready to cooperate with the established players... This is leading to huge losses for the industry as a whole.

2. Sid mentioned about wars. I would say in most of the cases, the solution set has two answers: Positive or Negative, Win or Loss, Death or Life etc. In wars also, there are usually two parties... Even if there are three countries at war with each other, at one point of time, one warrior can have only one enemy...suppose I am from country A and there are two other soldiers from country B and C. so when I am fighting the soldiers from B and C, then both B and C combine together to form one entity against me i.e. the ENEMY! That means u can always generalise a group into two factions and apply the PD.

I know this theory has its own set of limitations but I am sure it is very comprehensive and applicable, albeit with some kind of customization in each case.

Do read Nash's game theory... U will have an upper hand when u go for MBA ;)

Partha said...

ONE MORE THING:

The Viva case: See when in a viva you face a situation where the teacher could punish you for copying, then again there will be only two groups. One -> pro copying, another -> anti copying. Now during the final submission, again cooperation comes into picture. :) So having a group does not deter u from applying the theory.

And man! I am also not satisfied with the Israel thing... make it a bit clear to me!!!

Anonymous said...

Not for the sake of commenting friends, … one of the lucky few to hav known and interacted with utsav. Though only for 2-3 months, but I can 100% guarantee that…. he is one of the coolest guys to hang around with… Einstein was indeed right that time isn’t the same everywhere… it flies faster wit utsav around (courtesy: PAgal Meets :mg:)).. Really fun to be with utsavaaa…wud hav loved to study in the same class :gm:… Now enough of flattering, comin to PD of the blog, I wanted to comment on PD though not an expert in Game theory and all, bit still a curious guy who likes that.
In the PD, the two prisoner’s betray each other bcoz only defecting rather than cooperating will giv them the better result taking into account the other prisoner’s choices.( since by betraying, each expects to get a sentence of ½*12 months + 1/2* 0 months = 6 months, while by cooperating each expects a sentence for ½*120 months + ½*6 months = 63 months).
But in the Jews Example, the choice of the nazi’s to defect( to terminate the jews) or cooperate( to live as they had lived in the past) was independent of the jew’s decision, which isn’t the case in the actual PD.. In other words, the nazis had nothing to fear( the choices of Jews) but the jews had to depend on the choice of the Nazis…
Am I right?
The Arms race and the Advertising are definite classic examples of PD..
In the Tour De France, both the cyclists who are in front of the group actually can make their choices after knowing the choice of the other unlike the case in the PD….. the cyclist who is cooperating (going first) has an option to ride slowly for a moment and see if the second cyclist takes the initiative to go ahead. If the second cyclist doesn’t take the lead and slows down further, he makes it open his choice to the first cyclist. Now the first can decide wat to do based on the second person’s choices. Am I right?
In the boy-girl love example, the returns(benefits of mental satisfaction or agony or guilty feeling) that the boy will get wen the girl shares or the returns that the gal wil get wen the boy shares must also be specified to analyze this as a PD.. Bcoz one will share with the other only if he knows wat he/she will get if the other also does the same thing.
As for the Viva example . It definitely is a PD treating the group of six pointers as one and the topper as the other. But as a true PD, u guys too shud hav defaulted( accepted that u copied) since that’s the best that u can get given the choice that ur topper had with him.:)
Utsav, amazing blog dude.. I know how easy it is to criticize ;)…… Keep up the fabulous work. Waiting for ur explanation and ur next blog post.!