Minimal number of covering boxes for binary matrix
Asked Answered
S

0

6

I have a binary matrix n*m (0's and 1's). Problem is to cover all 1's with non-overlapping boxes whose elements are all 1.

Example:

1111
0110
0110

Box can be represent with coordinates and lengths in each coordinate (x,y,lx,ly). This example is covered with 2 boxes { (0,0,1,4), (1,1,2,2) }.

I'm looking how to find cover with minimal number of boxes.

Thanks

Scrofula answered 16/3, 2011 at 10:24 Comment(5)
Are the boxes allowed to overlap?Handbook
@Jeff: For the specified problem, you wouldn't gain any benefit by overlapping.Dropkick
You might find this useful: #4702387Cawley
@Jeff: no overlapping. I edited text.Scrofula
@biziclop: it is same problem. Thank you.Scrofula

© 2022 - 2024 — McMap. All rights reserved.