+ Reply to Thread
Results 1 to 12 of 12

Using Excel To do "SOLVER"

  1. #1
    Registered User
    Join Date
    11-08-2012
    Location
    Albany,NY
    MS-Off Ver
    Office for MAC
    Posts
    24

    Using Excel To do "SOLVER"

    Guys - See attached table..

    What I want to do is optimize my team based on points and salaries with a salary restriction.

    I need to have (2)PG (2) SG (2) SF (2) PF and (1) Center - - The players cannot be reused Meaning Blake Griffin cant play Center and PF

    The goal is to create the MOST OPTIMAL TEAM with the above constraints as well as a salary of $90,000
    Attached Files Attached Files

  2. #2
    Registered User
    Join Date
    11-08-2012
    Location
    Albany,NY
    MS-Off Ver
    Office for MAC
    Posts
    24

    Re: Using Excel To do "SOLVER"

    I for the most part have it except not picking the same person twice

  3. #3
    Registered User
    Join Date
    11-08-2012
    Location
    Albany,NY
    MS-Off Ver
    Office for MAC
    Posts
    24

    Re: Using Excel To do "SOLVER"

    How can I get it so they won't pick a player twice

  4. #4
    Forum Expert Alf's Avatar
    Join Date
    03-13-2004
    Location
    Gothenburg/Mullsjoe, Sweden
    MS-Off Ver
    Excel 2019 and not sure I like it
    Posts
    4,758

    Re: Using Excel To do "SOLVER"

    By changing the layout and using a binary matrix.

    Alf

  5. #5
    Registered User
    Join Date
    11-08-2012
    Location
    Albany,NY
    MS-Off Ver
    Office for MAC
    Posts
    24

    Re: Using Excel To do "SOLVER"

    What exactly does that mean? Changing layout and using binary matrix

  6. #6
    Valued Forum Contributor ratcat's Avatar
    Join Date
    03-07-2008
    Location
    Rural NSW, Australia
    MS-Off Ver
    Vista 2007
    Posts
    1,111

    Re: Using Excel To do "SOLVER"

    G'day CWRocas,

    Please follow the forum rules and don't multiple post your question across the forum.

    How can I get it so they won't pick a player twice
    The following instructions will help you

    http://www.contextures.com/xlDataVal03.html
    Have I made you happy ??? If yes, please make me happy by pressing the http://www.excelforum.com/images/buttons/reputation-40b.png Add Reputation button in my post.
    Please don't forget to do the same to other contributors of this forum.

    Thanks
    I don't void confusion, I create it

  7. #7
    Registered User
    Join Date
    11-08-2012
    Location
    Albany,NY
    MS-Off Ver
    Office for MAC
    Posts
    24

    Re: Using Excel To do "SOLVER"

    WIN BIG.xlsxRal Cat can you help me apply it to this table that I am inserting ?

  8. #8
    Registered User
    Join Date
    11-08-2012
    Location
    Albany,NY
    MS-Off Ver
    Office for MAC
    Posts
    24

    Re: Using Excel To do "SOLVER"

    I have attached the file but Cannot figure this out. I want to make sure that the solver doesn't place a "1" next to any name twice.

  9. #9
    Forum Expert Alf's Avatar
    Join Date
    03-13-2004
    Location
    Gothenburg/Mullsjoe, Sweden
    MS-Off Ver
    Excel 2019 and not sure I like it
    Posts
    4,758

    Re: Using Excel To do "SOLVER"

    What exactly does that mean? Changing layout and using binary matrix
    Put player's name in cell A2 and down as far as you need.

    In columns B, C, D and E you define the positions the players can have with the help of binary format.

    Sum of binary for a player must be <=1

    Alf

  10. #10
    Registered User
    Join Date
    11-08-2012
    Location
    Albany,NY
    MS-Off Ver
    Office for MAC
    Posts
    24

    Re: Using Excel To do "SOLVER"

    How do you define the postitions with a binary format.

  11. #11
    Forum Expert Alf's Avatar
    Join Date
    03-13-2004
    Location
    Gothenburg/Mullsjoe, Sweden
    MS-Off Ver
    Excel 2019 and not sure I like it
    Posts
    4,758

    Re: Using Excel To do "SOLVER"

    The players from Blake Griffin to Sergen Ibaka can all play position PF or position C. So range B2 to C10 is a range where solver can change cells. Since his is a case of either or this range must be set as binary (only 0 or 1 allowed) and the formula in F2 = SUM(B2:C2) .

    Since Blake Griffin can only play PF or C or neither a constraint must be set on cell F2 i.e. it’s value must be <=1.

    You just add the different ranges where solver can change cells and define them as binary and set the appropriate sum constraint for the cells in the F column.

    As you only wish to pick 2 PG, 1 C, 2 SG and 2 PF you can get rid of the players who only can play SF and where a player can be SF or if he can play SF and PF get rid of the SF part as this will make your model a bit simpler to work with.

    Alf
    Attached Images Attached Images

  12. #12
    Forum Expert Alf's Avatar
    Join Date
    03-13-2004
    Location
    Gothenburg/Mullsjoe, Sweden
    MS-Off Ver
    Excel 2019 and not sure I like it
    Posts
    4,758

    Re: Using Excel To do "SOLVER"

    Assuming that sell-by date has passed on this home work I’m uploading my solution for those who have an interest in solver problems.

    If you wish to test it I would suggest you first run it the way I set it up.

    To see the effect of an optimized solver settings clear range B2:E52 then go to options and tick the box for “Assumed Linear Model” and “Assume Non-Negative”

    Both solutions are identical in regards of team cost and value of object function. The only difference is the shuffling of a name from PF to C / C to PF.

    What Shakespeare said “a rose by any other name would smell as sweet” is proved by Solver. A name is not important what’s important is the quality i.e. value of the object function.

    Alf
    Attached Files Attached Files

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

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