I cannot reproduce the error here. For me, this case runs just fine. Is it 
possible that you have modified some of the MATPOWER files in some way? If so, 
I suggest doing a clean install of MATPOWER 4.1, plus the updated smartmkt.m 
and try again.
  
-- 
Ray Zimmerman
Senior Research Associate
419A Warren Hall, Cornell University, Ithaca, NY 14853
phone: (607) 255-9645




On Mar 22, 2012, at 7:06 PM, Dailan Xu wrote:

> Dear Prof. Zimmerman,
> 
> After replacing the new smartmkt code I get an error as follows for the 
> following code:
> 
> define_constants;
> mpc0 = loadcase('case6ww');
> mpc = load2disp(mpc0);
> mpc.branch(:, RATE_A) = 0;  % disable flow limits
> offers.P.qty = [200; 150; 180];
> offers.P.prc = [30; 40; 50];
> bids.P.qty = [70; 70; 70];
> bids.P.prc = [100; 100; 100];
> mkt.OPF = 'DC';
> [r, co, cb] = runmarket(mpc, offers, bids, mkt);
> co.P.prc
> 
> 
> Shutting down generator 3.
> ??? Index exceeds matrix dimensions.
> 
> Error in ==> smartmkt at 206
>     qgcost = mpc.gencost(ng+(1:ng), :);
> 
> Error in ==> runmarket at 141
> [co, cb, r, dispatch, success] = smartmkt(mpc, offers, bids, mkt, mpopt);
> 
> What is the reason?
> 
> Best Regards
> 
> D. Xu
> 
> 
> 
> On Thu, Mar 1, 2012 at 17:33, Ray Zimmerman <[email protected]> wrote:
> Sorry, the problem may have been due to a bug in smartmkt.m. I realized based 
> on an error experienced by someone else that runmarket had never been tested 
> with reactive power *costs*, only with reactive bids and offers. I've 
> attached a new version of smartmkt.m that should hopefully fix that bug.
> 
> 
> 
> 
> -- 
> Ray Zimmerman
> Senior Research Associate
> 419A Warren Hall, Cornell University, Ithaca, NY 14853
> phone: (607) 255-9645
> 
> 
> 
> 
> On Feb 29, 2012, at 7:06 PM, Dailan Xu wrote:
> 
>> Dear Prof. Zimmerman,
>> 
>> I have trusted you and I have sent you the m.files also I don't want 
>> distribute these files and I sent them only to you.
>> 
>> I tried your suggestions but again it doesn't work. I don't want you to 
>> debug the errors. The main objective is this as I want to have active and 
>> reactive offers and bids, therefore, want to maximize social welfare and 
>> consequently want to have reactive costs. I am not sure either it is 
>> necessary or not.
>> 
>> It is my pleasure working with you. 
>> 
>> Best Regards
>> 
>> Dailan
>> 
>> On Wed, Feb 29, 2012 at 17:21, Ray Zimmerman <[email protected]> wrote:
>> You are setting your generator costs to be piecewise linear costs with 3 
>> points defining the curve (6 more columns) but then you only provide 3 more 
>> columns (which look like they are polynomial coefficients).
>> 
>> But honestly, I really can't afford to keep providing this level of 
>> debugging support for you. If you need further assistance of this type, we 
>> can discuss a consulting arrangement and I'll be happy to work with you. You 
>> can also feel free to post on the MATPOWER-L and if anyone else has time to 
>> help that will be up to them.
>> 
>> -- 
>> Ray Zimmerman
>> Senior Research Associate
>> 419A Warren Hall, Cornell University, Ithaca, NY 14853
>> phone: (607) 255-9645
>> 
>> 
>> 
>> On Feb 29, 2012, at 10:46 AM, Dailan Xu wrote:
>> 
>>> Dear Prof. Zimmerman,
>>> 
>>> I want to use reactive cost as objective function, i.e both and active and 
>>> reactive costs. When I do runmarket also runopf I get the following error. 
>>> The files are attached.
>>> 
>>> Error in ==> totcost at 53
>>>         pp = mkpp(x(i, 1:gencost(i, NCOST))', [(y(i,j2) - y(i,j1)) ./ 
>>> (x(i,j2) -
>>>         x(i,j1));  y(i,j1)]');
>>> 
>>> Error in ==> smartmkt at 191
>>> fcost   = mkt.t * totcost(mpc.gencost, zeros(ng, 1) );      %% fixed costs
>>> 
>>> Error in ==> runmarket at 141
>>> [co, cb, r, dispatch, success] = smartmkt(mpc, offers, bids, mkt, mpopt);
>>> 
>>> Error in ==> ANM_9 at 299
>>> [r, co, cb, f, dispatch, success, et] = 
>>> runmarket(mpc,offers,bids,mkt,mpoption);
>>>  
>>> 
>>> Best Regards
>>> 
>>> Dailan
>>> 
>>> <ANM_9.m><case84_newdispatch6_10.m>
>> 
>> 
> 
> 
> 

  • smartmkt Dailan Xu
    • Re: smartmkt Ray Zimmerman

Reply via email to