This book presents a model and an environment for recovering high level design of legacy software systems based on user defined architectural patterns and graph matching techniques. In the proposed model, a high-level view of a software system in terms of abstract components and their constrained interactions is represented as a query using a new description language. This query is mapped onto a pattern-graph, where a component and its constrained interactions with other components are represented as a group of graph-nodes and a group of graph-edges. Such a pattern is applied against an entity-relation graph of the software system. An approximate graph matching process performs a series of graph edit operations (i.e., node/edge insertion/deletion) on the pattern- graph and uses a ranking mechanism based on data mining association rules to obtain a suboptimal solution that complies with the given query. An interactive toolkit (Alborz) is developed that performs architecture recovery in two levels. First, the system is decomposed into a number of subsystems of files. Second, each subsystem is decomposed into a number of modules of functions, datatypes, and variables.