Bin Packing Optimization

Slides:



Advertisements
Similar presentations
Algorithm Design Techniques
Advertisements

1D Bin Packing (or “CP? Who cares?”)
Crew Pairing Optimization with Genetic Algorithms
Algorithm Design Methods (I) Fall 2003 CSE, POSTECH.
Algorithm Design Methods Spring 2007 CSE, POSTECH.
Constraint Optimization We are interested in the general non-linear programming problem like the following Find x which optimizes f(x) subject to gi(x)
MATH 224 – Discrete Mathematics
 Review: The Greedy Method
MCS 312: NP Completeness and Approximation algorithms Instructor Neelima Gupta
CS6800 Advanced Theory of Computation
1 An Adaptive GA for Multi Objective Flexible Manufacturing Systems A. Younes, H. Ghenniwa, S. Areibi uoguelph.ca.
Algorithm Design Techniques: Greedy Algorithms. Introduction Algorithm Design Techniques –Design of algorithms –Algorithms commonly used to solve problems.
CS223 Advanced Data Structures and Algorithms 1 Greedy Algorithms Neil Tang 4/8/2010.
Multi-Objective Optimization NP-Hard Conflicting objectives – Flow shop with both minimum makespan and tardiness objective – TSP problem with minimum distance,
Non-Linear Problems General approach. Non-linear Optimization Many objective functions, tend to be non-linear. Design problems for which the objective.
Introduction to Genetic Algorithms Yonatan Shichel.
Chapter 10: Algorithm Design Techniques
Chapter 6: Transform and Conquer Genetic Algorithms The Design and Analysis of Algorithms.
Genetic Algorithm.
A Budget Constrained Scheduling of Workflow Applications on Utility Grids using Genetic Algorithms Jia Yu and Rajkumar Buyya Grid Computing and Distributed.
Modeling and Optimization of Aggregate Production Planning – A Genetic Algorithm Approach B. Fahimnia, L.H.S. Luong, and R. M. Marian.
Scott Perryman Jordan Williams.  NP-completeness is a class of unsolved decision problems in Computer Science.  A decision problem is a YES or NO answer.
Approximation schemes Bin packing problem. Bin Packing problem Given n items with sizes a 1,…,a n  (0,1]. Find a packing in unit-sized bins that minimizes.
Genetic algorithms Charles Darwin "A man who dares to waste an hour of life has not discovered the value of life"
HOW TO MAKE A TIMETABLE USING GENETIC ALGORITHMS Introduction with an example.
Applying Genetic Algorithm to the Knapsack Problem Qi Su ECE 539 Spring 2001 Course Project.
For Wednesday No reading No homework There will be homework for Friday, as well the program being due – plan ahead.
Learning by Simulating Evolution Artificial Intelligence CSMC February 21, 2002.
Introduction to Genetic Algorithms. Genetic Algorithms We’ve covered enough material that we can write programs that use genetic algorithms! –More advanced.
Algorithm Design Methods 황승원 Fall 2011 CSE, POSTECH.
Overview Last two weeks we looked at evolutionary algorithms.
1 Comparative Study of two Genetic Algorithms Based Task Allocation Models in Distributed Computing System Oğuzhan TAŞ 2005.
Class Scheduling Using Constraint Satisfaction Victoria Donelson Garrett Grimsley.
Exhaustive search Exhaustive search is simply a brute- force approach to combinatorial problems. It suggests generating each and every element of the problem.
Introduction to Algorithms: Brute-Force Algorithms.
BIN SORTING Problem Pack the following items in bins of size Firstly, find the lower bound by summing the numbers to be packed.
Warehouse Lending Optimization Paul Parker (2016).
A MapReduced Based Hybrid Genetic Algorithm Using Island Approach for Solving Large Scale Time Dependent Vehicle Routing Problem Rohit Kondekar BT08CSE053.
1 Priority Queues (Heaps). 2 Priority Queues Many applications require that we process records with keys in order, but not necessarily in full sorted.
Genetic Algorithm (Knapsack Problem)
Algorithm Design Techniques, Greedy Method – Knapsack Problem, Job Sequencing, Divide and Conquer Method – Quick Sort, Finding Maximum and Minimum, Dynamic.
Using GA’s to Solve Problems
Selected Topics in CI I Genetic Programming Dr. Widodo Budiharto 2014.
Bin Packing First fit decreasing algorithm
USING MICROBIAL GENETIC ALGORITHM TO SOLVE CARD SPLITTING PROBLEM.
Algorithm Design Methods
Example: Applying EC to the TSP Problem
Chapter 6: Genetic Algorithms
Multi - Way Number Partitioning
Genetic Algorithms CPSC 212 Spring 2004.
Objective of This Course
Exam 2 LZW not on syllabus. 73% / 75%.
Bin Packing First fit decreasing algorithm
Multi-Objective Optimization
Discrete Mathematics CMP-101 Lecture 12 Sorting, Bubble Sort, Insertion Sort, Greedy Algorithms Abdul Hameed
3. Brute Force Selection sort Brute-Force string matching
Bin Packing First fit decreasing algorithm
Methods and Materials (cont.)
Solving the Minimum Labeling Spanning Tree Problem
Bin Packing First fit decreasing algorithm
Searching for solutions: Genetic Algorithms
3. Brute Force Selection sort Brute-Force string matching
Algorithm Design Methods
Computer Hardware Optimization
Algorithm Design Methods
Bin Packing Michael T. Goodrich Some slides adapted from slides from
Alex Bolsoy, Jonathan Suggs, Casey Wenner
Algorithm Design Methods
3. Brute Force Selection sort Brute-Force string matching
Presentation transcript:

Bin Packing Optimization Rachel Jackson Kirklyn Fields

Overview Introduction Algorithms Results Q/A What is bin packing? Why 380? Applications Algorithms Exhaustive Search First Fit Decreasing Genetic Algorithm Results Q/A Overview

Introduction Bin Packing Problem: Objects of different sizes must be packed into a finite number of containers, or “bins” Each bin has a finite volume. Must minimize the number of bins used Computational complexity NP-Hard Problem. Decision problem of deicing if a certain number of bins is optimal, is NP-Complete Two Versions Online: items arrive one at a time Offline: all items are given up front Introduction

Problem with lots of applications, that requires us to design our own implementations of common algorithms we will study. Applications: Loading files into memory Job scheduling TV advertisement slots Packing by cost/weight Why 380?

Formal Problem Statement Given a set of bins , B with the same size S, and a list of j items each with sizes 𝒘 𝟏 .. 𝒘 𝒏 to pack inside of those bins, find the minimum number of bins ,K ,such that the sum of items within each bin is <= S. Mixed Integer Programming formulation: Minimize 𝐊= 𝒊=𝟏 𝒏 𝑩 𝒊 Subject to 𝒋=𝟏 𝒏 𝑩(𝒘 𝒋 ) ≤𝑺 Where K is the sum of bins B, needed to pack j items, subject to the sum of j items must be less than the size of each bin S. Formal Problem Statement

Brute Force Brute Force Approach to Combinational Logic Focused on constraint Satisfaction Selects the Solutions that user asks for Algorithm Take a Set of Items Find all possible combinations Check If each combinations passes the constraint check Pass the solutions to the User

Brute Force

First Fit Decreasing Greedy Approximation Time complexity O(n log n) Algorithm: Initially all bins empty beginning with 0 bins Sort items to be packed in to decreasing order. For each item: Attempt to place the item in the first bin that can accommodate the item If no bin is found: Create a new bin First Fit Decreasing uses at most (4M + 1)/3 bins if the optimal is M. First Fit Decreasing

First Fit Decreasing Results Example with bin size = 30 First Fit Decreasing Results First Fit Decreasing   Total Bins 10 20 8 28 7 Full 1 6 13 3 16 19 2 21 22 Done 2 Bins

First Fit Decreasing Results

Hybrid Grouping Genetic Algorithm Overview Initialize a population of possible solutions (50) using first fit For a specified amount of time(in our case 50 generations): Select two parents Generate offspring through crossover Mutation Grade fitness Hybrid Grouping Genetic Algorithm

Hybrid GA (cont) 𝑠 𝑖 = sum of the ith bin Fitness = 𝑖=1 𝑛 ( 𝑆 𝑖 𝑐 ) 𝑘 𝑛 N = number of bins 𝑠 𝑖 = sum of the ith bin c = capacity of the bin k = 2 (can be any constant greater than1) Should maximize fitness score. Hybrid GA (cont)

Crossover Select random parents Clone parents Hybrid GA (cont) Crossover Select random parents Clone parents Chose two cross over points Swap bins between parents and clones Remove duplicates and add any unused elements from parents into children

Hybrid GA (Cont) Mutation - 50% Select bins at random to be destroyed. This allows for reinsertion of items within those bins

GA Results

First Fit Decreasing, and Genetic Algorithms are as expected faster than brute force However they do not always find the optimal solution Many variations of problem that can be applied to many real world situations. Results/ Conclusion

Q&A Q:What is the bin packing problem? A: Given a set of items pack them into the smallest amount of bins possible. Q: Describe the Frist Fit Decreasing Algorithm A: given a set of n items, sort them in decreasing order. Until all items are packed: Attempt to pack each item into the first available bin, if the item will not fit, create a new bin and pack that item. Q: What is the time of complexity of First Fit Decreasing/? A: O(nLogn) Q&A

Fin Questions?