100% found this document useful (1 vote)
866 views

Bin Packing - First Fit Decreasing Algorithm

The first fit decreasing algorithm first sorts items into descending order of size. It then uses a first fit algorithm to pack the sorted items into bins, placing each item into the first bin that has enough remaining capacity to hold it. This process is shown step-by-step for packing various sized items into bins, resulting in the items being packed into 5 bins.

Uploaded by

milahanif8
Copyright
© Attribution Non-Commercial (BY-NC)
Available Formats
Download as PPT, PDF, TXT or read online on Scribd
100% found this document useful (1 vote)
866 views

Bin Packing - First Fit Decreasing Algorithm

The first fit decreasing algorithm first sorts items into descending order of size. It then uses a first fit algorithm to pack the sorted items into bins, placing each item into the first bin that has enough remaining capacity to hold it. This process is shown step-by-step for packing various sized items into bins, resulting in the items being packed into 5 bins.

Uploaded by

milahanif8
Copyright
© Attribution Non-Commercial (BY-NC)
Available Formats
Download as PPT, PDF, TXT or read online on Scribd
You are on page 1/ 11

Bin Packing First fit decreasing algorithm

With the first fit decreasing algorithm we sort the blocks into descending order first.

4 1 2

5 3 2 3

6 3

Bin Packing First fit decreasing algorithm

Now we use the first fit algorithm

Bin Packing First fit decreasing algorithm


6

Now we use the first fit algorithm

Bin Packing 5 First fit decreasing algorithm


6

Now we use the first fit algorithm

Bin Packing 4 First fit decreasing algorithm 4


6 5 4 C D E F

Now we use the first fit algorithm

Bin Packing First fit decreasing algorithm 3


3 3 6 5

4 C

3 D E F

Now we use the first fit algorithm

Bin Packing First fit decreasing algorithm 3


3 3

3
6 5 4 C 3 D E F

Now we use the first fit algorithm

Bin Packing First fit decreasing algorithm 3 3


3 3

3
6 5 4 C 3 D 3 E F

Now we use the first fit algorithm

Bin Packing First fit decreasing algorithm 2


2

2
6 5 4 C

3
3 D 3 E F

Now we use the first fit algorithm

Bin Packing First fit decreasing algorithm 2 2 2


2

2
6 5 4 C

3
3 D

2 3 E F

Now we use the first fit algorithm

Bin Packing First fit decreasing algorithm


1 1 6 5

2
4 C

3
3 D

2 3 E F

We have use the first fit algorithm Now we packed them into 5 bins.

You might also like