Abstract:We present a novel AI-assisted method for decomposing (segmenting) planar CAD (computer-aided design) models into well shaped rectangular blocks as a proof-of-principle of a general decomposition method applicable to complex 2D and 3D CAD models. The decomposed blocks are required for generating good quality meshes (tilings of quadrilaterals or hexahedra) suitable for numerical simulations of physical systems governed by conservation laws. The problem of hexahedral mesh generation of general CAD models has vexed researchers for over 3 decades and analysts often spend more than 50% of the design-analysis cycle time decomposing complex models into simpler parts meshable by existing techniques. Our method uses reinforcement learning to train an agent to perform a series of optimal cuts on the CAD model that result in a good quality block decomposition. We show that the agent quickly learns an effective strategy for picking the location and direction of the cuts and maximizing its rewards as opposed to making random cuts. This paper is the first successful demonstration of an agent autonomously learning how to perform this block decomposition task effectively thereby holding the promise of a viable method to automate this challenging process.