+ Reply to Thread
Results 1 to 4 of 4

All Possible Combination from 1 List with an Specific Arrangement

  1. #1
    Registered User
    Join Date
    01-19-2019
    Location
    Mexico
    MS-Off Ver
    2016
    Posts
    4

    All Possible Combination from 1 List with an Specific Arrangement

    Hello to all,

    I have been trying to learn and understand a bit more of excel for the last year, and I think I now have some minor / medium knowledge. I have always found the solution by testing and doing research but this time I could not find anything that would solve the problem exactly as I need it so I had to post it and ask for help to this lovely community.

    I am an Engineering and Production Manager (non-software related) and in my company the "production system" is very (for the lack of a better word) archaic, the volume of production changes constantly and the options which apply to certain part numbers go in the range of thousands, so optimizing labor is a task of exhausting hard work and there is not a systemic approach to it. As of right now I have created a tool that helps my employees a lot, but to finish this master piece (I want to call it that way ) I am still missing one thing. Which is what I am asking for help here, so here we go.

    I have a "dynamic size list" that could have 3 - 180 components, maybe even more, this components are "work loads for each production operator" and we will name them with a letter on this example, so for this list I need to create all possible combinations that could exist. Lets say I have 4 operator work loads, first called A that has a 49% value, B that has a 37% value, C that has a 51% value and D that has a 30% value. I want to create a matrix that has all possible combinations so then I can add everything up and automatically with some formula choose the one closest to ~93% (I am not worried about the formula I am confident I can come up with that one easily, the thing I have no idea of how to do is how to create the matrix)

    I know this could be solved with VBA, I am really not very good with it and I am pretty sure that my people hate working with excel files that have MACROS, since I am doing this for them and they will be the users of this I would prefer a simple formula, but if this is not possible with formulas I would still appreciate a VBA code.

    Let me try to put an example of what I need.

    I have the following list

    A
    B


    I would like to obtain on a different range the following matrix

    A B
    A
    B

    Another one:

    A
    B
    C

    The matrix I need would be:
    A B C
    A B
    A C
    B C
    A
    B
    C

    Last example just to make sure it's fully clear.

    A
    B
    C
    D

    The matrix would be:

    A B C D
    A B C
    A B D
    A C D
    B C D
    A B
    A C
    A D
    B C
    B D
    C D
    A
    B
    C
    D

    Remember the number of components could be VERY HIGH, I don't think I would really reach more than 100 but it's possible, so the number of combinations and the size of the table could be EXTREMELY big)

    The order in which the combinations are displayed DOES NOT MATTER but each component must be on 1 cell, NEVER 2 or 3 components of the list in the same cell of the matrix.

    Thanks a bunch to everyone and hopefully I can find a solution to this issue.
    Last edited by rogelio.alarconv; 01-19-2019 at 02:00 PM.

  2. #2
    Forum Guru Pete_UK's Avatar
    Join Date
    12-31-2011
    Location
    Warrington, England
    MS-Off Ver
    Office 2019 (still learning)
    Posts
    24,723

    Re: All Possible Combination from 1 List with an Specific Arrangement

    I've modified one of my files to show you how this can be done. I've set this up for 8 columns, but I've just used 4 for this demonstration, as in your last example (i.e. A, B, C, and D). The values go into row 4 (row 3 is made up of spaces), and formulae begin on row 10 to generate the combinations. I've copied these formulae down to row 500, as can be seen with the hyphens, but you can see from the number in J16 how many are actually needed - note that this includes the first row (10), which will always be a row of blanks.

    The order is generated from right to left, so it is a different order to yours, but you can see that the combinations are the same. You can add up to 4 more characters in the yellow area, and the combinations will automatically be produced.

    If you need more columns, it would be better to insert some new columns INSIDE the area covered now (e.g. after column B), then copy column B's formulae across.

    Hope this helps.

    Pete
    Attached Files Attached Files

  3. #3
    Registered User
    Join Date
    01-19-2019
    Location
    Mexico
    MS-Off Ver
    2016
    Posts
    4

    Re: All Possible Combination from 1 List with an Specific Arrangement

    Quote Originally Posted by Pete_UK View Post
    I've modified one of my files to show you how this can be done. I've set this up for 8 columns, but I've just used 4 for this demonstration, as in your last example (i.e. A, B, C, and D). The values go into row 4 (row 3 is made up of spaces), and formulae begin on row 10 to generate the combinations. I've copied these formulae down to row 500, as can be seen with the hyphens, but you can see from the number in J16 how many are actually needed - note that this includes the first row (10), which will always be a row of blanks.

    The order is generated from right to left, so it is a different order to yours, but you can see that the combinations are the same. You can add up to 4 more characters in the yellow area, and the combinations will automatically be produced.

    If you need more columns, it would be better to insert some new columns INSIDE the area covered now (e.g. after column B), then copy column B's formulae across.

    Hope this helps.

    Pete
    OMG Thanks, I will analyze this to understand it fully, but I really appreciate it.

  4. #4
    Forum Guru Pete_UK's Avatar
    Join Date
    12-31-2011
    Location
    Warrington, England
    MS-Off Ver
    Office 2019 (still learning)
    Posts
    24,723

    Re: All Possible Combination from 1 List with an Specific Arrangement

    You're welcome - thanks for the rep.

    Pete

+ 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] COUNTIF specific combination of figures and character
    By Solvax in forum Excel Formulas & Functions
    Replies: 5
    Last Post: 01-07-2019, 05:11 PM
  2. [SOLVED] need help counting of combination of specific text in textphrase
    By anu08 in forum Excel General
    Replies: 7
    Last Post: 09-24-2015, 03:23 PM
  3. [SOLVED] a question on data arrangement (general) and chi-sq test (specific)
    By seraphin in forum Excel General
    Replies: 5
    Last Post: 07-17-2015, 04:17 PM
  4. [SOLVED] Combination IF/VLOOKUP to Return Specific Value
    By Shadefalcon in forum Excel Formulas & Functions
    Replies: 11
    Last Post: 05-09-2013, 04:14 PM
  5. Routine to an specific type of combination
    By bagulhodoido in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 07-10-2012, 09:22 PM
  6. Replies: 0
    Last Post: 04-18-2012, 01:56 PM
  7. Replies: 5
    Last Post: 07-01-2008, 09:36 AM

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