In this study, the problem of determining the optimal group and sequence of operations for a multistage machining system is investigated. A method incorporating a combination of the expert system and mathematical programming is proposed to produce an optimal operation sequence minimizing the noncutting time. Also precedence, tolerance and alternative operations are taken into consideration as constraints. The mathematical method performs grouping and sequencing simultaneously and the expert system preprocesses the procedure by eliminating infeasible solution sets and clustering the operations according to the tool commonalities. A prototype CAPP system is also developed using an object-oriented expert system shell. The system not only performs local process planning for each machining feature of the part but also analyses the relationships among operations to generate a global process plan. The advantage and effectiveness of the proposed approach are verified through an example of an actual manufacturing product.