Before designing the program, we needed some prerequisites. The first one is an understanding of the functional programming language SML. We will use this language to code the new system. In this project, we will use the module facility of SML to design our programs to create a COSY environment. So, the second thing we need to know is what COSY (Concurrent System) is. In this project, our main task was to expand Macro COSY programs. Therefore, we need to undertand what is meant by the expansion of Macro COSY programs to basic COSY programs. In the following sections, we will talk about SML, COSY and the expansion of Macro COSY programs.