> Dear All,
>
> Thank you for the responses. You have been a big help to me .I managed to
> add generators to other buses in case14 by adding a generator to bus 4 (row
> 6) as Dr Zimmerman suggested:
>
> *
> *
>
> *define_constants;*
>
> *mpc = loadcase('case14');*
>
> *size(mpc.gen, 1);   %gives the last row of generator data*
>
> *ng = size(mpc.gen, 1) + 1; %Specifies the start point  *
>
> *mpc.gen(ng, GEN_BUS:PMIN) = [4 0 0 10 -10 1.01 100 1 20 0];  %add 0MW to
> bus 4*
>
>
> Now if I want to increase its real power demand at bus 4 to 10 MW I add
> scripts as follows:
>
> *
> *
>
> *mpc.gen (6,PG) = 10;              %add 10MW to bus 4*
>
> *mpc.bus (6,BUS_TYPE) = 2;    %changes the type of bus 6 to PV*
>
> *runpf(mpc)*
>
>
> *But unfortunately* again I receive error which I don’t know why???
>
>
> ??? Error using ==> subsref
>
> Index exceeds matrix dimensions.
>
>
>
> Error in ==> get_reorder at 50
>
> B = subsref(A, s);
>
> Do you have any ideas?
>
>
> I am so greatful of your guidance and suggestions
>
> Regards
>
> Iman
>
>
>
>
>
>
>

Reply via email to