Hi Anirudh,

I think you misunderstand the purpose of case2off.m. I'm not sure where you got 
the idea that it does something "optimal". I simply converts the cost data in 
gencost into an offer consisting of a set of price/quantity pairs. In other 
words, it is the same data in a different format, essentially a representation 
of marginal cost instead of total cost (as in gencost). You can convert the 
data back and forth between the two formats using case2off.m and off2case.m. 
The purpose of case2off.m was simply to generate marginal cost offer inputs for 
runmkt. Here is one way you might use it.

mpc = loadcase('t_auction_case');
[q, p] = case2off(mpc.gen, mpc.gencost);
G = find( ~isload(mpc.gen) );   %% real generators
L = find(  isload(mpc.gen) );   %% variable loads
offers = struct( 'P', struct( 'qty', q(G, :), 'prc', p(G, :) ) );
bids   = struct( 'P', struct( 'qty', q(L, :), 'prc', p(L, :) ) );
[results, cleared_offers, cleared_bids] = runmarket(mpc, offers, bids);

This runs an auction in which all generators are offering full capacity at 
marginal cost and all dispatchable loads are bidding their maximum quantity at 
the value of their marginal benefit. The OPF result is identical to simply 
running the case file directly (results = runopf('t_auction_case')), it's just 
that the result is also returned as a set of cleared offers and bids.

Regarding your second question (b), as I said before, in MATPOWER's auction 
markets there is no such thing as a transaction between generators. The 
transaction is always between the generator and the ISO. The offer quantity 
determines the maximum amount the ISO can buy from a generator.

--
Ray Zimmerman
Senior Research Associate
211 Warren Hall, Cornell University, Ithaca, NY 14853
phone: (607) 255-9645



On May 23, 2010, at 1:58 PM, Anirudh Raghavan wrote:

Hello

This is a query relating to the use of smart_market code to generate
optimum bid pricing for a set of generators. I read that case2off.m is
responsible for the conversion of 'gencost' and 'gen' data to an
optimum set of bids to buy/sell power to minimize total cost of
meeting demand. I'd like to know:
a) How to run this code.
b) How to apply a fixed transaction limit between any two particular generators.

Any help will be greatly appreciated.

Thanks
Anirudh

On Sat, May 22, 2010 at 12:30 AM, Ray Zimmerman 
<[email protected]<mailto:[email protected]>> wrote:
MATPOWER 4.0b4 is available for download from the MATPOWER home page ...

http://www.pserc.cornell.edu/matpower/

The primary changes from version 4.0b3 are:

* New features:
 - Added support for the IPOPT interior point optimizer for large scale
   non-linear optimization. Use OPF_ALG = 580 and OPF_ALG_DC = 400 for
   AC and DC OPF, respectively. Requires the Matlab MEX interface for
   IPOPT, available from https://projects.coin-or.org/Ipopt/.
 - Added RETURN_RAW_DER option to control when OPF solver returns
       constraint, Jacobian and objective function gradient and Hessian
       information.
 - Refactored portions of opf() into opf_setup() and opf_execute().
* Bugs fixed:
 - Added check for invalid gencost model value in opf_setup().

For a complete and detailed list of changes from previous versions, see the 
CHANGES file in the distribution, also available at:

http://www.pserc.cornell.edu/matpower/CHANGES.txt

As always, please send any bug reports, suggestions and comments, to the 
MATPOWER mailing list (instructions on MATPOWER home page).

Enjoy!

Ray Zimmerman
Senior Research Associate
211 Warren Hall, Cornell University, Ithaca, NY 14853
phone: (607) 255-9645









Reply via email to