The purpose of this paper is to present a way to acquire some knowledge for the development of an expert system for power system security analysis. The paper discusses principally the problem of security in steady state and especially the problem of overloaded branches. The proposed method is based on a hybrid approach which includes rules and numerical computations to evaluate the effect of outages on the power system. The basic idea is to use a systematic analysis of the single contingencies to build a knowledge base. In real time the knowledge base is used to perform a single contingency analysis around the working point for which the base case has been calculated. The same knowledge base is also used to carry out a double contingency analysis at the working point for which it has been established. Rules are extracted by considering similarities between the knowledge bases obtained for different characteristic operating states. An advantage of the proposed method is that, by using filtering, it provides a general way to extract rules for each contingency