This paper presents some aspects of command and control of the new generation of machines-tools with numerical control. A problem faced by numerical control programmers is related to the length (relatively long) of the programs, with implications in the costs and duration of the manufacturing preparation. A method of reducing the main program and other redundant expenses is the introduction and use of processing cycles and subroutines for automatic calculation of the cutting tool trajectory, a fact that also allows the optimization and simplification of numerical control programming on flexible order manufacturing systems numeric. The method involves the use of predefined cycles and appropriate subroutines in order to improve the efficiency of the programming activity in a balanced way. It is a new and rapid method for optimize the structure of program using the numerical subroutine for command the movement of tool, in our case, with application for turning and milling.