Yes, user-defined variables can only be used in linear constraints, so if you need them to be included in the power flow equations you'd need to modify the code that computes the Jacobian and Hessian, which is non-trivial.
-- Ray Zimmerman Senior Research Associate B30 Warren Hall, Cornell University, Ithaca, NY 14853 phone: (607) 255-9645 On Aug 12, 2013, at 12:27 PM, [email protected] wrote: > Dear all, > I try to calculate lambda in cpf by using extended OPF > formulation: > > min f(x) + fu(x; z) > subject to > g(x) = 0 > h(x) <= 0 > xmin <= x <= xmax > l <= A[x; z] <= u > zmin <= z <= zmax > > However, if we want to do cpf, lambda must be considered in Jacobi and > Hessian matrix, such as > > g(x, lambda) = 0 > h(x, lambda) <= 0 > > From extended OPF formulation, does it mean that user-define variable can > only be used in linear constraint? > Then the origin goal is impossible if I don't modify Jacobi and Hessian by > myself? > >> Regards, >> LarryHo > > 寄件者: Ray Zimmerman <[email protected]> > 收件者: MATPOWER Discussion List <[email protected]> > 寄件日期: 2013/8/7 (週三) 2:02 AM > 主旨: Re: About using opf to do cpf > > It may be possible to use the OPF with user-defined variables/constraints to > solve the problem you have in mind, but you would need to specify the > formulation of your problem in more detail to be sure. There are examples of > some simple user-defined extensions to the OPF in the OPF test functions > (e.g. t/t_opf_mips.m). > > -- > Ray Zimmerman > Senior Research Associate > B30 Warren Hall, Cornell University, Ithaca, NY 14853 > phone: (607) 255-9645 > > > > > > On Aug 6, 2013, at 7:27 AM, [email protected] wrote: > >> Dear all, >> >> I am wondering if it is possible to use opf's user-define variable to >> calculate lambda in cpf? >> Such as >> >> max lambda >> F(x, lambda) = 0 >> >> And where can I find the example of user-define function? It's not that >> helpful by reading the manual. >> >> Regards, >> LarryHo
