PII: 0196-8904(94)00075-B P e r g a m o n Energy Convers. Mgmt Vol. 36, No. 4, pp. 257-261, 1995 Copyright © 1995 Elsevier Science Ltd 0196-8904(94)00075-1 Printed in Great Britain. All rights reserved 0196-8904/95 $9.50 + 0.00 A N E X P E R T S Y S T E M A P P R O A C H T O T H E U N I T C O M M I T M E N T P R O B L E M D . P . K O T H A R P a n d A I J A Z A H M A D 2 1Centre for Energy Studies, Indian Institute of Technology, Delhi, Hauz Khas, New Delhi 110 016 and 2Electrical Engineering Department, Regional Engineering College, Srinagar, Kashmir, India (Received 26 March 1994; received for publication 8 December 1994) Abstract--An expert system plays a key role in the better conservation and management of electrical energy in a power station having a number of units that have to be committed for a given load. This paper presents a hybrid expert system dynamic programming approach to the unit commitment problem. Here, the scheduling output of the usual dynamic programming is enhanced by supplementing it with the rule based expert system. The proposed system limits the number of constraints and also checks the possible constraint violations in the generated schedule. The expert system communicates with the operator in a friendly manner, and hence, the various program parameters can be adjusted to have an optimal, operationally acceptable schedule. Unit commitment Dynamic programming Expert system 1. I N T R O D U C T I O N I n o r d e r to select the m o s t e c o n o m i c a l schedule o f units in a p o w e r system, different p r o g r a m a l g o r i t h m s h a v e been developed in the past. These algorithms are b a s e d o n m a t h e m a t i c a l p r o g r a m m i n g m e t h o d s , such as d y n a m i c p r o g r a m m i n g ( D P ) [ 1 , 7], L a g r a n g i a n relaxation [2], b r a n c h a n d b o u n d etc. Experience with unit c o m m i t m e n t ( U C ) using a D P technique has s h o w n that, in o r d e r to o b t a i n a g o o d schedule, o p e r a t o r experience should be included in setting u p the c o n t r o l p a r a m e t e r s . This results in tuning the heuristic d a t a a n d input p a r a m e t e r s to p r o d u c e a lower cost a n d o p e r a t i o n a l l y acceptable schedule. A h y b r i d Artificial N e u r a l N e t w o r k ( A N N ) - D P a p p r o a c h [3], h a s also been used. This p a p e r p r o p o s e s a h y b r i d expert system (ES) d y n a m i c p r o g r a m m i n g a p p r o a c h to unit c o m m i t m e n t . H e r e , the scheduling o u t p u t o f the usual D P is enhanced b y s u p p l e m e n t i n g it with the rule b a s e d ES. This ES c o m b i n e s the knowledge o f the U C p r o g r a m m e r a n d a set o f rules. T h e m a i n feature o f the ES, thus developed using T u r b o P r o l o g V2.0, includes m a k i n g possible the use o f the p r o g r a m b y a n o n - e x p e r t user t h r o u g h its ability to guide the user t h r o u g h the i m p o r t a n t decision m a k i n g processes in the p r o b l e m set u p period. T h e system guides the user in adjusting the m a r g i n a l constraints, thereby ensuring a feasible solution within e c o n o m i c a l time limits. T h e m e t h o d h a s been applied to a 10 unit system, wherein the schedule has been o b t a i n e d b y the ES to ensure a feasible solution. I t provides a flexible p r o g r a m m e structure t h a t is easily a d a p t a b l e to changes in the system o p e r a t i o n . 2. E X P E R T S Y S T E M D E V E L O P M E N T I n the past, the ES a p p r o a c h for U C has been applied b y M o k h t a r i e t al. [5]. H e r e , they h a v e developed a n ES to analyze a n d i m p r o v e the D P b a s e d U C . T h e ES tool selected is b a s e d on the inference engine o f the well k n o w n M y c i n ES a n d has been developed for the c o m b u s t i o n turbine cycling p r o b l e m . O u a n g a n d S h a h i d e p o u r [4] h a v e p r o p o s e d a U C ES which applies the E A S E + N E X P E R T shell to o b t a i n a c o m m i t m e n t schedule b y using heuristic rules. A user friendly interface a n d graphic utilities h a v e also been set up. ECM 36/*--D 257 258 KOTHARI and AHMAD: THE UNIT COMMITMENT PROBLEM In the work presented here, a rule based ES approach [6] for handling the UC problem is based on the application of an ES to supplement the DP technique so that a more appropriate solution is achieved. 2.1. Main features of the ES development The main features of the ES developed here are: (i) It combines the knowledge of the UC programmer with the rule base and, hence, can lead an inexperienced operator to a better unit schedule. (ii) The knowledge base (KB)[9, 10], which is the data or knowledge used to make decisions, consists of two parts, i.e. the working memory and the rule base. The KB, containing the knowledge of both schedulers and mathematical programmers, is represented by if/then rule statements. (iii) Each rule represents a piece of knowledge relevant to the problem and the rules can be added, removed and modified in the knowledge base conveniently. (iv) Production rules are close to natural language and, therefore, easy to understand. This enables the user to communicate with the ES in a friendly manner in order to adjust various programme parameters, so that an optimal and acceptable solution is approached. (v) It can give the steps that lead to the conclusions and user's queries about the main phase of the problem. The user can confirm or correct the conclusion by examining the explanations given by the inference engine. The ES developed functions in the following main capacities: (i) Preprocessor of the DP results. (ii) KB and reasoning. (iii) Postprocessor of the result. (iv) User consultant. 2.2. Preprocessor of the DP results There are many constraints in the UC problem which are too difficult to include in the DP algorithm because it increases the programm execution time exponentially. In order to adjust the input data properly, the operator must have a thorough knowledge of the UC programme. The constraints, like operational and complex, are accommodated in the ES as described below. 2.2.1. Inclusion of operational constraints. The operational constraints are included by the user who is guided by the preprocessor, and this is accomplished through an interactive question and answer session during which the user will enter data and answer questions concerning the constraints, such as spinning reserve requirements, unit minimum up and down time, must run status, unit maintenance schedules, unit minimum and maximum generating limits etc. The information regarding these constraints is requested by the system and has to be supplied by the user. Take the case of the constraint "must-run-status". Here, it is assumed that, during any given hour, one or more units in any group may be designated as "must run", i.e. those units for which there will never be any doubt about the need to commit them either because of outstanding efficiency or exceptional capacity. There may also be certain units which will be known, in advance, to be unavailable due to scheduled or forced outage. Such units are designated as "must out". All such information is supplied by the user. 2.2.2. Inclusion of complex constraints. The inclusion of complex constraints in the problem not only makes the problem difficult but increases the program execution time also. This is particularly true of constraints like "unit minimum up and down time", which are time dependent. Here, it is assumed that such a constraint is not violated frequently, so that it can be relaxed and handled external to the UC program itself by adjusting the input data which is fed to it by the preprocessor. Detections for constraint violations can be made by including rules in the knowledge. Also, constraints like fuel constrained units, crew constraints and pollution constraints are present in the actual system operation, and these can be generalized to form production rules that would be added to the knowledge base. Here, in the present study, although it has been tried to include as many constraints as possible, yet these constraints could not be included to avoid the complexity of the problem. KOTHARI and AHMAD: THE UNIT COMMITMENT PROBLEM 259 2.3. Knowledge base and reasoning All the knowledge in solving the U C problem is presented by either a property list or a production rule, i.e. facts and rules. The property list has a form o f object-attribute-value. F o r instance, if the m a x i m u m capacity o f unit-1 is 500 MW, this knowledge is stored in the knowledge base by a triple: (Unit-l, m a x i m u m capacity, 500). Similarly, if the value o f cost parameter A o f unit 10 is Rs. 2500, this knowledge is stored as: (Unit-10, cost A, 2500). Other facts and system constraints are also represented in the same manner. The value portion o f the triple can be update if required. A n o t h e r form o f knowledge is a production rule. A rule expresses the relationship between facts and has a form o f (if clause then clause). Such rule based representation allows the expert system to approach a problem in a way similar to a h u m a n expert. An example o f knowledge representation is given below: I f the unit start up cost is low, A n d the efficiency is high, A n d the unit cost parameter values are low, Then the unit has 'must-run-status'. Such a rule is represented in Turbo Prolog as follows: Hypothesis (must-run-status), condition (start-up-cost-low), condition (efficiency high), condition (cost-parameter-values-low). The inference engine examines the first predicate o f the rule. If the start up cost is low, the engine goes to check the second predicate, if the efficiency is high, then it goes to check the third predicate, and it the cost parameter values are low, then the engine concludes that the unit has must-run-status. The facts for all units, like m i n i m u m and m a x i m u m generating limits, cost curve parameters, start up times etc. and the load curve for the period are stored in the d a t a base. This corresponds to the prolog's static database. The preceding rule a b o u t must-run-status, for example, is a part o f the rule base/static database. 2.3.1. Production rules in the knowledge base. In order to have a fast solution, a production rule based and priority list based heuristics are implemented. The rules, here used, use the priority list as the starting point with additional heuristics leading to the optimal commitment decisions. The decisions in the ES developed here are made according to the following set o f rules: Rule 1: I f a particular unit which is on the top o f the priority list o f available uncommitted units but has a higher m i n i m u m up-time (say, 4 h) than o f the other units (say 1 h) and the spinning reserve requirement is insufficient only for say 1 h, then it is more economical to commit the second unit for 1 h rather than the first unit for at least the m i n i m u m up-time o f 4 h. Rule 2: If, at a n y stage, there is an outage associated with the normally committed units, then commit the next most economical unit. Rule 3: Assign the value o f m a x i m u m tolerable insecurity level (MTIL) to be 0.000445. If, due to some forced outage, this value o f M T I L is not satisfied, then commit the units to the next nearest higher value o f M T I L . Rule 4: I f the load is much less t h a n expected, then the " m u s t r u n " unit (if suggested by the user) should be one o f the committed units in such a case. Rule 5: I f a unit is committed, decommitted and committed again and the " o f f " status in between is close or equal to the m i n i m u m down time o f the unit, commit the unit continuously at the required output. Rule 6: At any instant, if some committed units o f smaller capacity can be replaced in an " o f f " state, then do such replacement, preserving the spinning reserve constraint. 260 KOTHARI and AHMAD: THE UNIT COMMITMENT PROBLEM Rule 7: All the c o m m i t t e d units must operate at least at their m i n i m u m o u t p u t conditions. Rule 8: I f the load d e m a n d is not met at any instant, first let the m o st efficient unit generate m o r e power until either its m a x i m u m o u t p u t is reached o r the load d e m a n d is fulfilled. Rule 9" At any stage, if the sum o f the m a x i m u m generating capacity o f all c o m m i t t e d units is greater t h a n the load demand, then d e c o m m i t only that unit which has the lowest efficiency. 2.4. Postprocessor T h e function o f the postprocessor is to guide the user in analyzing the schedule an d also m a k e suggestions to the user a b o u t adjustments to p r o g r a m p aram et ers to i m p ro v e the overall schedule cost. T h e parameters adjusted here include m i n i m u m up an d d o w n time, unit initial conditions a n d priority ordering. A n o t h e r function o f the ES postprocessor is to detect constraint violations, which is d o n e by including rules in the knowledge base. These rules can deduce logically a violation condition f r o m the schedule o u t p u t and, subsequently, advise the user an d r e c o m m e n d corrections for the problem. We have seen that m i n i m u m u p and d o w n times are particularly difficult to model and c a n n o t be i n c o r p o r a t e d directly in a D P routine. So, to detect such violations, a rule can be introduced in the knowledge base. F o r example, one o f such rules is: Check constraint (up-time-violated): condition (unit on), condition (unit off), condition (dur-less-than-1 h). This rule states that, if the unit is committed, then d e c o m m i t t e d an d the d u r a t i o n between o n an d off is less than 1 h, then the unit up time is violated. T h e condition " u p - t i m e - v i o l a t e d " will n o t be a fact in the database. T h e r e are a n u m b e r o f such rules which have been used in the p r o g r a m m e for checking constraint violations. 2.5. User interface A natural language permits the user to c o m m u n i c a t e with the ES during the consultation process using a h u m a n language. T h e main feature o f the user interface, here, is t h at it works as an e x p l a n a t o r y system which permits the user to answer a question with why. T h e system then responds with any i n f o r m a t i o n regarding the c o m m i t m e n t o f a particular unit at a particular time and so helps the user to u n d e r s t a n d the reasoning process. A n y question raised by the o p e r a t o r concerning the result is answered by the ES, an d i f the results seemed to be unsatisfactory, the K B was modified and the entire process r e p e a t e d until satisfactory g o o d results were obtained. 3. S A M P L E S Y S T E M The rule based ES developed here is applied to analyze an d improve the D P results o f the sample system o f Ref. [8]. F r o m various consultation sessions with the ES, it was seen t h at the system is quite helpful in improving the results. A n u m b e r o f U C runs were m a d e to test the capability and friendliness o f the ES. T h e p r o g r a m has been ru n o n an I B M - P C - A T . Th e consultation sessions provide almost all i n f o r m a t i o n a b o u t the various U C schedules given at different values o f M T I L . T h e system also gives an explanation a b o u t an y decisions t ak en by it. It was seen that, in o rd er to increase the effectiveness o f the system, a considerable database is required. As the rules included here in the K B have been obtained mainly f r o m a t h o r o u g h survey o f the literature an d are based o n heuristics, therefore, it is expected that, if the rules o b t ai n ed f r o m field experts are included here, the system will obviously pave the way for handling the practical U C problem. The sample system consists o f 10 thermal generating units with different generating capacities and start up times. T h e time span is 24 h. It was pointed out by the ES n o t to put unit 2 o ff fo r 1 h an d then restart it again. It suggested that the unit must be kept on line f r o m the f o u r t h to the sixth hour. F u r t h e r , it suggested t h at the value o f M T I L at which the earlier schedule was c o m p u t e d by D P can be increased so t h at the overall schedule will be m o r e economical. T h e final U C schedule is depicted in Table 1. KOTHARI and AHMAD: THE UNIT COMMITMENT PROBLEM 261 Table 1 Load Unit status Hour (MW) l 2 3 4 5 6 7 8 9 10 1 2000 0 1 0 2 1980 0 1 0 3 1940 0 1 0 4 1900 0 1 1 5 1840 0 0 0 6 1870 0 1 0 7 1820 0 0 0 8 1700 0 0 0 9 1510 0 0 0 I0 1410 0 0 0 11 1320 0 0 0 12 1260 0 0 0 13 1200 0 0 0 14 1160 0 0 0 15 1140 0 0 0 16 1160 0 0 0 17 1260 0 0 0 18 1380 0 0 1 19 1560 0 0 1 20 1700 0 0 1 21 1820 0 0 1 22 1900 0 1 1 23 1950 0 I 1 24 1990 0 1 1 I 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 I 1 1 1 1 1 1 1 I 0 1 0 0 1 0 0 1 0 0 1 0 0 0 1 0 0 0 1 0 0 0 1 0 0 0 1 0 0 0 1 0 1 0 1 1 1 0 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 When one compares the schedule obtained here to that obtained purely by D P [8], there is not much variation except the points discussed above, but the main feature is the capability o f the ES to approach the operator in a friendly manner. A better solution may be achieved if the knowledge o f a good number of field experts is included in the database. 4 . C O N C L U S I O N An expert system and dynamic programming hybrid has been presented for solving the unit commitment problem. The dynamic programming solution o f a sample system of 10 units was supplemented by the expert system, resulting in better management o f the units and, hence, better energy conservation. R E F E R E N C E S 1. P. G. Lowery, I E E E Trans. Power Apparatus Systems PAS-85, (1966). 2. Slobodan Ruzic and Nikola Rajakovic, I E E E Trans. Power Systems 6, No. 1 (1991). 3. Z. Ouang and S. M. Shahidepour, 1EEE Trans. Power Systems 6, No. 3 (1991). 4. Z. Ouang and S. M. Shahidepour, Electric Power System Res. 20, No. 3 (1990). 5. Sasan Mokhtari, Jagjit Singh and Bruce Wollenberg, I E E E Trans. Power Systems 3, No. 1 (1988). 6. S. K. Tong et al., I E E E Trans. Power Systems 6, No. 3 (1991). 7. C. K. Pang and H. C. Chen, I E E E Trans. Power Systems PAS-95, No. 4 (1976). 8. A. K. Ayub and A. D. Patton, I E E E Trans. Power Systems PAS-90, (1971). 9. T. Sakaguchi et al., I E E E Trans. Power Systems PAS-102, No. 2 (1983). 10. Tim Taylor et al., I E E E Trans. Power Systems 4, No. 1 (1989). 11. I. J. Nagrath and D. P. Kothari, Power System Engineering. McGraw-Hill, New Delhi (1994).