1 / 9

Example Matlab Simulation

Example Matlab Simulation. Based on Teaching Social Simulation with Matlab Journal of Artificial Societies and Social Simulation vol. 3, no. 1, <http://www.soc.surrey.ac.uk/JASSS/3/1/forum/1.htm. "Take it or leave it.". A friend is looking for a mate

lfink
Download Presentation

Example Matlab Simulation

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. Example Matlab Simulation

  2. Based on Teaching Social Simulation with MatlabJournal of Artificial Societies and Social Simulation vol. 3, no. 1, <http://www.soc.surrey.ac.uk/JASSS/3/1/forum/1.htm

  3. "Take it or leave it." • A friend is looking for a mate • Goal: Find matches that meet criterion number of desirable attributes in a mate: • honesty, intelligence, beauty, lets you cheat off them… • Different people have different numbers of these attributes - we give them a “score” based on the number of desirable attributes they have. - we can describe the population by a distribution on this score. • Picky friend makes a wants a “12”. • How hard will that be to achieve?

  4. Prospect distribution • Prospect’s scores are normally distributed and have mean 6, standard deviation 3. • Scores can be negative, but all scores are integers. Meanscore = 6; Stdscores = 3; NumberProspects = 1000; prospects=ceil(6+3*randn(1,NumberProspects)) This is your dating pool

  5. How many prospects for friend? goodones=find(prospects >= 12)

  6. Now what? • Which dates should the friend take? • How many possible matches? • That depends on the PROSPECT’s criteria • We need to know our friend’s score. Say it is a “10” • Assign each PROSPECT a criteria. • Let us say PROSPECT criteria are about +/-2 points from their own score on average. • Finally MATCHES are made first date that both exceed criteria.

  7. PROSPECT CRITERIA prospectcriteria=ceil(prospects+2*randn(1,NumberProspects))

  8. MATCH GAME Isdatablecount =0; For possibledates=1:NumberProspects, isdatable = prospects(possibledates)>=friendscriterion isdatablecount = isdatablecount +1; if isdatable, ismatch= friendsscore >= prospectscriterion(possibledates; if ismatch, matchscore = prospects(possibledates); break; end end end

  9. Be systematic! • What is the average match scores • As a function of friend’s score? • What is the effect of • Dating pool size • Pool quality

More Related