Hi I'm trying to fit Lego Blocks into an asymmetrical shape.
I can choose between all Lego blocks (different weights) which are:
- 8x2 (0.35)
- 8x1 (0.29)
- 6x2 (0.28)
- 6x1 (0.25)
- and so on
all the bricks can be align vertically and horicontally
to bring the shape into code I use an Array like:
0 0 1 1 1 1 1 1 0 0 0 0
1 1 1 1 1 1 1 1 0 0 0 0
0 0 0 0 1 1 1 1 0 0 0 0
0 0 0 0 1 1 1 1 0 0 0 0
1 1 1 1 1 1 1 1 1 1 1 1
1 1 1 1 1 1 1 1 1 1 1 1
0 0 0 0 1 1 1 1 1 1 1 1
0 0 0 0 1 1 1 1 0 0 0 0
I now need to fit the blocks into this shape with the lowest cost I think about using genetic algorithm for this, but not sure actually how to start
Can anyone help me with this problem ?