Abstract:Recent research on the self-adaptive software is one of the new focuses in the field of software engineering. The researchers pay more attention on how to improve the adaptation of software from different angles. While some focus on the architecture information, others pay more attention to the requirement. However as of now, there is little work about the process fragments reuse in self-adaptive software. This paper employs the idea of software cybernetics to study the process fragments reuse, and searches the optimal query method based on the model of controlled Markov chain. Firstly, a CMC model in the context of process fragments query is proposed, followed by subsequent optimizations. Then, a self-adaptive query strategy is addressed based on the iterative least square method. With the on-line parameter adjustment, this strategy utilizes the history of process fragment query to help people adjust strategies. The experiments in the context of Matlab and real process dataset validate the efficiency and feasibility of the model and algorithm presented in this paper.