为了增强转换所得CSG模型的可读性,利用面壳封闭技术改进B Rep至CSG转换算法.B-Rep至CSG转换包括生成基本体元和构建CSG树.基于面壳封闭的B-Rep模型分解算法能生成基本体元,文中在此基础上提出构建CSG树的算法.首先使用体关系图(VRG)表示基本体元之间的关系;然后基于改进的Stoer-Wagner最小割算法实现从VRG至CSG树的转换.文中证明了通过硬约束“可闭合约束”和“可组合约束”可保证转换所得CSG树的正确性,通过软约束“最简分割约束”和“最优平衡约束”能进一步优化CSG树.文中算法已集成到自主研发的多物理耦合分析建模软件MCAM中.测试结果表明,该算法能显著地改进MCAM的B Rep至CSG转换结果的可读性,对MCAM的时间性能也有所改进.
To make CSG models more readable, the paper improves B-Rep to CSG conversion algorithm by utilizing face shell shrinking technology. B-Rep to CSG conversion consists of generation of primitives and construction of CSG tree. And the face shell shrinking based B-Rep decomposition algorithm is exploited to generate suitable primitives. In order to effectively construct the CSG tree, volume relation graph(VRG) is firstly used to represent the relation among different primitives; and then an improved Stoer-Wagner mini-cut algorithm is utilized to achieve VRG to CSG conversion. The paper proves that the hard constraints "closable constraints" and "combinable constraint" can ensure the correction of the constructed CSG tree, and the soft constraints "simple decomposition constraint" and "the best balance constraint" can optimize the CSG tree. The algorithm has been implemented in self-developed multi-physics coupling analysis modeling program MCAM, and the experimental results demonstrate that the algorithm can greatly optimize the constructed CSG model and improve MCAM's time performance as well.