+ Reply to Thread
Results 1 to 27 of 27

Create unique combinations of individuals for triads

  1. #1
    Registered User
    Join Date
    09-22-2023
    Location
    Asheville, NC
    MS-Off Ver
    Office 365
    Posts
    5

    Create unique combinations of individuals for triads

    I have 12 training participants that I need to assign to triads (sets of 3), and I need to create as many unique groupings of them as possible (9, if possible). Does anyone have the formula or an example Excel sheet (without Macros, if possible) that I can use? I found several other examples in this forum, but I can't figure out how to adapt them for my needs. (Note, I may need to increase the number of individuals participating in these triads, so I'd like to find/build a template in Excel that I can keep using, despite the number of individuals participating. But they will always be triads or groups of 3.)

    Thanks!

  2. #2
    Administrator 6StringJazzer's Avatar
    Join Date
    01-27-2010
    Location
    Tysons Corner, VA, USA
    MS-Off Ver
    MS365 Family 64-bit
    Posts
    24,721

    Re: Create unique combinations of individuals for triads

    Welcome to the Forum H2D_IRR !

    Saying you are assigning people to triads is throwing me off here. Do you mean dividing the participants into teams of 3? When you say 9 groupings, you mean something like dividing them up into 4 teams of 3, and then dividing them again so none of the teams of 3 are the same as the first time, then doing this 9 times?

    I suggest attaching a sample file to show us what your input data looks like and a mock-up of what result you want.

    Also please update your profile to show an Excel version name, not a release number (like Excel 2019, Microsoft 365).
    Last edited by 6StringJazzer; 09-22-2023 at 03:28 PM.
    Jeff
    | | |會 |會 |會 |會 | |:| | |會 |會
    Read the rules
    Use code tags to [code]enclose your code![/code]

  3. #3
    Registered User
    Join Date
    09-22-2023
    Location
    Asheville, NC
    MS-Off Ver
    Office 365
    Posts
    5

    Re: Create unique combinations of individuals for triads

    Yes, a triad is a small group of 3 people. We have 12 people in the 9-session training course, so (as you said), we'd like to create as many diverse/unique triads as possible over the 9 sessions by dividing them up into 4 teams of 3, then dividing them again so none of the teams of 3 are the same as the first time, and then doing this 9 times, if possible.

    I don't have much at all to share, but attached is the list of names in the first column with the 9 different sessions listed out in the other columns. I manually created 3 unique sessions worth of triad groupings, but I can't think of any more unique combinations of triads.

    Plus, I'd love for Excel to do this thinking for me, especially for next time we have a training with potentially more people than the 12 we have. Does that make sense?

    Making Triads.xlsx

  4. #4
    Administrator 6StringJazzer's Avatar
    Join Date
    01-27-2010
    Location
    Tysons Corner, VA, USA
    MS-Off Ver
    MS365 Family 64-bit
    Posts
    24,721

    Re: Create unique combinations of individuals for triads

    This is actually turning out to be a tough problem. I am looking to see if I can develop a VBA solution but this could take some time.

    There are 1320 different triads you can make out of 12 people. Let's call each set of four triads a "grouping." It's not hard to generate the list of 1320 possible triads , but then you have to select groupings that are mutually exclusive and collectively exhaustive. Then on top of that you have to select more groupings that do not duplicate any of the triads in a previous grouping. I don't even know how to calculate how many that is.

    Another approach is to generate all permutations of 12 people (but that is probably prohibitive since it is almost 500 million) then select the permutations that each form four unique teams.

  5. #5
    Forum Expert
    Join Date
    01-25-2011
    Location
    Belgium, Alveringem
    MS-Off Ver
    Excel 2003, 2007, 365
    Posts
    1,418

    Re: Create unique combinations of individuals for triads

    1320 triads ??? Isn't it 220 ?
    Remember, saying thanks only takes a second or two. Click the little star * below, to give some Rep if you think an answer deserves it.

  6. #6
    Forum Moderator Glenn Kennedy's Avatar
    Join Date
    07-08-2012
    Location
    Digital Nomad... occasionally based in Ireland.
    MS-Off Ver
    O365 (PC) V 2403
    Posts
    44,101

    Re: Create unique combinations of individuals for triads

    If Triad 1 contains A, B & C, then triads 2, 3 & 4 for that session cannot contain any of A, B & C

    For the first triad you have a choice of 220 possible triads. For the second, 84, for the 3rd, 20 and for the 4th... just the one.
    Glenn




    None of us get paid for helping you... we do this for fun. So DON'T FORGET to say "Thank You" to all who have freely given some of their time to help YOU

  7. #7
    Forum Expert
    Join Date
    01-25-2011
    Location
    Belgium, Alveringem
    MS-Off Ver
    Excel 2003, 2007, 365
    Posts
    1,418

    Re: Create unique combinations of individuals for triads

    deleted - i made an error

    @Glenn, i make a better solution this evening ...
    Last edited by bsalv; 09-23-2023 at 11:16 AM.

  8. #8
    Forum Moderator Glenn Kennedy's Avatar
    Join Date
    07-08-2012
    Location
    Digital Nomad... occasionally based in Ireland.
    MS-Off Ver
    O365 (PC) V 2403
    Posts
    44,101

    Re: Create unique combinations of individuals for triads

    I think you did make an error. There are (I'm >>>almost<<< certain) "only" 325.

  9. #9
    Forum Expert
    Join Date
    01-25-2011
    Location
    Belgium, Alveringem
    MS-Off Ver
    Excel 2003, 2007, 365
    Posts
    1,418

    Re: Create unique combinations of individuals for triads

    15.400 ??? (column E)
    Attached Files Attached Files

  10. #10
    Forum Moderator Glenn Kennedy's Avatar
    Join Date
    07-08-2012
    Location
    Digital Nomad... occasionally based in Ireland.
    MS-Off Ver
    O365 (PC) V 2403
    Posts
    44,101

    Re: Create unique combinations of individuals for triads

    I think you're getting combinations and permutations confused, maybe... For 3 names out of 12 there are 220 combinations and 1320 permutations. Here, we're looking at combinations. For the next triad, there are only 9 to choose the next 3 from, etc, etc.

    I have only ever written one recursive lambda formula. This is what it needs to do.

    However, I've spent enough time on the EF for one day, so I'm off now.
    Attached Files Attached Files

  11. #11
    Administrator 6StringJazzer's Avatar
    Join Date
    01-27-2010
    Location
    Tysons Corner, VA, USA
    MS-Off Ver
    MS365 Family 64-bit
    Posts
    24,721

    Re: Create unique combinations of individuals for triads

    Quote Originally Posted by 6StringJazzer View Post
    There are 1320 different triads you can make out of 12 people.
    Quote Originally Posted by bsalv View Post
    1320 triads ??? Isn't it 220 ?
    Sorry, you are correct. There are 1320 permutations but for this application the order doesn't matter, so we care about 220 combinations.

  12. #12
    Forum Guru HansDouwe's Avatar
    Join Date
    06-21-2022
    Location
    Nederland
    MS-Off Ver
    365 V2403 (Build 17330.20000)
    Posts
    6,465

    Re: Create unique combinations of individuals for triads

    This formula returns 4 random triads, without duplicate persons:

    Formula: copy to clipboard
    Please Login or Register  to view this content.
    Every time when you press F9 a new random result of 4 random thriads will be returned.
    Attached Files Attached Files

  13. #13
    Forum Expert
    Join Date
    01-25-2011
    Location
    Belgium, Alveringem
    MS-Off Ver
    Excel 2003, 2007, 365
    Posts
    1,418

    Re: Create unique combinations of individuals for triads

    you have
    for table 1 combinations(12;3) = 220 combinations
    for table 2 combinations(9;3)= 84 combinations
    for table 3 combinations(6;3)= 20 combinations
    that makes 220*84*20 = 369.600 possibilities
    but you also have the permutations of the tables = 4! = 24

    369.600/24 = 15.400 = okay

  14. #14
    Forum Expert
    Join Date
    01-25-2011
    Location
    Belgium, Alveringem
    MS-Off Ver
    Excel 2003, 2007, 365
    Posts
    1,418

    Re: Create unique combinations of individuals for triads

    i lost myself in the discussion of how many possible solutions, with the macro "Making_10_4Triads", you 'll have 10 random solutions.
    Attached Files Attached Files

  15. #15
    Registered User
    Join Date
    09-22-2023
    Location
    Asheville, NC
    MS-Off Ver
    Office 365
    Posts
    5

    Re: Create unique combinations of individuals for triads

    Thank you so much for your input on this. However, it looks like none of your solutions completely work.

    When cross-referencing the sessions (i.e. each set of four triads) that you all offered, there are multiple repeated pairings from session to session to session. Meaning that all the sessions don't have completely unique combinations of people. At least two people end up in triads with the same people they'd been previously paired up with (even from Session One to Session Two, as shown in your various solutions). We need to try to somehow make as many completely unique combinations of triads without repeating any of them.

    From my original attempt of manually placing people into 4 teams of 3 for each session, I could only figure out 3 possible unique combinations, which means that we would need to start repeating combinations (of at least 2 out of 3 people in a triad) by the 4th session. Numerically, here are those 3 unique combinations/sessions:

    Session One:
    1, 2, 3
    4, 5, 6
    7, 8, 9
    10, 11, 12

    Session Two:
    1, 5, 9
    2, 6, 10
    3, 7, 11
    4, 8, 12

    Session Three:
    3, 4, 11
    6, 7, 12
    9, 10, 1
    2, 5, 8

    Are more than 3 completely unique combinations/sessions possible before people end up being paired up again with one another? If so, what would another combination/session look like?

  16. #16
    Forum Guru HansDouwe's Avatar
    Join Date
    06-21-2022
    Location
    Nederland
    MS-Off Ver
    365 V2403 (Build 17330.20000)
    Posts
    6,465

    Re: Create unique combinations of individuals for triads

    Even this combination with 3 sessions is not complete unique without people paired twice.

    Number 3 and 11 paired in Session 2 and 3.

  17. #17
    Forum Expert
    Join Date
    01-25-2011
    Location
    Belgium, Alveringem
    MS-Off Ver
    Excel 2003, 2007, 365
    Posts
    1,418

    Re: Create unique combinations of individuals for triads

    24 persons and 20 sessions = 66 couples 1 time and 277 couples twice
    You can change the number of persons and sessions in the macro
    Attached Files Attached Files

  18. #18
    Registered User
    Join Date
    09-22-2023
    Location
    Asheville, NC
    MS-Off Ver
    Office 365
    Posts
    5

    Re: Create unique combinations of individuals for triads

    Quote Originally Posted by HansDouwe View Post
    Even this combination with 3 sessions is not complete unique without people paired twice.

    Number 3 and 11 paired in Session 2 and 3.

    Ugggh... You're totally right.

  19. #19
    Registered User
    Join Date
    09-22-2023
    Location
    Asheville, NC
    MS-Off Ver
    Office 365
    Posts
    5

    Re: Create unique combinations of individuals for triads

    Quote Originally Posted by bsalv View Post
    24 persons and 20 sessions = 66 couples 1 time and 277 couples twice
    You can change the number of persons and sessions in the macro
    I have no idea how to read or use the spreadsheet you created... so I'm not sure this is what we need.

  20. #20
    Forum Expert
    Join Date
    01-25-2011
    Location
    Belgium, Alveringem
    MS-Off Ver
    Excel 2003, 2007, 365
    Posts
    1,418

    Re: Create unique combinations of individuals for triads

    Say you have 15 persons = 5 triads and you want 10 sessions, in the A1:E10 those triads. Person 1 = letter A, person 15 = letter L
    15 people = 105 possible couples and you want them as less as possible together.
    So in the solution in the attachment, 45 couples come twice and the rest (60) one time together.
    The triads for session 1 = A1:E1, the first triad = DNC = person 5 & person 14 & person 3, etc.

    I think that is the answer you wanted to know, give me for a multiple of 3 persons and so many sessions a balanced solution.
    The only thing, i still had to do, was the translation of all those triads to the names of the persons.
    (if you agree with this method)
    Attached Files Attached Files

  21. #21
    Forum Expert
    Join Date
    01-25-2011
    Location
    Belgium, Alveringem
    MS-Off Ver
    Excel 2003, 2007, 365
    Posts
    1,418

    Re: Create unique combinations of individuals for triads

    the posts #15-16 = 12 persons & 3 sessions = no couple twice in attachment

    PS. column AA = the couples (paires) and the integer part of column AB = the number of occurencies. (decimal part was for sorting), column AC = row and column of occurency
    AG1 = last 3 digits = number of couples with 1 occurency, next 3 digits = couples with 2 occurencies, etc
    Attached Files Attached Files
    Last edited by bsalv; 10-04-2023 at 05:43 AM.

  22. #22
    Forum Expert
    Join Date
    01-25-2011
    Location
    Belgium, Alveringem
    MS-Off Ver
    Excel 2003, 2007, 365
    Posts
    1,418

    Re: Create unique combinations of individuals for triads

    12 persons & 4 sessions = no couple twice
    Attached Files Attached Files

  23. #23
    Forum Expert
    Join Date
    01-25-2011
    Location
    Belgium, Alveringem
    MS-Off Ver
    Excel 2003, 2007, 365
    Posts
    1,418

    Re: Create unique combinations of individuals for triads

    12 persons & 5 sessions = 3 couples twice
    Attached Files Attached Files

  24. #24
    Valued Forum Contributor
    Join Date
    11-27-2011
    Location
    usa
    MS-Off Ver
    Excel 2007, Excel 365
    Posts
    495

    Re: Create unique combinations of individuals for triads

    I am so confused on what the actual objective is here.

    1 2 3
    4 5 6
    7 8 9
    10 11 12

    1 4 7
    1 5 8
    1 6 9
    2 4 8

    2 5 7
    2 6 10
    3 4 9
    3 5 10

    3 6 7
    3 8 11
    5 9 11
    6 8 12
    Last edited by johnnyL; 10-03-2023 at 10:41 PM. Reason: Corrected

  25. #25
    Valued Forum Contributor
    Join Date
    11-27-2011
    Location
    usa
    MS-Off Ver
    Excel 2007, Excel 365
    Posts
    495

    Re: Create unique combinations of individuals for triads

    When done on paper, the most unique combinations of 3 that I could come up (for 12 numbers) is 19 (it varies from 17 - 19 depending on the manual approach I took).

  26. #26
    Valued Forum Contributor
    Join Date
    11-27-2011
    Location
    usa
    MS-Off Ver
    Excel 2007, Excel 365
    Posts
    495

    Re: Create unique combinations of individuals for triads

    Did everyone give up on this project?

  27. #27
    Forum Expert
    Join Date
    01-25-2011
    Location
    Belgium, Alveringem
    MS-Off Ver
    Excel 2003, 2007, 365
    Posts
    1,418

    Re: Create unique combinations of individuals for triads

    @johnnyL, i'm waiting for a response of TS. After #19, i gave more information (no repetition of a duo/couple) and i want to know if this is okay.
    Your approach is looking for a repetition of a triad, you found it after 17-19 sessions, i don't think that's what TS wants.
    But there is only 1 person who knows the answer.

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. [SOLVED] Create unique combinations
    By zz_zz11 in forum Excel Formulas & Functions
    Replies: 6
    Last Post: 07-27-2023, 02:16 PM
  2. Create unique combinations
    By zz_zz11 in forum Excel Formulas & Functions
    Replies: 1
    Last Post: 07-27-2023, 02:06 AM
  3. [SOLVED] Create All Possible Age Combinations for Two Individuals
    By IGoCougsI in forum Excel General
    Replies: 5
    Last Post: 03-21-2021, 07:53 PM
  4. Power Pivot Formula to Generate Count of Unique Individuals' Info
    By RAdams1 in forum Excel Formulas & Functions
    Replies: 8
    Last Post: 11-16-2017, 02:41 PM
  5. [SOLVED] How to extract list of unique individuals from the master data set - Reg.
    By bala04msw in forum Excel Formulas & Functions
    Replies: 19
    Last Post: 08-26-2016, 06:40 AM
  6. Counting of triads for relation matrix :o
    By Carmine in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 08-06-2016, 03:26 PM
  7. Email merge unique messages to groups and individuals
    By RagingWahoo in forum Excel General
    Replies: 3
    Last Post: 10-12-2012, 01:15 PM

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1