Closed Thread
Results 1 to 27 of 27

Optimize Cut Lengths

  1. #1
    Registered User
    Join Date
    05-20-2009
    Location
    Cameron, Oklahoma
    MS-Off Ver
    Excel 20073
    Posts
    11

    Optimize Cut Lengths

    I have a given length of steel bar...Example(550 feet)
    I have various cut lengths that I can pick from...
    14'-10".....13'- 9".. 12'-8"........(up to 6 different lengths)

    I need to know the best combination of lengths to cut the long bar into to have minimal scrap left when we get to the end of the 550 feet.....

    Cut as many of the longest cut lengths possiable.....Cut as few of the shortest cut lengths possiable

    Due to the fact that I will have to convert this to a PLC application when completed, I want to find a mathmatical way to do this inside excel and not use the "solver"....Assuming that I/we can come up with an equation to do this .....
    Any and all advice/help would be appricated.....
    Last edited by opister; 05-25-2009 at 01:55 PM.

  2. #2
    Forum Expert shg's Avatar
    Join Date
    06-20-2007
    Location
    The Great State of Texas
    MS-Off Ver
    2003, 2010
    Posts
    40,678

    re: Optimize Cut Lengths

    It's a combinatorial problem, and can be very time consuming.

    A simple algorithm is to choose the largest length possible in the remaining bar length, subtract that, and iterate. Then move on the the next bar.

    The optimal solution to to try all possible combinations, and choose those that minimize scrap for all bars. Computations could run minutes to months.

    It kinda depends on whether you're trying to save aluminum or platinum.
    Entia non sunt multiplicanda sine necessitate

  3. #3
    Forum Expert Paul's Avatar
    Join Date
    02-05-2007
    Location
    Wisconsin
    MS-Off Ver
    2016/365
    Posts
    6,885

    re: Optimize Cut Lengths

    I'm just glad a Texan answered and not one of our UK folks. "Aluminium" just makes me twinge when I hear/see it.

  4. #4
    Forum Expert shg's Avatar
    Join Date
    06-20-2007
    Location
    The Great State of Texas
    MS-Off Ver
    2003, 2010
    Posts
    40,678

    re: Optimize Cut Lengths

    In Texas, aluminium is a probably a dietary supplement for people in Austin.

    in Fort Worth and Amarillo, we machine aluminum to make weapon platforms.

    Hoo-ah!

  5. #5
    Registered User
    Join Date
    05-20-2009
    Location
    Cameron, Oklahoma
    MS-Off Ver
    Excel 20073
    Posts
    11

    re: Optimize Cut Lengths

    Will there be that many combinations with only 6 cut lengths avaiable???
    Cab this be done inside excel even if it is time consuming?

  6. #6
    Valued Forum Contributor squiggler47's Avatar
    Join Date
    02-17-2009
    Location
    Littleborough, UK
    MS-Off Ver
    Excel 3.0 to 2007+2010! (couldnt get 2.1 working)
    Posts
    1,013

    re: Optimize Cut Lengths

    its not optimal, but i used it to fill floppies using a batch file in dos days

    take the longest length

    calculate remainder

    find the longest length smaller than the remainder

    repeat until you have no lengths smaller than the remainder!

    other than that you have to iterate through every combination!

    you can cut down combinations by using all cuts over 50% of the bar length first!
    Regards
    Darren

    Update 12-Nov-2010 Still job hunting!

    If you are happy with the results, please add to our reputation by clicking the blue scales icon in the blue bar of the post.

    Learn something new each day, Embrace change do not fear it, evolve and do not become extinct!


  7. #7
    Forum Expert shg's Avatar
    Join Date
    06-20-2007
    Location
    The Great State of Texas
    MS-Off Ver
    2003, 2010
    Posts
    40,678

    re: Optimize Cut Lengths

    Will there be that many combinations with only 6 cut lengths avaiable???
    Post a workbook.

  8. #8
    Registered User
    Join Date
    05-20-2009
    Location
    Cameron, Oklahoma
    MS-Off Ver
    Excel 20073
    Posts
    11

    re: Optimize Cut Lengths

    examples what I am talking about...
    Attached Files Attached Files

  9. #9
    Forum Expert shg's Avatar
    Join Date
    06-20-2007
    Location
    The Great State of Texas
    MS-Off Ver
    2003, 2010
    Posts
    40,678

    re: Optimize Cut Lengths

    Excel can't handle lengths in feet and inches like that without messier formulas than the one below. It can store them as, for example, 168.07, meaning 168'7" -- that's what I've done below.

    However, you can cut all your pieces from the one piece of stock.

    Please Login or Register  to view this content.

  10. #10
    Registered User
    Join Date
    05-20-2009
    Location
    Cameron, Oklahoma
    MS-Off Ver
    Excel 20073
    Posts
    11

    re: Optimize Cut Lengths

    I think you misunderstand what I am asking....We need to know what combination of the cut lengths leave us with the least ammout of scrap at the end....We can cut any number or combination of lengths ...The goal is to have little scrap bar remaining when we make our last cut.....Sorry about not being clear on this........

    As far as the length in feet and inchs goes..we can change all of them to decimal if that helps in the calculations ....But thanks for your response....

  11. #11
    Forum Expert shg's Avatar
    Join Date
    06-20-2007
    Location
    The Great State of Texas
    MS-Off Ver
    2003, 2010
    Posts
    40,678

    re: Optimize Cut Lengths

    You need equal numbers of each length? If not, you need to specify the required qty of each.

    EDIT: Never mind -- just re-read the original post.
    Last edited by shg; 05-21-2009 at 01:39 PM.

  12. #12
    Registered User
    Join Date
    05-20-2009
    Location
    Cameron, Oklahoma
    MS-Off Ver
    Excel 20073
    Posts
    11

    re: Optimize Cut Lengths

    No, in the example workbook we would take the 168, cut as many prime(15') bars as possiable but keep in mind that we will cut some of the smaller cut lengths in order to minimize the final bit of scrap

    If we cut all 15' then we would get 11.24 smaller bars the 0.24 being scrap.......

    If we could use any combination of the other cut lenghts and come up with less than 0.24 scrap......that would be the goal.....I think that 11-15' bars is the best solution here but what if there were 175' of bar or 400' .....

  13. #13
    Forum Expert shg's Avatar
    Join Date
    06-20-2007
    Location
    The Great State of Texas
    MS-Off Ver
    2003, 2010
    Posts
    40,678

    re: Optimize Cut Lengths

    Yes, but you could always take that approach -- cut as many as the longest bars possible, and if what's left is shorter than any other standard length, it's scrap.

    What if cutting all bars the shortest length (for example), yields zero waste -- is that better or worse?
    Last edited by shg; 05-21-2009 at 03:08 PM.

  14. #14
    Registered User
    Join Date
    05-20-2009
    Location
    Cameron, Oklahoma
    MS-Off Ver
    Excel 20073
    Posts
    11

    re: Optimize Cut Lengths

    Cutting all prime lenght and a final sub prime(if needed) is what we do now ....scrap the remainder.....

    The problem is ...sometimes this is a 9' scrap bar ....weight approx...2000 pounds ....worth about $350 .....we have 3 of the casters doing this several times a day......

    There is some cost assoiated with every cut...therfore cutting the smallest cut length will not likely be the best option even if it yeilds 0 scrap.....

    The real goal here is to cut prime lengths as much as we can ....then ...near the end ....switch to a the best combo. of subprimes to reduce this end scrap.....

  15. #15
    Forum Expert shg's Avatar
    Join Date
    06-20-2007
    Location
    The Great State of Texas
    MS-Off Ver
    2003, 2010
    Posts
    40,678

    re: Optimize Cut Lengths

    cut prime lengths as much as we can ....then ...near the end ....switch to a the best combo. of subprimes
    That's a very squishy criteria.

    Suppose you COULD use Solver -- how would you define the optimization?

  16. #16
    Registered User
    Join Date
    05-20-2009
    Location
    Cameron, Oklahoma
    MS-Off Ver
    Excel 20073
    Posts
    11

    re: Optimize Cut Lengths

    I think it would make thing easier to just try and optomize the last 6 cuts....
    say we had 81 eet of bar with cut lengths of 14, 13, 12, 10, 9 to choose from.....
    this should/maythe math easier,,,,I would optomize for +- scrap..

    I have not used the solver and am not all that familar with it.....I just didnt want to use it because i had no idea of a way to duplicate this in a plc....

  17. #17
    Forum Expert shg's Avatar
    Join Date
    06-20-2007
    Location
    The Great State of Texas
    MS-Off Ver
    2003, 2010
    Posts
    40,678

    re: Optimize Cut Lengths

    I understood the reason you didn't want to use Solver.

    Can your PLC do Visual Basic?

  18. #18
    Registered User
    Join Date
    05-20-2009
    Location
    Cameron, Oklahoma
    MS-Off Ver
    Excel 20073
    Posts
    11

    re: Optimize Cut Lengths

    yes..most code can be converted to work .....

  19. #19
    Registered User
    Join Date
    05-20-2009
    Location
    Cameron, Oklahoma
    MS-Off Ver
    Excel 20073
    Posts
    11

    re: Optimize Cut Lengths

    can this be done with a Macro?

  20. #20
    Forum Expert shg's Avatar
    Join Date
    06-20-2007
    Location
    The Great State of Texas
    MS-Off Ver
    2003, 2010
    Posts
    40,678

    re: Optimize Cut Lengths

    See attached
    Attached Files Attached Files

  21. #21
    Registered User
    Join Date
    05-20-2009
    Location
    Cameron, Oklahoma
    MS-Off Ver
    Excel 20073
    Posts
    11

    Re: Optimize Cut Lengths

    this works great...thanks so much......I should be able to convert to work with the PLC...thanks again!!!

  22. #22
    Forum Expert shg's Avatar
    Join Date
    06-20-2007
    Location
    The Great State of Texas
    MS-Off Ver
    2003, 2010
    Posts
    40,678

    Re: Optimize Cut Lengths

    You're welcome. Would you please mark the thread as Solved? (How To ... in menu bar)

  23. #23
    Registered User
    Join Date
    05-20-2009
    Location
    Cameron, Oklahoma
    MS-Off Ver
    Excel 20073
    Posts
    11

    Re: Optimize Cut Lengths

    Follow-up to the above work.....This method has worked great in the excel enviorment...I am now in the process of converting to VB.net....I am having trouble converting the functions as the VBA and VB.net are not as similar as I would have hoped....Anybody have experience in converting?? Any Help or advice woruld be greatly appriciated.......

  24. #24
    Registered User
    Join Date
    08-25-2011
    Location
    Boston, MA
    MS-Off Ver
    Excel 2003
    Posts
    5

    Re: Optimize Cut Lengths

    Hello!
    I know this thread is from ages ago, but is there any chance you are still around, and feel like sharing that cut length optimizing solution? I have about 700 rods I need to cut, and want to minimize scrap. I have an Excel 2007 table with Rod length (inches) (ranging from 54 to 240), and Quantity(ranging from 1 to 143), and need to find how many 32 ft lengths i need to order, and how much scrap that leaves me with.,,,,. I really don't want to do it by hand!

    Any help would be much appreciated.

  25. #25
    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: Optimize Cut Lengths

    Hi Ari88

    Your best chance of getting help is to post your question starting a new tread. As this tread is marked "Solved" most forum members that gets a kick out of solving problems will just pass it by.

    Don't forget to post a workbook as well showing numbers of cut rods required and length of the different rods.

    In my opinion Solver would probably be the best tool for this problem.

    Alf

  26. #26
    Forum Guru (RIP) Marcol's Avatar
    Join Date
    12-23-2009
    Location
    Fife, Scotland
    MS-Off Ver
    Excel '97 & 2003/7
    Posts
    7,216

    Re: Optimize Cut Lengths

    As a footnote to this thread.
    Are you cutting or shearing the bars?

    If you are cutting, the blade thickness can make a significant difference.
    36 cuts with an 1/8" blade will lose 4 1/2"

  27. #27
    Forum Expert
    Join Date
    12-23-2006
    Location
    germany
    MS-Off Ver
    XL2003 / 2007 / 2010
    Posts
    6,326

    Re: Optimize Cut Lengths

    Your post does not comply with Rule 2 of our Forum RULES. Don't post a question in the thread of another member -- start your own thread. If you feel it's particularly relevant, provide a link to the other thread.

Closed 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