; TO DO
;
GLOBALS
[ ; groupComposition [CHOOSER] ; Determines what flipset heuristic each member is assigned
; groupSize [SLIDER] ; Number of members in each group
; nDimensions [SLIDER] ; Number of dimensions in problem space
; nGroups [SLIDER] ; Number of groups to be run when the "Run nGroups" button is clicked
; PlotWhat? [CHOOSER] ; Determines what is ploted in the graph
; Print-Output-to-Interface? [SWITCH] ; When ON, a list of key model output values are displayed for each group in the output textbox on the interface
; Show-All-Possible-Solutions-In-History? [SWITCH] ; When ON, a complete list of all solutions in the solution space is provided at the beginning of the history for each group
; ShowHistory? [SWITCH] ; When ON, the step-by-step problem-solving history of each group discussion is output in the Command Center
; Show-Member-Flipsets-in-Output? [SWITCH] ; When ON, The flipset heuristic assigned to each member is displayed for each group in the output textbox on the interface
anyYet? ; Is set to TRUE after the first member in a given group generates the first solution
avgMaxValFound ; Average maxValFound across groups run so far
avgMaxValFound0 ; Average maxValFound across groups run so far when pCommunicate = 0
avgMaxValFound.2 ; Average maxValFound across groups run so far when pCommunicate = .2
avgMaxValFound.4 ; Average maxValFound across groups run so far when pCommunicate = .4
avgMaxValFound.6 ; Average maxValFound across groups run so far when pCommunicate = .6
avgMaxValFound.8 ; Average maxValFound across groups run so far when pCommunicate = .8
avgMaxValFound1 ; Average maxValFound across groups run so far when pCommunicate = 1
comCount ; Total number of times members communicated a just-found improvement in their currentBestValue
comMoveCount ; Number of times members move as a function of someone else communicating a just-found improvement in its currentBestValue (should alway be >= comCount)
flipset1 ; Potential groupMember problem-solving strategy (flip any one ranedomly selected element of the binary code)
flipset2 ; Potential groupMember problem-solving strategy (flip all but one randomly selected element of the binary code)
flipset3 ; Potential groupMember problem-solving strategy (flip any two adjacent randomly selected elements of the binary code)
flipsetMasterList ; List of all flipsets
gcbvHistoryM ; Historical record of which member found each of the group's new current best solutions (i.e., an ordered list of member who values)
gcbvHistoryS ; Historical record of the group's current best solutions (i.e., an ordered list of decimal solution IDs)
gcbvHistoryV ; Historical record of the group's current best values (i.e., an ordered list of solution values)
maxValFound ; Highest value found by group at end of run
moveCount ; Total number of times members move (last move, if any, at very end of run is not counted)
nFindingMaxVal ; Number of groups finding maximum possible value
nFindingMaxVal0 ; Number of groups finding maximum possible value when pCommunicate = 0
nFindingMaxVal.2 ; Number of groups finding maximum possible value when pCommunicate = .2
nFindingMaxVal.4 ; Number of groups finding maximum possible value when pCommunicate = .4
nFindingMaxVal.6 ; Number of groups finding maximum possible value when pCommunicate = .6
nFindingMaxVal.8 ; Number of groups finding maximum possible value when pCommunicate = .8
nFindingMaxVal1 ; Number of groups finding maximum possible value when pCommunicate = 1
nGroupsRun ; Number of groups run so far
nGroupsRun0 ; Number of groups run so far when pCommunicate = 0
nGroupsRun.2 ; Number of groups run so far when pCommunicate = .2
nGroupsRun.4 ; Number of groups run so far when pCommunicate = .4
nGroupsRun.6 ; Number of groups run so far when pCommunicate = .6
nGroupsRun.8 ; Number of groups run so far when pCommunicate = .8
nGroupsRun1 ; Number of groups run so far when pCommunicate = 1
nMembersMaxVal ; Number of members independently reaching maxValFound before the end of run
nSolutionsTested ; Total number of points in the solution space that were evaluated
pCommunicate ; Probability of communicating location of a just-found better currentBestValue to groupMates
solutionSpace ; List of values assigned to all points in a given solution space. The postion in the solution space is indicated by the position in the list.
solutionsTestedList ; List of solutions evaluation during run by any group member
sp? ; Is set to TRUE when the Setup button has been clicked
sumMaxValFound ; Sum maxValFound across groups run so far
sumMaxValFound0 ; Sum maxValFound across groups run so far when pCommunicate = 0
sumMaxValFound.2 ; Sum maxValFound across groups run so far when pCommunicate = .2
sumMaxValFound.4 ; Sum maxValFound across groups run so far when pCommunicate = .4
sumMaxValFound.6 ; Sum maxValFound across groups run so far when pCommunicate = .6
sumMaxValFound.8 ; Sum maxValFound across groups run so far when pCommunicate = .8
sumMaxValFound1 ; Sum maxValFound across groups run so far when pCommunicate = 1
steps2Solution ; Number of ticks needed to reach best solution found
%FindingMaxVal ; Percentage of groups run so far finding maximum possible value
%FindingMaxVal0 ; Percentage of groups run so far finding maximum possible value when pCommunicate = 0
%FindingMaxVal.2 ; Percentage of groups run so far finding maximum possible value when pCommunicate = .2
%FindingMaxVal.4 ; Percentage of groups run so far finding maximum possible value when pCommunicate = .4
%FindingMaxVal.6 ; Percentage of groups run so far finding maximum possible value when pCommunicate = .6
%FindingMaxVal.8 ; Percentage of groups run so far finding maximum possible value when pCommunicate = .8
%FindingMaxVal1 ; Percentage of groups run so far finding maximum possible value when pCommunicate = 1
%SolutionsTested ; Percentage of the solution space tested by the group as a whole
]
BREED [ members member]
BREED [ digits digit]
MEMBERS-OWN
[ changeSolution? ; Is set to TRUE when a new solution is tested and proves to have more value than currentBestSolution
currentBestSolution ; Decimal ID of solution with hightest value found so far by me (i.e., the position of that solution in the solutionSpace list)
currentBestValue ; Value of currentBestSolution
stopSearching? ; Is set to TRUE wehn the member has finished searching (b/c there is no better solution in its neighborhood), but may be reset to FALSE later if another member subsequently finds a new current best solution
doneSearchTick ; Last tick in which search occurred
exploreMore? ; Is set to TRUE when the current best solution is not randomly generated with no other input (i.e., not the result of flipping solution elements)
flippedList ; Digit(s) of currentBestSolution flipped without improving currentBestValue
listenStatus ; Is set to 1 when member hears announcement of, and adopts, a new best solution found by group so far
; Is set to 2 when member is listening, but no better solution is announced
; Is set to 0 when member is not listening
myFlipset ; The flipset heuristics held by each group member
myFlipsetLbl ; A label for each member's flipset heuristic (used for labeling output)
mySolutionsTestedList ; List of solutions evaluated by me
oldBestSolution ; Decimal ID of the immediately preceding currentBestSolution
oldBestValue ; Value of immediately preceding currentBestSolution
searchOrder ; Order in which members serarched for a better solution during a given tick
testSolutionBits ; Binary ID of solution to be evaluated next
testSolutionDec ; Decimal ID of solution to be evaluated next
testSolutionValue ; Value of new solution currently being tested
toFlip ; Digit(s) of currentBestSolution now being flipped
]
TO SetupPrimary ; Observer Context: Once, for all nGroups
clear-all
set avgMaxValFound 0
set avgMaxValFound0 0
set avgMaxValFound.2 0
set avgMaxValFound.4 0
set avgMaxValFound.6 0
set avgMaxValFound.8 0
set avgMaxValFound1 0
set nFindingMaxVal 0
set nFindingMaxVal0 0
set nFindingMaxVal.2 0
set nFindingMaxVal.4 0
set nFindingMaxVal.6 0
set nFindingMaxVal.8 0
set nFindingMaxVal1 0
set nGroupsRun 0
set nGroupsRun0 0
set nGroupsRun.2 0
set nGroupsRun.4 0
set nGroupsRun.6 0
set nGroupsRun.8 0
set nGroupsRun1 0
set sumMaxValFound 0
set sumMaxValFound0 0
set sumMaxValFound.2 0
set sumMaxValFound.4 0
set sumMaxValFound.6 0
set sumMaxValFound.8 0
set sumMaxValFound1 0
set %FindingMaxVal 0
set %FindingMaxVal0 0
set %FindingMaxVal.2 0
set %FindingMaxVal.4 0
set %FindingMaxVal.6 0
set %FindingMaxVal.8 0
set %FindingMaxVal1 0
resize-world 0 (nDimensions + 3) -1 groupSize
set-patch-size 40
ifelse Show-All-Possible-Solutions-In-History? = true and ShowHistory? = false
[ user-message "ShowHistory? must be ON in order to show all solution values in history."]
[ if (2 ^ nDimensions) > 100 and Show-All-Possible-Solutions-In-History? = true
[ if user-yes-or-no? (word "Setting Show-All-Solution-Values-in-History = ON will generate an extra " (2 ^ nDimensions) " lines of output per group. Do your really want to show these?") = false
[ set Show-All-Possible-Solutions-In-History? false]
]
]
if Show-Member-Flipsets-In-Output? = true and Print-Output-to-Interface? = false
[ user-message "Print-Output-to-Interface? must be ON in order to show member flipsets in the output window."]
MakeFlipsets
SetupSecondary
ask members [InitialView]
set sp? true
reset-ticks
END
TO MakeFlipsets ; Observer Context
set flipset1 (list) ; Will become the code for "flip any one randomly selected element of the binary code"
set flipset2 (list) ; Will become the code for "flip all but one randomly selected element of the binary code"
set flipset3 (list) ; Will become the code for "flip any two adjacent randomly selected elements of the binary code"
set flipsetMasterList (list)
let i 1
repeat nDimensions
[ set flipset1 lput i flipset1
let subFlipset2 (list)
let ii 1
repeat nDimensions
[ if ii != (nDimensions + 1) - i
[set subFlipset2 lput ii subFlipset2]
set ii ii + 1
]
set flipset2 lput subFlipset2 flipset2
let subFlipset3 (list)
ifelse i != nDimensions
[ set subFlipset3 lput i subFlipset3
set subFlipset3 lput (i + 1) subFlipset3
]
[ set subFlipset3 lput i subFlipset3
set subFlipset3 lput 1 subFlipset3
]
set flipset3 lput subFlipset3 flipset3
set i i + 1
]
set flipsetMasterList (list flipset1 flipset2 flipset3)
;show (word "flipsetMasterList = " flipsetMasterList) ; Save for Testing
END
TO InitialView ; Turtle Context: Initial view after Setup button is clicked
let indx 1
repeat nDimensions
[ ask patch indx ycor
[ set pcolor cyan + 4
sprout-digits 1
[ set color sky + 4
set shape "circle"
set size .95
]
set indx indx + 1
]
]
END
TO SetupSecondary ; Observer Context: For each group run
clear-turtles
reset-ticks
set anyYet? false
set comCount 0
set comMoveCount 0
set gcbvHistoryS (list)
set gcbvHistoryV (list)
set gcbvHistoryM (list)
set maxValFound 0
set moveCount 0
set nMembersMaxVal 0
set nSolutionsTested 0
set solutionsTestedList (list)
set steps2Solution 0
set %SolutionsTested 0
CreateSolutionSpace
CreateMembers
END
TO CreateSolutionSpace ; Observer Context
set solutionSpace (list)
let indx 0
repeat (2 ^ nDimensions)
[ set solutionSpace lput indx solutionSpace
set indx indx + 1
]
set solutionSpace shuffle solutionSpace
ask patches [ set pcolor white
set plabel ""
]
ask patches with [(pxcor > 0) and (pxcor < (max-pxcor - 2)) and (pycor > -1) and (pycor < max-pycor)]
[ set pcolor (10 *(random 14)) + 9]
ask patches with [(pxcor = (max-pxcor - 2)) and (pycor > -1) and (pycor < max-pycor)]
[ set pcolor brown + 3.5]
ask patches with [(pxcor = max-pxcor - 1) and (pycor > -1) and (pycor < max-pycor)]
[ set pcolor orange + 4]
let dimensionLabels (list "A" "B" "C" "D" "E" "F" "G" "H" "I" "J" "K" "L" "M" "N" "O" "P")
set indx 1
repeat nDimensions
[ ask patch indx max-pycor
[ set pcolor white
set plabel (word item (indx - 1) dimensionLabels " ")
set plabel-color black
set indx indx + 1
]
]
ask patch (max-pxcor - 2) max-pycor
[ set plabel "Slutn "
set plabel-color black
]
ask patch (max-pxcor - 1) max-pycor
[ set plabel "Value "
set plabel-color black
]
END
TO CreateMembers ; Observer Context
create-members groupSize
[ set xcor 0
set ycor who
set shape "person"
set size .8
if ycor = 0 [ set color red]
if ycor = 1 [ set color lime]
if ycor = 2 [ set color blue]
if ycor = 3 [ set color orange]
if ycor = 4 [ set color turquoise]
if ycor = 5 [ set color violet]
if ycor = 6 [ set color brown]
if ycor = 7 [ set color green]
if ycor = 8 [ set color magenta]
if ycor = 9 [ set color cyan]
if ycor = 10 [ set color pink]
if ycor = 11 [ set color grey]
set label who
set label-color black
ifelse groupComposition = "Heterogeneous"
[ if (who + 1) mod 3 = 1 ; Members 0, 3, 6, etc. get flipset1
[ set myFlipset flipset1
set myFlipsetLbl "Flipset Heuristic 1"
]
if (who + 1) mod 3 = 2 ; Members 1, 4, 7, etc. get flipset2
[ set myFlipset flipset2
set myFlipsetLbl "Flipset Heuristic 2"
]
if (who + 1) mod 3 = 0 ; Members 2, 5, 8, etc. get flipset3
[ set myFlipset flipset3
set myFlipsetLbl "Flipset Heuristic 3"
]
]
[ if groupComposition = "Flipset Heuristic 1" ; Otherwise all members get flipset1
[ set myFlipset flipset1]
if groupComposition = "Flipset Heuristic 2" ; Otherwise all members get flipset2
[ set myFlipset flipset2]
if groupComposition = "Flipset Heuristic 3" ; Otherwise all members get flipset3
[ set myFlipset flipset3]
set myFlipsetLbl groupComposition
]
set changeSolution? false
set listenStatus 0
set currentBestSolution -999
set currentBestValue -999
set stopSearching? false
set doneSearchTick 0
set flippedList (list)
set mySolutionsTestedList (list)
set oldBestSolution -999
set oldBestValue -999
set searchOrder -999
set testSolutionBits (list)
set testSolutionDec -999
set testSolutionValue -999
set toFlip (list)
]
END
TO Go ; Observer Context: Main schedule
repeat nGroups
[ set pCommunicate precision (.2 * (nGroupsRun mod 6)) 1 ; Every 6 groups, run one each with pCommunicate = 0.0, 0.2, 0.4, 0.6, 0.8, 1.0
ifelse sp? = false
[ SetupSecondary] ; Setup for each group
[ set sp? false] ; Setup for first group already done via Setup Button
if (Print-Output-to-Interface? = true) and (Show-Member-Flipsets-in-Output? = true)
[ PrintOutputToInterface "fs"]
let endWhile? false
while [ endWhile? = false]
[ ask members [ set searchOrder 0]
ifelse any? members with [stopSearching? = false]
[ tick
let i 0
ask members with [stopSearching? = false] ; Members who have not exhausted their search possibilities each test one new solution
[ set listenStatus 0
set i i + 1
set searchOrder i
AdjustCurrentSolution ; Determine where to start search from, if any
if exploreMore? = true
[ MaketestSolutionID ; Solution to evaluate next
TestTestSolution ; Evaluate that solution
]
if stopSearching? = true and not any? other members with [stopSearching? = false]
[ FinalizeGroupSolution
UpdateCumulativeResults
]
if not any? members with [stopSearching? = false] and Print-Output-to-Interface? = true
[ PrintOutputToInterface "results"]
if showHistory? = true [ ShowMemberHistory 1]
if showHistory? = true [ ShowMemberHistory 2]
]
]
[ set endWhile? true] ; Group is done
]
PlotResults "Avg"
PlotResults "Percent"
]
END
TO AdjustCurrentSolution ; Turtle Context: Start search from own currentBest, start search from group's best so far, or generate novel solution
ifelse anyYet? = false
[ set anyYet? true ; Generate novel starting position - Executed only for first move of first member
set currentBestSolution random (2 ^ nDimensions)
set currentBestValue item currentBestSolution solutionSpace
set testSolutionDec currentBestSolution
set testSolutionValue currentBestValue ; Don't actually test this value. Simply use it.
set gcbvHistoryV lput currentBestValue gcbvHistoryV ; Update list of current best values found by members
set gcbvHistoryS lput currentBestSolution gcbvHistoryS ; Update list of current best solutions found by members
set gcbvHistoryM lput who gcbvHistoryM ; Update list of members finding current best values
if not member? currentBestSolution mySolutionsTestedList
[ set mySolutionsTestedList lput currentBestSolution mySolutionsTestedList]
UpdateView
set changeSolution? true
set exploreMore? false ; Novel start position, so do not explore from here this round
]
[ ifelse random-float 1 < pCommunicate
[ set comCount comCount + 1 ; Add to communication count
ifelse currentBestValue < max gcbvHistoryV ; Move to the best solution found so far by others, but only if that solution is an improvment in value
[ set listenStatus 1
set flippedList []
set currentBestValue max gcbvHistoryV ; Update value
let p position currentBestValue gcbvHistoryV
set currentBestSolution item p gcbvHistoryS ; Update solution ID
if not member? currentBestSolution mySolutionsTestedList
[ set mySolutionsTestedList lput currentBestSolution mySolutionsTestedList]
set comMoveCount comMoveCount + 1 ; Add to move count due to communication
set moveCount moveCount + 1 ; Add to total move count
UpdateView
set changeSolution? true
set exploreMore? true ; Using group's current best, Explore further, if possible
]
[ set listenStatus 2
set exploreMore? true] ; Using own last round's current best, explore further, if possible
]
[ set listenStatus 0
ifelse currentBestSolution = -999 ; Generate novel starting position - Executed only for first move of other members, and only if they did not first move to the best solution found so far by the group
[ set currentBestSolution random (2 ^ nDimensions)
set currentBestValue item currentBestSolution solutionSpace
set testSolutionDec currentBestSolution
set testSolutionValue currentBestValue ; Don't actually test this value. Simply use it.
set gcbvHistoryV lput currentBestValue gcbvHistoryV ; Update list of current best values found by members
set gcbvHistoryS lput currentBestSolution gcbvHistoryS ; Update list of current best solutions found by members
set gcbvHistoryM lput who gcbvHistoryM ; Update list of members finding current best values
if not member? currentBestSolution mySolutionsTestedList
[ set mySolutionsTestedList lput currentBestSolution mySolutionsTestedList]
UpdateView
set changeSolution? true
set exploreMore? false ; Novel start position, so do not explore from here this round
]
[ set exploreMore? true] ; Using own last round's current best, explore further, if possible
]
]
END
TO MakeTestSolutionID ; Turtle Context
set testSolutionBits GetBinaryBitList currentBestSolution ; Create an ordered list of the binary digits for this location
let endWhile false
while [ endWhile = false]
[ let i random nDimensions
set toFlip item i myFlipset
if member? toFlip flippedList = false
[ set flippedList lput toFlip flippedList
set endWhile true
]
]
ifelse is-list? toFlip
[ foreach toFlip ; toFlip is itself a list. So flip all elmements indicated in list
[ i -> ifelse item (length testSolutionBits - i) testSolutionBits = 0
[ set testSolutionBits replace-item (length testSolutionBits - i) testSolutionBits 1]
[ set testSolutionBits replace-item (length testSolutionBits - i) testSolutionBits 0]
]
]
[ ifelse item (length testSolutionBits - toFlip) testSolutionBits = 0 ; toFlip is not a list. So flip onley the elmement indicated
[ set testSolutionBits replace-item (length testSolutionBits - toFlip) testSolutionBits 1]
[ set testSolutionBits replace-item (length testSolutionBits - toFlip) testSolutionBits 0]
]
set testSolutionDec GetDecimalNumber testSolutionBits ; Create the decimal value from the ordered list of binary digits for this location
if not member? testSolutionDec mySolutionsTestedList
[ set mySolutionsTestedList lput testSolutionDec mySolutionsTestedList]
END
TO TestTestSolution ; Turtle Context
set changeSolution? false
set oldBestSolution currentBestSolution ; Remember this for reporting history when a better solution is found
set oldBestValue currentBestValue ; Remember this for reporting history when a better solution is found
set testSolutionValue item testSolutionDec solutionSpace
ifelse testSolutionValue > currentBestValue ; If the test location has more value...
[ set changeSolution? true
set currentBestSolution testSolutionDec ; ... adopt it as the current best
set currentBestValue testSolutionValue
UpdateView
set flippedList [] ; Clear list of failed tests
set moveCount moveCount + 1 ; Add to total move count
set gcbvHistoryV lput currentBestValue gcbvHistoryV ; <== ValSeek(3.4.7) Modification ; Update list of current best values found by members
set gcbvHistoryS lput currentBestSolution gcbvHistoryS ; <== ValSeek(3.4.7) Modification ; Update list of current best solutions found by members
set gcbvHistoryM lput who gcbvHistoryM ; <== ValSeek(3.4.7) Modification ; Update list of members finding current best values
ask other members with [stopSearching? = true]
[ set stopSearching? false ; Restart search
set flippedList [] ; Clear list of failed tests
]
]
[ if length flippedList = length myFlipSet ; If all possible locations in neighborhood have been searched and none has more value...
[ set stopSearching? true ; Stop searching
set doneSearchTick ticks ; last tick in which search occurred
]
]
END
TO FinalizeGroupSolution ; Observer Context
set solutionsTestedList (list)
ask members
[ set solutionsTestedList sentence solutionsTestedList mySolutionsTestedList]
set solutionsTestedList sort remove-duplicates solutionsTestedList
set nSolutionsTested length solutionsTestedList
set %SolutionsTested (nSolutionsTested / (2 ^ nDimensions)) * 100
set maxValFound max [currentBestValue] of members
set nMembersMaxVal count members with [currentBestValue = maxValFound]
set steps2Solution ticks
ask members with [currentBestValue = maxValFound]
[ ask patches with [(pycor = [pycor] of myself) and (pxcor = max-pxcor)] ; Put check mark by all members who reached final group solution
[ sprout-digits 1
[ set heading 270
set shape "check"
set color grey + 3
set size .75
]
]
]
END
TO UpdateCumulativeResults ; Observer Context
set sumMaxValFound (sumMaxValFound + maxValFound)
set nGroupsRun nGroupsRun + 1
set avgMaxValFound (sumMaxValFound / nGroupsRun)
if maxValFound = ((2 ^ nDimensions) - 1) [ set nFindingMaxVal nFindingMaxVal + 1]
set %FindingMaxVal nFindingMaxVal / nGroupsRun * 100
(ifelse pCommunicate = 0 [ set sumMaxValFound0 (sumMaxValFound0 + maxValFound)
set nGroupsRun0 nGroupsRun0 + 1
set avgMaxValFound0 (sumMaxValFound0 / nGroupsRun0)
if maxValFound = ((2 ^ nDimensions) - 1) [ set nFindingMaxVal0 nFindingMaxVal0 + 1]
set %FindingMaxVal0 nFindingMaxVal0 / nGroupsRun0 * 100
]
pCommunicate = .2 [ set sumMaxValFound.2 (sumMaxValFound.2 + maxValFound)
set nGroupsRun.2 nGroupsRun.2 + 1
set avgMaxValFound.2 (sumMaxValFound.2 / nGroupsRun.2)
if maxValFound = ((2 ^ nDimensions) - 1) [ set nFindingMaxVal.2 nFindingMaxVal.2 + 1]
set %FindingMaxVal.2 nFindingMaxVal.2 / nGroupsRun.2 * 100
]
pCommunicate = .4 [ set sumMaxValFound.4 (sumMaxValFound.4 + maxValFound)
set nGroupsRun.4 nGroupsRun.4 + 1
set avgMaxValFound.4 (sumMaxValFound.4 / nGroupsRun.4)
if maxValFound = ((2 ^ nDimensions) - 1) [ set nFindingMaxVal.4 nFindingMaxVal.4 + 1]
set %FindingMaxVal.4 nFindingMaxVal.4 / nGroupsRun.4 * 100
]
pCommunicate = .6 [ set sumMaxValFound.6 (sumMaxValFound.6 + maxValFound)
set nGroupsRun.6 nGroupsRun.6 + 1
set avgMaxValFound.6 (sumMaxValFound.6 / nGroupsRun.6)
if maxValFound = ((2 ^ nDimensions) - 1) [ set nFindingMaxVal.6 nFindingMaxVal.6 + 1]
set %FindingMaxVal.6 nFindingMaxVal.6 / nGroupsRun.6 * 100
]
pCommunicate = .8 [ set sumMaxValFound.8 (sumMaxValFound.8 + maxValFound)
set nGroupsRun.8 nGroupsRun.8 + 1
set avgMaxValFound.8 (sumMaxValFound.8 / nGroupsRun.8)
if maxValFound = ((2 ^ nDimensions) - 1) [ set nFindingMaxVal.8 nFindingMaxVal.8 + 1]
set %FindingMaxVal.8 nFindingMaxVal.8 / nGroupsRun.8 * 100
]
pCommunicate = 1 [ set sumMaxValFound1 (sumMaxValFound1 + maxValFound)
set nGroupsRun1 nGroupsRun1 + 1
set avgMaxValFound1 (sumMaxValFound1 / nGroupsRun1)
if maxValFound = ((2 ^ nDimensions) - 1) [ set nFindingMaxVal1 nFindingMaxVal1 + 1]
set %FindingMaxVal1 nFindingMaxVal1 / nGroupsRun1 * 100
]
[ user-message "Error in running FinalizeGroupSolution Procedure!"]
)
END
TO-REPORT GetBinaryBitList [input] ; Observer Context: Converts a decimal number to an ordered list of binary digits representing that same number in base-2
let decVal input ; The decimal value
let bitList (list) ; A list of the binary digits will be put here
While [ decVal > 0]
[ let temp decVal mod 2
set bitList fput temp bitList
set decVal int (decVal / 2)
]
while [ length bitList < nDimensions]
[ set bitList fput 0 bitList]
report bitList
END
TO-REPORT GetDecimalNumber [input] ; Observer Context: Converts an ordered list of binary digits to a decimal value representing that same number in base-10
let bitList input ; The list of binary digits
let decVal 0 ; The dedimal value will be put here
let indx 0
let pwr (length bitList - 1)
repeat (length bitList - 1)
[ set decVal decVal + ((item indx bitList * 2) ^ pwr)
set indx indx + 1
set pwr (pwr - 1)
]
set decVal decVal + (item indx bitList)
report decVal
END
TO-REPORT SortWith [key inList] ; Turtle Context: Reports a list of lists sorted in order by the keyed item of the inner lists
report sort-by [ [a b] -> (runresult key a) < (runresult key b) ] inList
END
TO UpdateView ; Turtle Context
ask digits with [ycor = [ycor] of myself] [ die]
let cbsString (word currentBestSolution)
let cbsStringLength length cbsString
let space ""
repeat 6 - cbsStringLength
[ set space (word space " ")]
ask patch (nDimensions + 1) ycor
[ set plabel (word cbsString space) ; Display member's current solution decimal ID
set plabel-color black
]
let cbvString (word currentBestValue)
let cbvStringLength length cbvString
set space ""
repeat 6 - cbvStringLength
[ set space (word space " ")]
ask patch (nDimensions + 2) ycor
[ set plabel (word cbvString space) ; Display member's current best solution value
set plabel-color black
]
let cbsbitList GetBinaryBitList currentBestSolution ; Create an ordered list of the binary digits for this location
let indx 1
repeat nDimensions
[ ask patch indx ycor
[ set pcolor cyan + 4
sprout-digits 1
[ ifelse item (indx - 1) cbsbitList = 1
[ set color blue + 2
set shape "target"
]
[ set color sky + 4
set shape "circle"
]
set size .95
]
set indx indx + 1
]
]
END
TO PrintOutputToInterface [printWhat] ; Observer Context: Prints current best solution and best solution value to textbox on interface
if printWhat = "fs"
[ output-print "============================================================================="
output-print (Word "FOR " nDimensions "-DIMENSION PROBLEMS, THE FOLLOWING ARE THE AVAILABLE FLIPSET HEURISTICS:")
output-print "Flipset Heuristic 1: Flip any one randomly selected element of the binary code."
output-print (word " = "flipset1)
output-print "Flipset Heuristic 2: Flip all but one randomly selected element of the binary code."
output-print (word " = "flipset2)
output-print "Flipset Heuristic 3: Flip any two adjacent randomly selected elements of the binary code."
output-print (word " = "flipset3)
output-print ""
output-print "THE FLIPSET HEURISTICS ASSIGENED TO MEMBERS ARE:"
let memberList sort-by < members
foreach memberList
[ m -> ask m [ output-print (word " Member " who ": " myFlipsetLbl)]]
]
if printWhat = "results"
[ output-print (word "--------------------- Group " nGroupsRun " Results ---------------------")
output-print (word " Prob Communicate = " pCommunicate)
output-print (word " Max Possible Value = " ((2 ^ nDimensions) - 1))
output-print (word " max Value Found = " maxValFound)
output-print (word "% of Max Possible Val Found = " precision (maxValFound / ((2 ^ nDimensions) - 1) * 100) 1)
output-print (word "N Members Finding Max Value = " nMembersMaxVal)
output-print (word " Steps To Solution = " steps2Solution)
output-print (word " N Solutions Tested = " nSolutionsTested)
output-print (word " % Solutions Tested = " precision %SolutionsTested 1)
output-print (word " Communication Count = " comCount)
output-print (word " Commmunication Move Count = " comMoveCount)
output-print (word " Total Move Count = " moveCount)
output-print ""
]
END
TO PlotResults [plotWhat?] ; Observer Context: Plots average value found across all groups run so far, as well as percent of groups finding max value in solution space
let plotList (list)
ifelse plotWhat? = "Avg"
[ set-current-plot "Average Value Found"
clear-plot
set plotList (list avgMaxValFound0 avgMaxValFound.2 avgMaxValFound.4 avgMaxValFound.6 avgMaxValFound.8 avgMaxValFound1)
set-plot-background-color cyan + 4.5
]
[ set-current-plot "Percent Finding Max Value"
clear-plot
set plotList (list %FindingMaxVal0 %FindingMaxVal.2 %FindingMaxVal.4 %FindingMaxVal.6 %FindingMaxVal.8 %FindingMaxVal1)
set-plot-background-color violet + 4.5
]
let plotLL 0
let plotUL 1
if (min plotList) < (max plotList)
[ set plotLL (floor min plotList)
set plotUL (ceiling max plotList)
]
set-plot-y-Range plotLL plotUL
let indx 0
repeat 6 [ plotxy (indx * .2) (item indx plotList)
set indx indx + 1
]
END
TO ShowCodes ; Observer Context: Shows binary solution codes & Values in Command Center
let solutionID 0 ; Decimal Solution ID
repeat (2 ^ nDimensions)
[ let val item solutionID solutionSpace ; The value of this solution
let bitList GetBinaryBitList solutionID
let binID "" ; Binary Solution ID
let indx 0
repeat length bitList
[ set binID (word binID (item indx bitList))
set indx indx + 1
]
print (word "Solution = " solutionID " Binary = " binID " Value = " val)
set solutionID solutionID + 1
]
END
TO ShowMemberHistory [source] ; Turtle Context: Show run history in Command Center
if source = 1 and searchOrder = 1
[ let maxDecCode ((2 ^ nDimensions) - 1)
let maxBinCode ""
let maxBitList GetBinaryBitList maxDecCode
foreach maxBitList [ b -> set MaxBinCode (word MaxBinCode b)]
let varLength length (word (groupSize - 1)) + (2 * length (word maxDecCode)) + length (word maxBinCode)
let header1 (word "============================================================================")
let header2 ""
ifelse (pCommunicate = 0) or (pCommunicate = 1)
[ set header2 (word "============ Group " (nGroupsRun + 1) " pCommunicate = " pCommunicate " ============")]
[ set header2 (word "============ Group " (nGroupsRun + 1) " pCommunicate = " pCommunicate " ============")]
let header3 ""
ifelse not any? members with [stopSearching? = false]
[ set header3 (word "============================ Group " nGroupsRun " === Step " ticks " ============================")]
[ set header3 (word "============================ Group " (nGroupsRun + 1) " === Step " ticks " ============================")]
if ticks > 9
[set header1 remove-item ((length header1) - 1) header1
set header2 remove-item ((length header2) - 1) header2
set header3 remove-item ((length header3) - 1) header3
]
let indx 1
repeat varLength - 6
[ ifelse indx mod 2 = 1
[ set header1 (word header1 "=")
set header2 (word header2 "=")
set header3 (word header3 "=")
]
[ set header1 (word "=" header1)
set header2 (word "=" header2)
set header3 (word "=" header3)
]
set indx indx + 1
]
if ticks = 1
[ print header1
print header2
print header1
if Show-All-Possible-Solutions-In-History? = true [ ShowCodes]
]
print header3
]
if source = 2
[ let oldBinCode ""
let testBinCode ""
let oldBitList GetBinaryBitList oldBestSolution
let testBitList GetBinaryBitList testSolutionDec
foreach oldBitList [ b -> set oldBinCode (word oldBinCode b)]
foreach testBitList [ b -> set testBinCode (word testBinCode b)]
let memSpacer ""
if groupSize > 10
[ if length (word who) = 1
[set memSpacer " "]
]
let oldSpacer ""
let oldBestSpace length (word oldBestSolution)
let spaceMax length (word ((2 ^ nDimensions) - 1))
repeat spaceMax - oldBestSpace [ set oldSpacer (word oldSpacer " ")]
let testSpacer ""
let testSpace length (word testSolutionDec)
repeat spaceMax - testSpace [ set testSpacer (word testSpacer " ")]
;ifelse changeSolution? = true ; Save for testing
;[ show word " gcbvHistoryV but-last = " but-last gcbvHistoryV ; Save for testing
;show word " gcbvHistoryS = " but-last gcbvHistoryS ; Save for testing
;show word " gcbvHistoryM = " but-last gcbvHistoryM ; Save for testing
;] ; Save for testing
;[ show word " gcbvHistoryV = " gcbvHistoryV ; Save for testing
;show word " gcbvHistoryS = " gcbvHistoryS ; Save for testing
;show word " gcbvHistoryM = " gcbvHistoryM ; Save for testing
;] ; Save for testing
(ifelse
listenStatus = 0 [ print (word "Member " who memSpacer " Not Listening")]
listenStatus = 1 [ print (word "Member " who memSpacer " Announcement Heard: MOVING TO BEST SOLUTION FOUND SO FAR")]
listenStatus = 2 [ print (word "Member " who memSpacer " Listening, but No Better Solution Announced")]
[ show "ERROR IN IDENTIFYING LISTENING TYPE!"]
)
if oldBestValue = -999 [ set oldBinCode -999]
print (word "Member " who memSpacer " Current Best Solution = " oldBestSolution oldSpacer " BinCode = " oldBinCode " Current Best Value = " oldBestValue)
print (word "Member " who memSpacer " New Solution Tested = " testSolutionDec testSpacer " BinCode = " testBinCode " New Solution Value = " testSolutionValue)
if (stopSearching? = false) or ((stopSearching? = true) and (doneSearchTick = ticks))
[ print (word "Member " who memSpacer " Bit(s) flipped this tick = " toFlip)]
ifelse (changeSolution? = true) or (oldBestValue = -999)
[ print (word "Member " who memSpacer " >>> NEW SOLUTION ADOPTED & ANNOUNCED <<<")]
[ print (word "Member " who memSpacer " Old solution retained")]
ifelse (length flippedList > 0) and (is-list? item 0 flippedList = true)
[ let indx (length (item 0 flippedList)) - 1 ; Create sorted list of bit sets flipped so far
let sortOut flippedList
repeat length (item 0 flippedList)
[ set sortOut SortWith [ f -> item indx f ] sortOut
set indx indx - 1
]
print (word "Member " who memSpacer " Bit(s) flipped so far without improvement = " sortOut)
]
[ print (word "Member " who memSpacer " Bit(s) flipped so far without improvement = " sort flippedList)]
print (word "Member " who memSpacer " Stop Searching = " stopSearching?)
print ""
if stopSearching? = true and (any? other members with [stopSearching? = false] = false)
[ let len1 ""
let len2 ""
ifelse length (word nGroupsRun) mod 2 = 0
[ set len1 6 - (.5 * (length (word nGroupsRun))) ; If length of nGroupsRun is even, adjust len1 more than len2
set len2 6 - ((.5 * (length (word nGroupsRun))) - 1)
]
[ set len1 6 - (.5 * ((length (word nGroupsRun)) - 1)) ; If length of nGroupsRun is odd (except length = 1 ) adjust len1 and len2 equally
set len2 6 - (.5 * ((length (word nGroupsRun)) - 1))
]
let dashes1 ""
let dashes2 " "
repeat len1 [set dashes1 word dashes1 "-"]
repeat len2 [set dashes2 word dashes2 "-"]
let len3 length (word (position maxValFound solutionSpace))
let len4 length (word maxValFound)
let space ""
repeat round ((10 - len3 - len4) / 2) [ set space word space " "]
print (word "============================================")
print (word dashes1 " Best Solution Found by Group " nGroupsRun dashes2)
print (word space "Solution ID = " (position maxValFound solutionSpace) " Solution Value = " maxValFound)
print (word "============================================")
print ""
]
]
END
@#$#@#$#@
GRAPHICS-WINDOW
15
380
383
589
-1
-1
40.0
1
12
1
1
1
0
0
0
1
0
8
-1
3
0
0
1
ticks
30.0
BUTTON
180
10
250
43
Setup
SetupPrimary
NIL
1
T
OBSERVER
NIL
NIL
NIL
NIL
1
SLIDER
20
50
170
83
groupSize
groupSize
1
12
3.0
1
1
NIL
HORIZONTAL
CHOOSER
20
90
170
135
groupComposition
groupComposition
"Flipset Heuristic 1" "Flipset Heuristic 2" "Flipset Heuristic 3" "Heterogeneous"
0
OUTPUT
180
130
630
370
11
PLOT
860
55
1075
370
Percent Finding Max Value
Prob Communicate
Percent
0.0
1.0
0.0
10.0
true
false
"\n" "\n"
PENS
"default" 1.0 0 -16777216 true "" ""
SLIDER
20
9
170
42
nDimensions
nDimensions
4
16
5.0
1
1
NIL
HORIZONTAL
SWITCH
180
50
370
83
showHistory?
showHistory?
1
1
-1000
TEXTBOX
75
390
225
408
Solution Elements
14
0.0
1
SLIDER
480
10
630
43
nGroups
nGroups
1
100
1.0
1
1
NIL
HORIZONTAL
BUTTON
380
10
470
43
Run nGroups
Go
NIL
1
T
OBSERVER
NIL
NIL
NIL
NIL
0
BUTTON
260
10
369
43
Run Indefinitely
Go
T
1
T
OBSERVER
NIL
NIL
NIL
NIL
0
SWITCH
380
50
630
83
Show-All-Possible-Solutions-In-History?
Show-All-Possible-Solutions-In-History?
1
1
-1000
MONITOR
50
210
127
255
NIL
nGroupsRun
17
1
11
SWITCH
180
90
370
123
Print-Output-to-Interface?
Print-Output-to-Interface?
0
1
-1000
MONITOR
860
10
1075
55
n Groups Per Communication Level
nGroupsRun1
17
1
11
MONITOR
640
10
855
55
Maximim Possible Value
(2 ^ nDimensions) - 1
17
1
11
SWITCH
380
90
630
123
Show-Member-Flipsets-in-Output?
Show-Member-Flipsets-in-Output?
1
1
-1000
PLOT
640
55
855
370
Average Value Found
Prob Communicate
Average
0.0
1.0
0.0
10.0
true
false
"\n" ""
PENS
"default" 1.0 0 -16777216 true "" ""
@#$#@#$#@
# ValSeek(2.0)
Version Date: 3/4/2022
## WHAT IS IT?
ValSeek(2.0) explores the effect of diversity in members' problem-solving strategies on group problem-solving performance. The current version is a reinstantiation of the original model written in Microsoft Visual Basic 6.0 and described in Larson (2007). Note that the original model (version 3.4.7) had some capacities not reported in Larson (2007). Those unreported capacities are not implemented here.
The model derives its name from the value-seeking problems with which it is concerned. A value-seeking problem requires problem-solvers (whether individuals or groups) to sift through a set of solution alternatives that vary in value, with the goal of selecting a solution with the highest possible value. The value of a solution refers to its worth or desirability, or to the amount of satisfaction that can be derived from it. The model is restricted, however, to problems for which it is impractical to evaluate every possible solution alternative. For such problems, the strategies that problem-solvers use to navigate the solution space are critical to their performance.
### Value-Seeking Problems
Real-world value-seeking problems typically involve solutions with multiple distinct features or elements. Consider, for example, the task of creating a job offer to present to a highly sought-after candidate for a vacant research professorship. Among other things, it may be necessary to decide what salary will be proposed, what start date will be suggested, and what laboratory upgrades will be promised. The offer that is made—the specific combination of salary, start date, and upgrades actually written into the offer letter—constitutes the chosen solution to the problem. That solution is unique to the extent that its particular combination of elements differs in some respect from every other possible offer letter that might have been written instead. Changing any single element of the offer, even by a small amount, would constitute a different solution. The value of a given solution is a function of its costs and benefits. Offers that would be accepted by the candidate (the primary sought-after benefit) have more value than those that would be rejected, and acceptable offers that involve lower costs for the university (e.g., lower salary, earlier start date, and fewer laboratory upgrades) have more value than those involving higher costs.
Assembling a job offer is just one example of a value-seeking problem. Others include creating a marketing plan (what budget, form of advertising, and pricing structure will be employed) arranging a travel itinerary (what cities will be visited, and in what order), and designing an automobile (what engine, seating capacity, and passenger amenities will be specified). Indeed, almost any product of human invention, whether physical or abstract, can be seen as a solution to a value-seeking problem. Each exists because the problem-solver(s) believed (correctly or not) that its particular combination of elements would yield greater value than any other combination that might reasonably have been put forth.
Because solution elements can be combined in many different ways, value-seeking problems often have a very large number of solution alternatives, to the point that it becomes impractical to evaluate them all. Consider, for example, the problem that serves as the basis for the popular word game "Scrabble." The object of this game is to earn points by creating words from small sets of randomly chosen letters of the alphabet. At the outset of the game, the first player (or team) draws seven letters and attempts to construct a valid word from them. There are 13,699 ways in which a set of 7 letters might be arranged to form 1, 2, 3, 4, 5, 6, and 7 letter strings. Each of these is a possible solution to this seemingly simple word-formation problem. Of course, the majority of these strings will not be words found in the dictionary, and so will have no value at all. It is likely, however, that a few of them will be legitimate words. Furthermore, among the legitimate words, some are apt to have more value than others (because they are longer, involve letters with higher point values, or both). Because the player's goal is to score as many points as possible, he or she should choose the solution (word) with the highest point value. But it seems quite unlikely that players will consider every one of the 13,699 possible solutions when searching for the best word. Rather, players are apt to use a set of simplifying strategies to help them sift through the large number of possibilities. These strategies might be based, for example, on the frequency with which certain letter patterns typically occur (e.g., in English, the letter "q" is almost always followed by the letter "u"), or on what is cognitively easiest to manage (e.g., first construct short words, then try to build longer words from them). Such strategies can be effective in leading the problem solver relatively quickly to certain valuable solutions, at least when compared to an orderly search through all 13,699 possibilities. On the other hand, using such strategies will cause the player to ignore a great many solutions, some of which may in fact have a non-zero value (i.e., be real words). But if some legitimate words are overlooked, then it is also possible that one or more solutions with a higher value will go unrecognized. Thus, although a player may choose the word with the highest discovered value, he or she will not necessarily choose the word that is objectively best, simply because it is too big a task to evaluate every possible letter string.
It is convenient to conceptualize the relationship among the possible solutions to a value-seeking problem in terms of an _n_-dimensional space, where _n_ is the number of solution elements. Thus, each dimension represents a different element (e.g., in the faculty job-offer problem, one dimension would represent salary), each point on a given dimension reflects a different state of that element (e.g., the various salaries that might be offered), and each location within the _n_-dimensional space denotes a different combination of element states (e.g., a different offer letter). The task for the problem-solver is to move through this space in search of the one location with the greatest value.
For simplicity, ValSeek(2.0) only considers problems with binary solution elements, that is, elements with just two possible states (e.g., present vs. absent, new vs. used, analog vs. digital, high vs. low). Thus, a problem with three elements would have exactly 2^{3} = 8 different solution alternatives. ValSeek(2.0) can represent problems with from 3 to 16 binary elements, though even a 16-element problem is relatively simple when judged against the range of real-world value seeking problems.
An important point to note here is that a solution's value does not necessarily bear a simple linear relationship to the state of the solution elements. In the real world, solution elements sometimes contribute additively to the total value of a solution, but sometimes they contribute in complex, multiplicative ways. In the game of Scrabble, for example, the elements in a letter string contribute their separate point values to the value of the string as a whole only when that string forms a legitimate word. Thus, whether or not the letter C (worth 3 points) contributes value to a string depending on what other letters it is combined with and in what order (e.g., in English, it adds value in the string C-A-T, but not in either the string T-C-A or the string C-B-E). The same principle operates in many other contexts. For instance, incorporating an elevator bank into the design of a new parking garage is apt to add value to the project (i.e., make it more attractive to the architect's client) only if the garage exceeds a certain height. It also sometimes happens that when two elements are combined in the same product they create _less_ value than either would yield on its own. It is well known in the software industry, for example, that combining two or more otherwise-beneficial capabilities in the same software application can occasionally lead to unexpectedly poor performance, and even total system failure, because those functions interfere with one another in subtle but disastrous ways.
ValSeek(2.0) creates generic value-seeking problems by constructing systems of binary codes that represent sets of abstract solution alternatives, and randomly assigns a different value to each.^{1} It then simulates the activity of problem-solvers as they navigate their way from alternative to alternative in search of the one with the greatest value. Each different random mapping of values onto a set of solution alternatives expresses a different relationship between solution elements and total solution value, and so is a different value-seeking problem. By creating many such problems, and cumulating results across them, conclusions about simulated problem-solver behavior can be drawn that are independent of any particular element-value relationship.
### Modeling Problem-Solver Strategies
The model is centrally concerned with the strategies that problem-solvers use to guide their movement through the _n_-dimensional solution space. The solution space is presumed to be of such a magnitude that it is impractical for problem-solvers to canvas every conceivable solution. Consequently, strategies that require an examination of all possible alternatives before a solution is chosen are not considered. Nor is the model concerned in any fundamental way with the substance of the problem-solvers' strategies, except to the extent that one strategy can be differentiated from another. This is all that is required in order to simulate the effects of having diverse vs. homogeneous strategies when two or more problem-solvers work cooperatively to solve a generic value-seeking problem.
The strategies that simulated problem-solvers use to navigate the solution space are expressed in the model as "flipset heuristics." Following Hong and Page (2001), a flipset heuristic comprises one or more elementary instructions for changing one binary code to another, and so for shifting the simulated problem-solver's attention from one solution alternative to another. For example, consider again a problem with three binary elements, and so 2^{3} = 8 different solution alternatives. As noted, the relationship among those solutions can be represented in 3-dimensional space as a cube, with each corner of the cube being a unique solution. Those corners can each be identified by a different 3-digit binary code. The code 0-0-0, which identifies one particular corner (solution), can be changed to the code 0-0-1 (which identifies one of the three corners adjacent to it) by flipping its first element, where "flipping" means changing that element to its other possible state. (Note: Elements are numbered right to left, with the furthest element to the right being the first element). Subsequently, the binary code 0-0-1 can be changed to 0-1-0 (another corner or solution) by flipping both its first and second elements. A single instruction specifies the set of binary elements that are to be flipped at once: the flipset. Note that in the first example just given, the flipset comprised just one element of the binary code (the first), whereas in the second example it comprised two elements (the first and second). The size of the flipset can range from 1 to _n_, when _n_ is the length of the binary coding (viz., the dimensionality of the solution space). A given flipset heuristic may contain any number of flipset instructions.
It is important to recognize that a flipset instruction does not by itself determine which new solution alternative will be considered next. This also depends on the particular binary code to which the instruction is applied. Thus, the instruction "flip the first element" takes one to different locations in the solution space depending on whether it is applied to 0-0-0 (resulting in 0-0-1) or to 1-0-1 (resulting in 1-0-0). This is analogous to what happens when the driving instruction "turn left at the next intersection" is executed. One's location after making the turn depends both on the instruction and on one's location just before executing it (as anyone who has gotten lost in an unfamiliar city knows). Thus, flipset instructions specify incremental patterns of movement through the _n_-dimensional solution space, not particular locations within that space.
It is instructive to consider two further examples. The first is the flipset heuristic {1; 2; 3}. This heuristic consists of three different instructions. These are to "flip the first element of the binary code," "flip the second element of the binary code," and "flip the third element of the binary code," respectively. These three instructions are mutually exclusive, meaning that just one of them can be executed in a given problem-solving step. Further, no special priority or order of execution is implied by the order in which these instructions are listed. Rather, at every problem-solving step each instruction has an equal likelihood of being executed. This is consistent with the generic nature of the value-seeking problems being modeled, where there is no inherent priority among the solution elements themselves (i.e., across all possible problems, the solution elements contribute equally to solution value). Thus, assuming a 3-dimensional solution space, this flipset heuristic might be summarized as saying, "flip any one randomly selected element of the binary code."
Consider as well the flipset heuristic {1&2; 1&3; 2&3}. It too consists of three different instructions. Here, however, each instruction refers to two elements of the binary code. For example, "1&2" is an instruction to flip simultaneously the first two elements of that code. "1&3" and "2&3" are likewise interpreted as instructions to flip simultaneously two elements. As before, the instructions are mutually exclusive, and no special order of execution is implied by the order in which they are listed. Thus, again assuming a 3-dimensional solution space, this flipset heuristic can be summarized as saying, "flip all but one randomly selected element of the binary code."
### Modeling Individual Problem-Solving
ValSeek(2.0) models problem-solving as an activity that takes place in a series of discrete steps. Two things occur in each step: (a) the simulated problem-solver moves from her current location in the _n_-dimensional solution space to some new location, and (b) she evaluates the solution found at that new location. The problem solver moves from her current location to the new one by implementing one randomly selected instruction from her flipset heuristic. Evaluating the solution found at the new location entails two sub-steps. First, the absolute value of that solution is determined. This is accomplished simply by consulting a look-up table (a table that lists the binary codes for all possible solution, along with their randomly assigned values). Second, the value of the new solution is compared to that of the problem-solver's "current best solution," that is, the solution with the highest value previously encountered in all prior problem-solving steps. If the new solution has a higher value than the current best solution, then it becomes the new current best solution. On the other hand, if the new solution does not have a higher value than the current best solution, then it is abandoned. This move-and-evaluate process continues until no solution can be found that has a higher value than the current best solution, at which point the current best solution becomes the chosen solution, and problem-solving terminates.
Several points are worth noting. First, the problem-solving routine begins by choosing a starting location (binary code) at random, and evaluating the value of the solution found at that location. By default, no matter what its value, this solution becomes the current best solution (because it is the only one that has been evaluated so far). Thereafter, the problem-solver's flipset heuristic determines all subsequent locations to be evaluated.
Second, every problem-solving step except the first one begins at the location of the current best solution. Thus, the move that takes place at each problem-solving step is always a move away from the current best solution toward some other, not-yet-evaluated alternative. If the latter proves to have a higher value than the former, then it replaces the former as the current best solution, and the next move after that will proceed from the location of the new current best solution. On the other hand, if the new alternative does not have a higher value, then the simulated problem-solver retreats to the location of the current best solution, and uses it again as the starting point for a move to a different not-yet-evaluated alternative. Consequently, the problem-solver never strays more than one move from her current best solution.
Third, for every location in the _n_-dimensional solution space, the problem-solver's flipset heuristic defines a set of other locations that she can potentially reach in a single move (i.e., by executing one flipset instruction). These other locations constitute the solution neighborhood that the problem-solver can see from the location in question. Every location sits at the center of its own neighborhood, with the neighborhood's perceived composition—what can be "seen" by a given problem-solver—depending solely on the problem-solver's flipset heuristic. To illustrate, for a 3-dimension problem, if the problem-solver's flipset heuristic is {1; 2; 3}, then the neighborhood that can be seen from location 0-0-0 consists of locations 0-0-1, 0-1-0, and 1-0-0. On the other hand, if the problem-solver's flipset heuristic is {1&2; 1&3; 2&3}, the neighborhood that can be seen from location 0-0-0 consists of locations 0-1-1, 1-0-1, and 1-1-0.
ValSeek(2.0) simulates a problem-solver who searches for value only in the solution neighborhood she can see from the vantage point of her current best solution. That neighborhood is searched one alternative at a time, in random order, but stops as soon as an alternative is found that has more value than her current best solution. That alternative immediately becomes (i.e., replaces) the current best solution, and its perceived solution neighborhood is subsequently searched, again in random order. Thus, the simulated problem-solver employs a "hill-climbing" algorithm, a form of constrained stochastic behavior not unlike that shown to characterize scientific creativity (cf. Simonton, 2003). A notable feature of this algorithm is that if in a given neighborhood an alternative is discovered that has more value than the current best solution, but less value than one or more other not-yet-examined alternatives in that same neighborhood, those better-but-not-yet-examined alternatives will be overlooked, at least for the moment.
It is important to emphasize that problem-solvers always execute their flipset instructions in random order. Consequently, even when two simulated problem-solvers are endowed with identical flipset heuristics, and even when they start their search from exactly the same location (i.e., they have the same current best solution), their subsequent paths through the solution space may well diverge, implying that they will not necessarily end up with the same final solution. This also mean that having chosen a particular solution is no guarantee that another, higher-value solution does not exist.
### Modeling Group Problem-Solving
ValSeek(2.0) simulates the performance of groups of people who work collaboratively to solve a common problem. Working collaboratively implies that group members interact with one another to discuss the ideas and information they have that are relevant to solving the problem. In the case of value-seeking problems, an important category of information that members might discuss is the value of the solution alternatives they each have examined, particularly when they discover one that has greater value than their current best solution. These are the moments where it is most evident that progress is being made toward finding the solution with the greatest value.
ValSeek(2.0) can simulate up to 12 people working together to solve the same problem. The members each follow the step-wise problem-solving routine described above, with every member executing one problem-solving step before any member executes another step (the order in which members execute any given step is determined randomly; members cannot act simultaneously). Prior to running the simulation, each member is endowed with her own problem-solving strategy (i.e., flipset heuristic). This strategy might be the same across all members (strictly homogeneous) or it might vary from one member to the next (fully heterogeneous).^{2} Then, during the simulation each member follows the search routine described above. Thus, each enters the solution space at a random start location,^{3} and each employs her own flipset heuristic to guide her move-and-evaluate search process. The only difference between this and individual problem solving is that in a group context the members can communicate with one another whenever one of them updates her current best solution. Operationally, this is accomplished simply by having members announce to the group any time they find an alternative that is better than their previous best solution. The other members can then compare its value to their own current best solution. If for a given other member the new alternative has a higher value than her own current best solution, then that member too will adopt the announced solution as her own new current best, and so will also begin searching the neighborhood she perceives from that solution. If, on the other hand, the new alternative does not have a higher value than that other member's current best solution, it will be ignored by that other member, and she will continue searching the same solution neighborhood as before. Thus, communication about the discovered value of a new solution alternative may or may not impact another member’s path through the solution space, depending on the value of that other member’s own current best solution.
In the real world, problem-solving groups differ widely in how much interaction actually takes place among members. At one extreme are groups composed of highly voluble, attentive problem-solvers who not only verbalize every step of their own problem-solving activity, but also are keenly mindful of whatever progress their groupmates are making. Such groups display a very high degree of communication, with members seizing immediately on even the slightest value improvement identified by their groupmates. At the other extreme are groups composed of exceptionally taciturn problem-solvers who work in complete silence, paying no attention at all to one another until each has concluded her own search process. The only communication that occurs in such groups is at the very end, when the members announce their separately-found best solutions, and agree to adopt as their group solution the one with the highest value. Between these extremes are groups whose members verbalizing some, but not all, of their incremental successes, and attend to some, but not all, of what their groupmates have to say.
ValSeek(2.0) explores the impact of different levels of communication between members by systematically varying across groups the probability of communication. Specifically, members in the 1st through 6th groups run communicate with probabilities 0.0, 0.2, 0.4, 0.6, 0.8, and 1.0, respectively. Likewise for members in the 7th through 12th groups run, the 13th through 18th groups run, etc. When the probability of communication is 1.0, group members communicate each and every time one of them discovers an alternative that has a higher value than her own current best solution. By contrast, when the probability of communication is 0.0, no such communication occurs. When the probability of communication is at one of the intermediate values, members communicate about a discovered higher-value solution with a probability equal to that value. For example, when the probability of communication is 0.6, whenever any member discovers an alternative with a higher-value than her own current best solution, every other member has a 0.6 probability of becoming aware of the value of that alternative.^{4} In all cases, however, members always announced their final current best solution (i.e., the one that remains at the conclusion of their move-and-evaluate process), and the group as a whole always adopts the announced solution with the highest value.
## MODEL PARAMETERS
### nDimensions Slider
Determines the number of binary dimensions in the solution space. The total number of solutions in the space will be 2^{**nDimensions**}.
### groupSize Slider
Determines the number of members in each group.
### groupComposition Chooser
Determine the flipset heuristic assigned to each member. If `Flipset Heuristic 1` is selected, all members will be assigned Flipset Heuristic 1. Likewise for `Flipset Heuristic 2` and `Flipset Heuristic 3`. If `Heterogeneous` is selected, every third member will be assigned Flipset Heuristic 1, 2, or 3, respectively (e.g., in a 6-member group, Members 0 and 3 will be assigned Flipset Heuristic 1, Members 1 and 4 will be assigned Flipset Heuristic 2, and Members 2 and 5 will be assigned Flipset Heuristic 3. NOTE: Member IDs [`who` numbers] always begin at 0).
## RUN CONTROLS
### Setup Button
Clicking **Setup** clears all output from the two graphs and the textbox, and initializes all summary variables related to the cumulative results across groups (this is accomplished in the `SetupPrimary` procedure). The additional setup that is needed for each separate group occurs automatically (in the `SetupSecondary` procedure) as a part of the run.
### Run Indefinitely Button
Runs one simulated group after another until it is clicked again. The results shown in the graphs are averaged across all groups run since **Setup** was last clicked. If **Run Indefinitely** (or **Run nGroups**) is clicked again without first clicking **Setup**, additional groups will be added to the cumulative results. By contrast, if **Setup** is clicked before clicking **Run Indefinitely** (or **Run nGroups**) again, all of the old results will be lost, and only cumulative results for the newly run groups will be displayed.
### Run nGroups Button
Runs the number of groups indicated in the **nGroups** slider, then stops. This button is useful, for example, when the goal is to run a single group and inspect its history and/or final results.
### nGroups Slider
Determines the number of groups that will be run when the **Run nGroups** button is clicked.
### ShowHistory? Switch
When ON, the step-by-step problem-solving history of each group discussion is output in the Command Center. For each step, the history details which members were still searching in that step, who among them listened for announcements by others and, if listening, who switched to an announced better solution, what (after potentially switching) was each member's current best solution, what new alternative in that solution's neighborhood was tested by that member in that step, the value of both the current best solution and the newly evaluated alternative, whether the newly evaluated alternative was adopted as the member's new current best solution (always adopted if it of greater value), and if not, whether the member stopped searching (because no unevaluated alternatives remained in the current best solution's neighborhood as perceived by that member).
### Show-All-Possible-Solutions-In-History? Switch
When ON, a complete list of all solutions in the solution space, along with their values, is provided at the beginning of the history for each group. CAUTION: Depending on the value of **nDimensions**, this can generate a very large amount of output in the Command Center, and slows the model considerably. For this switch to function, the **ShowHistory?** switch must be ON.
### Print-Output-to-Interface? Switch
When ON, a list of key model output values is displayed for each group in the output textbox on the interface.
### Show-Member-Flipsets-in-Output? Switch
When ON, the flipset heuristic assigned to each member is displayed for each group in the output textbox on the interface. For this switch to function, the **Print-Output-to-Interface?** switch must be ON.
### Speed Slider
Near the top of the page is a speed slider. The model runs fastest when (a) the speed slider is moved all the way to the right, (b) **ShowHistory?** is OFF (showing each group’s history slows the model considerably) and **Print-Output-to-Interface?** is OFF. These settings are recommended when generating the model’s cumulative results (shown in the two graphs) over a large number of groups.
## MODEL OUTPUT
The primary output of interest is displayed in the two Graphs. The First plots the average value found by all groups run so far in each of the 6 communication probability conditions: 0.0, 0.2, 0.4, 0.6, 0.8, 1.0. The second graph plots the percentage of groups run so far in each of those same 6 conditions that found the highest possible value in the solution space.
The textbox summaries key results for each individual group (if the **Print-Output-to-Interface?** switch is ON).
## REPLICATING LARSON (2007)
To replicate the results reported in Larson (2007), set **nDimensions** = 5 and **groupSize** = 3. Then run the model 4 times, once for each possible setting in the **groupComposition** chooser. Stop each run when a total of 600,000 groups have been simulated (100,000 groups per communication level). The resulting output shown in the two graphs should approximate very closely one of the solid lines shown in Figures 3 and 4 of Larson (2007).
## POSSIBLE FUTURE DEVELOPMENTS OF THE MODEL
* Balance the two sides of the sender-receiver interaction (see Endnote #4), by representing separately the act of speaking about a newly found current best solution (_pAnnounce_) and listening for that announcement (_pListen_), with the probability of communication between any two members, **A** and **B**, being _pAnnounce__{A} * _pListen__{B}.
* Put a time limit on what members are able to here, for example by preventing them from hearing announcements made more than 1 step ago (i.e., they can hear announcements made by other members executing the same step they are currently on, or that were made during the immediately prior step, but not before that). This would better simulate face-to-face problem-solving discussions, where speaking and hearing are contemporaneous. This would also likely lead to members sometimes adopting announced alternatives that are better than their own current best solution but not necessarily the best found so far (and announced) by any group member.
* Give stronger emphasis to dyadic communication, with members initiating communication more often with some groupmates than others. This would allow for the formation of communication subgroups, where there is more communication within than between subgroups. Further it would allow for asymmetric communication patterns. For example, Member 0 might announce a newly found current best solution to Members 1 and 2 with _p_ = .9 & .3, respectively, whereas Member 1 might announce a new solution to Members 0 and 2 with _p_ = .5 & .7, respectively, and Member 2 might announce it to Members 0 and 1 with _p_ = .8 & .7, respectively. In this example, some communication relationships are symmetric (e.g., Members 1 and 2 announce to each other with _p_ = .7) whereas others are asymmetric (e.g., Member 0 announces to Member 1 with _p_ = .9, while Member 1 announces to Member 0 with _p_ = .5).
* In the real world, when one member communicates a just-found better solution that nevertheless is worse than another member's current best, it is likely that the latter member will be prompted to communicate her better solution in reply. The reply should prompt movement by other members whose current best solution is of less value, and should encourage the group as a whole to converge more quickly on the location that, at the moment, has the best solution of any found so far. As a consequence, enabling replies of this sort should lead groups to canvas less of the solution space, and so cause the group as a whole to choose final solutions that, on average, have less value than the solutions chosen when replies are not enabled.
* It would be interesting to create value "hills" in the solution space, then compare the performance of groups with different combinations of member types (flipsets), paying particular attention to whether some types contribute more to the final solution early vs. late in the problem-solving process.
## ENDNOTES
#### 1. Solution Space Representations
A problem's solution space is defined in the model by the content of the list variable `solutionSpace.` For example, the following list defines a 3-dimensional solution space with 8 possible solutions: [2 6 0 7 5 3 1 4]. Each item in the list gives the value associated with a different solution. The location of each solution in the 3-dimensional space (equivalently, the combination of elements that give rise to the listed value) is given by the binary representation of that solution's (decimal) position in the list. (Note: Positions in a list are indexed beginning at 0, not 1). So, the first item is Item 0 (binary 0-0-0) and has a value of 2, the second is Item 1 (binary 0-0-1) and has a value of 6, the third is Item 2 (binary 0-1-0) and has a value of 0, and so on.
#### 2. Problem-Solving Strategy Heterogeneity
Only 3 flipset heuristics are provided here (though others could be created). Consequently, maximum heterogeneity—where every member's flipset heuristic is different from that of every other member—is possible only with 3-person groups. Larger groups allow for only limited forms of heterogeneity, as some members will necessarily have the same flipset heuristic as others (see the description of the **groupComposition** chooser).
#### 3. Starting Location
For individual problem solving, and for group problem-solving when the probability of communication is set at 0.0, it is always true that the problem-solving routine begins by choosing a starting location (binary code) at random. On the other hand, for group problem solving when the probability of communication is greater than 0.0, the statement is strictly true only for the very first member to commence the problem-solving routine. The solution alternative at that member's randomly chosen starting location automatically becomes her initial current best solution, and is announced to the group. But because the probability of communication is greater than 0.0, the second member to commence may "hear" that announcement. If so, rather than beginning at a randomly chosen starting location, she will first move to the location of the announced current best solution and begin searching from there. This does not mean, however, that every member necessarily begins from the same starting location, even when the probability of communication is 1.0. Consider, for example, a 3-member group in which Member 0 commences the problem-solving routine first, Member 1 commences second, and Member 2 is the last to commence. Member 0 will announce the value of the solution at her randomly selected location, and if the probability of communication is 1.0, Member 1 will hear about it and move to it (because the solution at that location has at least some value, and Member 1 has no solution at all yet). Member 1 will then evaluate the solution alternative at one of the locations that her flipset heuristic allows here to reach from there. If the alternative at that location has a higher value than the one at the starting location, Member 1 will adopt and announce that new alternative as her current best solution. In this case, Member 2 (the last member to commence the problem-solving process) will hear that Member 1's solution is currently best, and move to that solution (not Member 0's solution). (Member 0 will also hear about Member 1's solution, and may move to it in the next problem-solving step, depending both on what Member 2 finds in the current problem-solving step, and the order in which members execute the next step.) Thus, it should be clear that when the probability of communication is greater than 0.0, only the first member to commence the problem-solving routing will necessarily start at a randomly selected location, and that two or more (and possibly all) members may start at the same location. But of course, even when every member commences the problem-solving routine at the same location, they may all still follow rather different paths through the solution space because they may have different flipset heuristics, and in any case always execute their flipset instructions in random order.
#### 4. Communication
As in the original version described in Larson (2007), ValSeek(2.0) models communication by focusing on the receiver side of the sender-receiver interaction. That is, members always announce the value of a new current best solution when one is found, but communication occurs only when an announcement is heard. Communication is thus simulated simply by having members "listen" for and "hear" the announcements made by others. When two or more other members announce new current best solutions, listening members always adopt the solution with the highest value. This means, in effect, that when hearing about and switching to an announced new current best solution, the switch is always to the best solution found so far by anyone in the group.
The opportunity to hear announcements about other members' newly found current best solutions occurs each time a member starts a new evaluation step in the problem-solving routine. Specifically, at the beginning of each step, members listen for announcements with _p_ equal to the probability of communication set for that group. If a member listens, and if an announcement has been made about a new alternative that is in fact better than her own current best solution, then that member will also adopt the announced solution as her current best, and will begin searching the solution neighborhood she can see from there. But if she does not listen, or if she does listens but either no announcement has been made or an announcement has been made about a new alternative that is not better than her own current best solution, then she will continue searching the neighborhood associated with here existing current best solution.
This approach to operationalizing communication is implemented here in order to faithfully replicating the original model as described in Larson (2007). However, it has several drawbacks. First, focusing exclusively on the receiver's side of the sender-receiver interaction makes this seem more like an attention parameter than a communication parameter (thought the two are obviously related). Second, each member has multiple opportunities to hear an announcement about a new current best solution found by someone else. A member will have as many opportunities to hear that announcement as there are still-unexplored alternatives in her current perceived solution neighborhood. Consequently, the effective probability of a member hearing any given announcement is actually higher than the nominal assigned probability of communication for that group. It is closer to 1 - (1 - _pC_)^{_n_}, where _pC_ is the nominal probability of communication for that group, and _n_ is the number of unexplored solutions in that member's current perceived solution neighborhood. (_n_ could be even larger than that, if one considers that an unexplored alternative may have a higher value than the member's current best solution—but still lower than the value of the announced solution—and so lead the member to yet another, and another, and another, etc., neighborhood to explore.) Because _n_ can vary across time for any one member, and across members at any one moment in time, the effective probability of hearing about the group's current best solution itself necessarily varies across time and members.
## REFERENCES
Hong, L., & Page, S. E. (2001). Problem solving by heterogeneous agents. _Journal of Economic Theory_, _97_, 123-163. https://doi.org/10.1006 jeth.2000.2709
Larson, J. R., Jr. (2007). Deep diversity and strong synergy: Modeling the impact of variability in members' problem-solving strategies on group problem-solving performance. _Small Group Research_, _38_, 413-436. https://doi.org/10.1177/1046496407301972
Simonton, D. K. (2003). Scientific creativity as constrained stochastic behavior: The Integration of product, person, and process perspectives. _Psychological Bulletin_, _129_, 475-494. https://doi.org/10.1037/0033-2909.129.4.475
## CODE AUTHOR
Jim Larson, Department of Psychology, Loyola University Chicago
@#$#@#$#@
default
true
0
Polygon -7500403 true true 150 5 40 250 150 205 260 250
airplane
true
0
Polygon -7500403 true true 150 0 135 15 120 60 120 105 15 165 15 195 120 180 135 240 105 270 120 285 150 270 180 285 210 270 165 240 180 180 285 195 285 165 180 105 180 60 165 15
arrow
true
0
Polygon -7500403 true true 150 0 0 150 105 150 105 293 195 293 195 150 300 150
box
false
0
Polygon -7500403 true true 150 285 285 225 285 75 150 135
Polygon -7500403 true true 150 135 15 75 150 15 285 75
Polygon -7500403 true true 15 75 15 225 150 285 150 135
Line -16777216 false 150 285 150 135
Line -16777216 false 150 135 15 75
Line -16777216 false 150 135 285 75
bug
true
0
Circle -7500403 true true 96 182 108
Circle -7500403 true true 110 127 80
Circle -7500403 true true 110 75 80
Line -7500403 true 150 100 80 30
Line -7500403 true 150 100 220 30
butterfly
true
0
Polygon -7500403 true true 150 165 209 199 225 225 225 255 195 270 165 255 150 240
Polygon -7500403 true true 150 165 89 198 75 225 75 255 105 270 135 255 150 240
Polygon -7500403 true true 139 148 100 105 55 90 25 90 10 105 10 135 25 180 40 195 85 194 139 163
Polygon -7500403 true true 162 150 200 105 245 90 275 90 290 105 290 135 275 180 260 195 215 195 162 165
Polygon -16777216 true false 150 255 135 225 120 150 135 120 150 105 165 120 180 150 165 225
Circle -16777216 true false 135 90 30
Line -16777216 false 150 105 195 60
Line -16777216 false 150 105 105 60
car
false
0
Polygon -7500403 true true 300 180 279 164 261 144 240 135 226 132 213 106 203 84 185 63 159 50 135 50 75 60 0 150 0 165 0 225 300 225 300 180
Circle -16777216 true false 180 180 90
Circle -16777216 true false 30 180 90
Polygon -16777216 true false 162 80 132 78 134 135 209 135 194 105 189 96 180 89
Circle -7500403 true true 47 195 58
Circle -7500403 true true 195 195 58
check
false
0
Polygon -7500403 true true 55 138 22 155 53 196 72 232 91 288 111 272 136 258 147 220 167 174 208 113 280 24 257 7 192 78 151 138 106 213 87 182
circle
false
0
Circle -7500403 true true 0 0 300
circle 2
false
0
Circle -7500403 true true 0 0 300
Circle -16777216 true false 30 30 240
cow
false
0
Polygon -7500403 true true 200 193 197 249 179 249 177 196 166 187 140 189 93 191 78 179 72 211 49 209 48 181 37 149 25 120 25 89 45 72 103 84 179 75 198 76 252 64 272 81 293 103 285 121 255 121 242 118 224 167
Polygon -7500403 true true 73 210 86 251 62 249 48 208
Polygon -7500403 true true 25 114 16 195 9 204 23 213 25 200 39 123
cylinder
false
0
Circle -7500403 true true 0 0 300
dot
false
0
Circle -7500403 true true 90 90 120
face happy
false
0
Circle -7500403 true true 8 8 285
Circle -16777216 true false 60 75 60
Circle -16777216 true false 180 75 60
Polygon -16777216 true false 150 255 90 239 62 213 47 191 67 179 90 203 109 218 150 225 192 218 210 203 227 181 251 194 236 217 212 240
face neutral
false
0
Circle -7500403 true true 8 7 285
Circle -16777216 true false 60 75 60
Circle -16777216 true false 180 75 60
Rectangle -16777216 true false 60 195 240 225
face sad
false
0
Circle -7500403 true true 8 8 285
Circle -16777216 true false 60 75 60
Circle -16777216 true false 180 75 60
Polygon -16777216 true false 150 168 90 184 62 210 47 232 67 244 90 220 109 205 150 198 192 205 210 220 227 242 251 229 236 206 212 183
fish
false
0
Polygon -1 true false 44 131 21 87 15 86 0 120 15 150 0 180 13 214 20 212 45 166
Polygon -1 true false 135 195 119 235 95 218 76 210 46 204 60 165
Polygon -1 true false 75 45 83 77 71 103 86 114 166 78 135 60
Polygon -7500403 true true 30 136 151 77 226 81 280 119 292 146 292 160 287 170 270 195 195 210 151 212 30 166
Circle -16777216 true false 215 106 30
flag
false
0
Rectangle -7500403 true true 60 15 75 300
Polygon -7500403 true true 90 150 270 90 90 30
Line -7500403 true 75 135 90 135
Line -7500403 true 75 45 90 45
flower
false
0
Polygon -10899396 true false 135 120 165 165 180 210 180 240 150 300 165 300 195 240 195 195 165 135
Circle -7500403 true true 85 132 38
Circle -7500403 true true 130 147 38
Circle -7500403 true true 192 85 38
Circle -7500403 true true 85 40 38
Circle -7500403 true true 177 40 38
Circle -7500403 true true 177 132 38
Circle -7500403 true true 70 85 38
Circle -7500403 true true 130 25 38
Circle -7500403 true true 96 51 108
Circle -16777216 true false 113 68 74
Polygon -10899396 true false 189 233 219 188 249 173 279 188 234 218
Polygon -10899396 true false 180 255 150 210 105 210 75 240 135 240
house
false
0
Rectangle -7500403 true true 45 120 255 285
Rectangle -16777216 true false 120 210 180 285
Polygon -7500403 true true 15 120 150 15 285 120
Line -16777216 false 30 120 270 120
leaf
false
0
Polygon -7500403 true true 150 210 135 195 120 210 60 210 30 195 60 180 60 165 15 135 30 120 15 105 40 104 45 90 60 90 90 105 105 120 120 120 105 60 120 60 135 30 150 15 165 30 180 60 195 60 180 120 195 120 210 105 240 90 255 90 263 104 285 105 270 120 285 135 240 165 240 180 270 195 240 210 180 210 165 195
Polygon -7500403 true true 135 195 135 240 120 255 105 255 105 285 135 285 165 240 165 195
line
true
0
Line -7500403 true 150 0 150 300
line half
true
0
Line -7500403 true 150 0 150 150
pentagon
false
0
Polygon -7500403 true true 150 15 15 120 60 285 240 285 285 120
person
false
0
Circle -7500403 true true 110 5 80
Polygon -7500403 true true 105 90 120 195 90 285 105 300 135 300 150 225 165 300 195 300 210 285 180 195 195 90
Rectangle -7500403 true true 127 79 172 94
Polygon -7500403 true true 195 90 240 150 225 180 165 105
Polygon -7500403 true true 105 90 60 150 75 180 135 105
plant
false
0
Rectangle -7500403 true true 135 90 165 300
Polygon -7500403 true true 135 255 90 210 45 195 75 255 135 285
Polygon -7500403 true true 165 255 210 210 255 195 225 255 165 285
Polygon -7500403 true true 135 180 90 135 45 120 75 180 135 210
Polygon -7500403 true true 165 180 165 210 225 180 255 120 210 135
Polygon -7500403 true true 135 105 90 60 45 45 75 105 135 135
Polygon -7500403 true true 165 105 165 135 225 105 255 45 210 60
Polygon -7500403 true true 135 90 120 45 150 15 180 45 165 90
sheep
false
15
Circle -1 true true 203 65 88
Circle -1 true true 70 65 162
Circle -1 true true 150 105 120
Polygon -7500403 true false 218 120 240 165 255 165 278 120
Circle -7500403 true false 214 72 67
Rectangle -1 true true 164 223 179 298
Polygon -1 true true 45 285 30 285 30 240 15 195 45 210
Circle -1 true true 3 83 150
Rectangle -1 true true 65 221 80 296
Polygon -1 true true 195 285 210 285 210 240 240 210 195 210
Polygon -7500403 true false 276 85 285 105 302 99 294 83
Polygon -7500403 true false 219 85 210 105 193 99 201 83
square
false
0
Rectangle -7500403 true true 30 30 270 270
square 2
false
0
Rectangle -7500403 true true 30 30 270 270
Rectangle -16777216 true false 60 60 240 240
star
false
0
Polygon -7500403 true true 151 1 185 108 298 108 207 175 242 282 151 216 59 282 94 175 3 108 116 108
target
false
0
Circle -7500403 true true 0 0 300
Circle -16777216 true false 30 30 240
Circle -7500403 true true 60 60 180
Circle -16777216 true false 90 90 120
Circle -7500403 true true 120 120 60
tree
false
0
Circle -7500403 true true 118 3 94
Rectangle -6459832 true false 120 195 180 300
Circle -7500403 true true 65 21 108
Circle -7500403 true true 116 41 127
Circle -7500403 true true 45 90 120
Circle -7500403 true true 104 74 152
triangle
false
0
Polygon -7500403 true true 150 30 15 255 285 255
triangle 2
false
0
Polygon -7500403 true true 150 30 15 255 285 255
Polygon -16777216 true false 151 99 225 223 75 224
truck
false
0
Rectangle -7500403 true true 4 45 195 187
Polygon -7500403 true true 296 193 296 150 259 134 244 104 208 104 207 194
Rectangle -1 true false 195 60 195 105
Polygon -16777216 true false 238 112 252 141 219 141 218 112
Circle -16777216 true false 234 174 42
Rectangle -7500403 true true 181 185 214 194
Circle -16777216 true false 144 174 42
Circle -16777216 true false 24 174 42
Circle -7500403 false true 24 174 42
Circle -7500403 false true 144 174 42
Circle -7500403 false true 234 174 42
turtle
true
0
Polygon -10899396 true false 215 204 240 233 246 254 228 266 215 252 193 210
Polygon -10899396 true false 195 90 225 75 245 75 260 89 269 108 261 124 240 105 225 105 210 105
Polygon -10899396 true false 105 90 75 75 55 75 40 89 31 108 39 124 60 105 75 105 90 105
Polygon -10899396 true false 132 85 134 64 107 51 108 17 150 2 192 18 192 52 169 65 172 87
Polygon -10899396 true false 85 204 60 233 54 254 72 266 85 252 107 210
Polygon -7500403 true true 119 75 179 75 209 101 224 135 220 225 175 261 128 261 81 224 74 135 88 99
wheel
false
0
Circle -7500403 true true 3 3 294
Circle -16777216 true false 30 30 240
Line -7500403 true 150 285 150 15
Line -7500403 true 15 150 285 150
Circle -7500403 true true 120 120 60
Line -7500403 true 216 40 79 269
Line -7500403 true 40 84 269 221
Line -7500403 true 40 216 269 79
Line -7500403 true 84 40 221 269
wolf
false
0
Polygon -16777216 true false 253 133 245 131 245 133
Polygon -7500403 true true 2 194 13 197 30 191 38 193 38 205 20 226 20 257 27 265 38 266 40 260 31 253 31 230 60 206 68 198 75 209 66 228 65 243 82 261 84 268 100 267 103 261 77 239 79 231 100 207 98 196 119 201 143 202 160 195 166 210 172 213 173 238 167 251 160 248 154 265 169 264 178 247 186 240 198 260 200 271 217 271 219 262 207 258 195 230 192 198 210 184 227 164 242 144 259 145 284 151 277 141 293 140 299 134 297 127 273 119 270 105
Polygon -7500403 true true -1 195 14 180 36 166 40 153 53 140 82 131 134 133 159 126 188 115 227 108 236 102 238 98 268 86 269 92 281 87 269 103 269 113
x
false
0
Polygon -7500403 true true 270 75 225 30 30 225 75 270
Polygon -7500403 true true 30 75 75 30 270 225 225 270
@#$#@#$#@
NetLogo 6.2.2
@#$#@#$#@
@#$#@#$#@
@#$#@#$#@
SetupPrimary
Go
maxValueFound
nMembersMaxVal
ticks2Solution
nSolutionsTested
%SolutionsTested
comCount
comMoveCount
moveCount
SetupPrimary
Go
maxValueFound
nMembersMaxVal
ticks2Solution
nSolutionsTested
%SolutionsTested
comCount
comMoveCount
moveCount
SetupPrimary
Go
maxValueFound
nMembersMaxVal
ticks2Solution
nSolutionsTested
%SolutionsTested
comCount
comMoveCount
moveCount
@#$#@#$#@
@#$#@#$#@
default
0.0
-0.2 0 0.0 1.0
0.0 1 1.0 0.0
0.2 0 0.0 1.0
link direction
true
0
Line -7500403 true 150 150 90 180
Line -7500403 true 150 150 210 180
@#$#@#$#@
1
@#$#@#$#@