The rectangle moves freely according to the random step generated by Monte Carlo method in the region to be packed in. When the rectangle moves, it is confined in the region to be packed in automatically, which makes the calculation of feasible region become simple. After the feasible region is obtained, the rectangle is packed in successfully by the placement function. Experiments show that above ninety percent of the region to be packed in is filled with rectangles.%根据蒙特卡罗方法产生的随机步长,控制矩形在布局空间中移动.矩形移动时,自动满足边界约束条件,简化了矩形可行域边界的计算过程.结合定位函数,得到的可行域可用于完成矩形的布局.测试结果表明,使用该方法求解矩形布局问题,布局空间90%以上被矩形占据.
展开▼