Dear Dr. Ray D. Zimmerman
Ok I get it now, Thank you very much for your reply. From: Ray Daniel Zimmerman<mailto:[email protected]> Sent: Wednesday, 9 December, 2020 1:40 AM To: MATPOWER-L<mailto:[email protected]> Subject: Re: Load Shedding In OPF Using load2disp() When the OPF does not converge, the results should be disregarded since they do not represent a valid solution. The only reason they are returned at all is that it can sometimes be useful to know where the solver was when it gave up. Ray On Dec 8, 2020, at 1:54 AM, KHALDON AHMED QAID AL-AREQI <[email protected]<mailto:[email protected]>> wrote: Dear Dr. Ray D. Zimmerman Thanks for this creative tool. I am new using MATPOWER, am not sure if I do it correctly here. I am trying to do load shedding scenarios using load2dis() in OPF for case9. In each scenario, there are generators out of the service. For example, the first scenario is assuming one generator off and the second scenario is assuming two generators off. However, in scenario three when three generators out of the service, which means it does not converge, I can still see in the results.gen 50% of the load is connected to the system with no generators power MW. I expected that when the generators are zero, all the connected load should be zero moves to load shedding. The code I used is clear; define_constants; mpopt = mpoption('out.all', 1, 'verbose', 0); mpopt=mpoption(mpopt,'opf.ac.solver', 'FMINCON'); mpc=loadcase('case9'); mpc = load2disp(mpc); mpc.gen([1 2 3],GEN_STATUS)=0; results=runopf(mpc,mpopt); LoadShed=results.gen([4 5 6], PG) ConnectedLoad = total_load(results) The results I get are >>>>> Did NOT converge (0.03 seconds) <<<<< LoadShed = -35.9692675358089 -40.0191108315373 -50.0298559599331 ConnectedLoad = 126.018234327279 Am not sure if the code correct or am I taking the load shedding results data from the wrong place. Thank you , any help is appreciated Khaldon Qaid
