A progressive Node.js framework for building efficient and scalable server-side applications.
The 3D Bin Packing Algorithm is a powerful solution designed to optimize the efficient packing of objects within three-dimensional containers. This algorithm is particularly useful in scenarios where maximizing space utilization is crucial, such as in logistics, manufacturing, or resource allocation.
{
"maxBin": {
"width":100,
"height" : 100,
"length" : 100,
"weight" : 22
},
"box": {
"width":10,
"height" : 15,
"length" : 20,
"weight" : 5
},
"numBoxes": 10
}
{
"result": [
{
"width": 100,
"length": 100,
"height": 100,
"weight": 20,
"totalWidth": 10,
"totalHeight": 60,
"totalLength": 20,
"boxes": [
{
"index": 0,
"position": {
"x": 0,
"y": 0,
"z": 0
}
},
{
"index": 1,
"position": {
"x": 0,
"y": 0,
"z": 15
}
},
{
"index": 2,
"position": {
"x": 0,
"y": 0,
"z": 30
}
},
{
"index": 3,
"position": {
"x": 0,
"y": 0,
"z": 45
}
}
]
},
{
"width": 100,
"length": 100,
"height": 100,
"weight": 20,
"totalWidth": 10,
"totalHeight": 60,
"totalLength": 20,
"boxes": [
{
"index": 4,
"position": {
"x": 0,
"y": 0,
"z": 0
}
},
{
"index": 5,
"position": {
"x": 0,
"y": 0,
"z": 15
}
},
{
"index": 6,
"position": {
"x": 0,
"y": 0,
"z": 30
}
},
{
"index": 7,
"position": {
"x": 0,
"y": 0,
"z": 45
}
}
]
},
{
"width": 100,
"length": 100,
"height": 100,
"weight": 10,
"totalWidth": 10,
"totalHeight": 30,
"totalLength": 20,
"boxes": [
{
"index": 8,
"position": {
"x": 0,
"y": 0,
"z": 0
}
},
{
"index": 9,
"position": {
"x": 0,
"y": 0,
"z": 15
}
}
]
}
]
}
$ npm install
# development
$ npm run start
# watch mode
$ npm run start:dev
# production mode
$ npm run start:prod