# Lecture – 35 Optimal Load Flow (Contd.) This is our last class lecture 35, Optimal Load Flow we continue, and we introduce and finish Hydro Thermal Scheduling. Last time we did out with equality constraints if you recall the optimal load flow. Today, we are doing with inequality constraints Now, inequality constraints all of you understand, what is the meaning of inequality constraints, it is less than equal to& Now, inequality constraints can be there on control variables, it can be there on dependent variables. Now, these two inequality constraints have to be tackle in two different ways. Let us first consider, the inequality constraints on control variable: control variables is normally specified in control systems by u, so U min less than equal to u less than equal to u max. For example, power generation that can be control variable, you can control power generation by controlling the water gate opening or steam input So, P G i min less than equal to P G i less than equal to P G i max. Now, when you add delta u i to get the latest value of control variable, you check whether this mu, new mu is within this limits or not this is what you have to check, this must be always satisfied If this delta u causes u i to cross any one limit, you can other cross the upper limit or lower limit not both simultaneously As I have been always saying either you are in inside the hall or you are outside. You cannot be both only God is only present. So, then what you do, if this happens then put u i equal to corresponding limit; that means, either it will be u max or it will be u min, it cannot be both and proceed, because you cannot have gate opening more than the gate Suppose you have a 10 rupees, you cannot spend more than 10 rupees that is upper limit, so spent 10 rupees only So that means, u new will be either equal to u max, if the upper limit is crossed, u old plus delta u i is greater than u max or it will be u i min, if lower limit is crossed If the u new is between the limits, then put equal to whatever is the value you are getting, otherwise OW is otherwise, this should be clear to you. So, u new u will take one of the three values, when there is inequality constraint either it will take the upper limit or lower limit or actual value which lies between the two limits Now, K-T is Kool-Tooker conditions, I hope you have by now, master this K-T conditions, because we are applying them again and again and again, what do this condition tell, please read them in appendix e of anyone of the books, they say these are only necessary condition not sufficient, I already explained you, what is necessary condition and what is sufficient condition, for you to pass the course it is necessary to appear in exam not sufficient,  Now that means the original cost C (x, u) now get modified by adding the penalty cost, this is called penalty cost. So, now you have to minimize, original cost, fuel cost plus penalty cost, you cannot give penalty as much as you want, can you deliver the book after 1 year, no he may take the penalty almost the cost of the book, it is better to purchase the book rather give penalty for 1 year. So, this penalty does not mean, you can have any amount of penalty cost; no this has to be a part of minimization process. So, C dash is the new modified objective function, original objective function plus cost function For violating j th inequality constraints, this is the cost W j all such constraints summation j. So, total penalty cost is sigma j W j all variables will not cross limits, otherwise is something wrong with your definition of limits. Suppose, you put your limits so stringent 0.99 per unit to 1.01 per unit all the PQ was voltages will cross the limit, because you foolishly kept such a limit which is not possible in India, because voltages go minus infinity to plus infinity. So, you have to at least put 0.9 per unit to 1.1 per unit then it is likely that some of the variables, voltage variables will not cross the limits So that is why, I have put it here j, otherwise I put all j This is the graph which is very important to understand Y axis is penalty cost, x axis is the x variables, if It is between x lower bar means, x min there was no place to write min. So, I have to written x lower bar, x upper bar means, x max why upper bar and lower bar are not normally used, because it can be misunderstood by vector sign and even lower bar some people write for some special meaning So, I write x min x max with no confusion, but here, because of the space constraints, let me use the word constraint, I put x lower bar and x upper bar, if there between this two limits, no problem this dotted line which is the Rigid Limit no penalty, penalty is 0. The moment x crosses either the upper bar or lower bar this quality curve is there So, penalty starts increasing moment x crosses limit and as it moves away from the limit, the Rigid Limit, the penalty also increases, the penalty cost characteristics you can choose, it can be quadratic, it can be cubic, it can be exponential, suppose they are very strict, if you give book after 10 days, you can see you are suspended or 1000 rupees that is various stringent penalty This is the model, I have chosen W j is equal to gamma j x j minus x j max whole square, gamma j x j minus x j min whole square, luckily one of the two will be there, as I have been repeatedly telling you, either it crosses upper limit or it crosses lower limit, you cannot have both, so it crosses upper limit this equation, if it crosses lower limit this equation and gamma j is called Penalty Factor, not power factor, but penalty factor It is up to you to choose, what penalty factor you want, I will talk, I will comment on this selection of gamma j after some time, why have put square here, penalty cost should be positive, you cannot have negative penalty, you cannot given award for someone for not giving book in proper time, no problem, well done, here 1000 rupees for you, I think no where no library will give you reward or award for depositing book late, no appreciations for that hence we had to have positive penalty cost, so square Now, the necessary condition are Kool Tooker conditions gets modified, you get the W j also terms here, which is quite understandable, because W j is definitely a function of x   and so on What are the parameters to be called oneself developed countries like Singapore is a developed country now. So fuel cost is 0 as per the water is constraints. So, availability water consideration makes it a dynamic optimization; that means, you working for a given period and dynamic optimization problem is always more complex then static optimization We still try to minimize thermal cost with respective to constraints, what are the constraints, main constraint is water constraint. Two types of water constraints storage, reservoirs, inflow, how much inflow is available; that is a data of course, so depending on this, they we have to minimize over a given period Period either said can be day week, month, year. Here is the simplest possible hydrothermal system drawn, why simplest possible, he has to at least one hydro station, one thermal system to justify calling it hydro thermal system; that is why it is called Fundamental Hydrothermal System, because you cannot go below this, here is the thermal power station, here is the hydro power station, here is the load, this is a P G T power generation by thermal plant, P GH power generation by hydro plant, this will& You will now learn, how to specify suffix, prefix, subscripts, you know, why G, G generation, why T, T is thermal, you cannot write anyone of the A, B, C, D here. So, this make sense, P is power, so power generation by thermal plant, this is a hydro power plant, this is J is inflow universally J is used as inflow, X is a storage and this is the water discharge q and here is turbine we generates power and power goes to the grid water discharge, the control variable here is water discharge gate opening, we should know anyway, because of AGC he must have done hydro thermal system in AGC Let me tell you one more thing, hydro power plants are of three types, we are interested in storage types, because optimization is only possible in storage tank. The second one is pondage type and third one is run of the river. Here, we are not considering small hydro, which is renewable, no this hydro is also renewable, but small hydro is normally considered in our non conventional energy sources below 15 megawatt, 1 to 5 megawatt is min Hydro Power Plant, below 1 megawatt is Micro and below few kilo watts is Nano and now a days is a area of Nano, everything Nanotechnology Idea is whatever power you can generate, it is welcome, it is power is a commodity which is in short supply at least in developing world; storage is something where you can really apply optimization, what is pondage, what is coming all the time, but you cannot control it, why you cannot control it, you cannot store it, it is coming, so put a turbine and generate power and feed it to grid, but there is no control, there is no optimization, this is a bonus, it is not a salary, you get a bonus once in a year and use it way you want to use it, it helps to improve your you know, condition, lifestyle Run of the river is as an when water comes use it, like a deleverage as an when he gets offer to come, he comes to IIT everyday at 8 o clock or today are not required sorry  get a call, but the land line call, you really do not know when it will come, customer in a shop, when customer will come, nobody knows a death, though it is a certainty, but when it is going to come, I do not think anybody knows So, water inflow and load these two are random variables and if you consider the random variables then the problem becomes stochastic scheduling of hydro thermal system, but I am going to consider only Deterministic, Stochastic may be next time, because it is very interesting and very fascinating to deal with stochastic problem, because then you have to minimize expected cost, standard deviation, the moments, they all coming to play, the best book in this case if you want to learn random variables is populous and that is the wonderful book random variable and stochastic processes Control variable you have chosen is q. Objective function is minimization of C T integral 0 to T C dash P G T t dt, t is a total period day, month, week What are the other constraints: total Power Generation Thermal plus total Power Generation Hydro minus loss minus demand should be 0 within this time period 0 to T, I think you know, this thing if it is square bracket including 0 and T, if it is a small bracket leaving that final point, both small 0 and T both are not considered. So you know these things Water Availability: the final water storage minus initial water storage must be equal to total input minus total output, I hope this is clear to you This is the reservoir, lets a month of August, in the beginning of August this is the water storage, at the end of August this is the water storage, during August this is the inflow and outflow is or discharge is q 1. So, X 1 is equal to X 0 plus input minus output, this is called Water Continuity Equation, Water Continuity Equation wish you must have done in control system plant equation So water availability is this and hydro power is defined as head into water discharge, but if you want total equation, it is a function of storage and water discharge, I will give exact equation after 2 minutes, but nobody solves now problem in continuous time variables, all of you must be intelligence enough to understand by now, see you are using computers, we discretize the problem So, computer won t take continuous values, it you have discretize; that means you have to have a subinterval, if it is a day 24 hours divide into 8 parts, 3 hours each. If you have more for see 24 hour, 1 hour each. So, optimization interval T is divided into N subintervals. Week 7 days, month 30 days, year 12 months or 365 days or 52 weeks depending on what you want We assume that in each subinterval variables remain fixed in value, otherwise it is very difficult to handle the problem, if I am considering 1month as a sub interval during that month inflow is constant, outflow is given, the water storages are given anyway in the beginning and the end of the period otherwise there will be caves So, now the problem is you want to minimize delta t times the cost with reference to the   