Hi all,

I was trying to scale the loads and generation in MATPower using the
following lines:

clc;clear all;
define_constants;
mpcb = loadcase('case118'); % load base case
mpct = mpcb; % set up target case with
mpct.bus(:, VM) = 1;
mpct.bus(:, VA) = 0;
mpct.gen(:, VG) = 1;
mpopt = mpoption('pf.tol', 1e-3,'pf.nr.max_it',
100,'pf.enforce_q_lims',1,'out.all', 1, 'verbose', 3);
mpct.gen(:,PG)=mpct.gen(:,PG)*1.82736;
mpct.gen(:,QG)=mpct.gen(:,QG)*1.82736;
mpct.bus(:, PD) = mpcb.bus(:, PD)*1.82736; % and increased load
mpct.bus(:, QD) = mpcb.bus(:, PD)*1.82736; % and increased load
results = runpf(mpct, mpopt);

The above code said that the power flow did not converge at that scaled
loading level. However, on changing the order of the scaling (with the rest
of the code remaining same) as follows, I got a solution:

    mpct.bus(:,PD)=mpcb.bus(:,PD)*1.82736;
    mpct.gen(:,PG)=mpcb.gen(:,PG)*1.82736;
    mpct.bus(:,QD)=mpcb.bus(:,QD)*1.82736;
    mpct.gen(:,QG)=mpcb.gen(:,QG)*1.82736;

 I have attached my published MATLAB code with the results.

Why should the two codes give different results? Is there a reason behind
having to follow a particular order? Which order should we follow?

Thank you!
-- 
Best Regards,
Shruti Dwarkanath Rao

Graduate Research Assistant
School of Electrical, Computer and Energy Engineering
Arizona State University
Tempe, AZ, 85281
650 996 0116

Attachment: MATPower_Conflicting_solutions.pdf
Description: Adobe PDF document

Reply via email to