Wang-Yanping1996 / Secured-Constraints-Unit-Commitment-SCUC-model-of-Power-system

Secured Constraints Unit Commitment model of Power system, including the model based on AC flow equation and DC flow equation. Only the constraints in pre-contingency state are considered. There is a piecewise function expression for power generation costs. However, I'm sorry that the version is relative old, and it may be difficult to read or modify. 电力系统安全约束单位承诺模型,包括基于交流潮流方程和直流潮流方程的模型。 仅考虑意外前状态下的约束。 有一个用于发电成本的分段函数表达式。 但是,很抱歉该版本相对较旧,可能难以阅读或修改。 Besides, note that the model is based on the Matlab, Yalmip, and the solver is Gurobi. It can be changed to other solvers, such as Cplex, by modifying the parameter 'gurobi' in sentence 'ops = settings('solver','gurobi''. 此外,请注意,该模型基于Matlab,Yalmip,求解器为Gurobi。 通过修改句子'ops = settings('solver','gurobi'中的参数'gurobi',可以将其更改为其他求解器,例如Cplex。 If you have any idea on improving this model, please contact me. 如果您有任何改进此模型的想法,请联系我
84 stars 15 forks source link

AC-SCUC论文 #7

Open wnghaoyi opened 1 year ago

wnghaoyi commented 1 year ago

砚平学长你好,请问这个编写的AC-SCUC的模型具体用于哪篇论文中

Wang-Yanping1996 commented 1 year ago

并非我的原创,可以参考《最优潮流问题的凸松弛技术综述_林哲》的2.2章SOCP的说明,以及Convex relaxation of optimal power flow—Part I:formulations and equivalence和Convex relaxation of optimal power flow—Part II:exactness中SOCP部分

------------------ 原始邮件 ------------------ 发件人: "Wang-Yanping1996/Secured-Constraints-Unit-Commitment-SCUC-model-of-Power-system" @.>; 发送时间: 2023年4月25日(星期二) 下午4:37 @.>; @.***>; 主题: [Wang-Yanping1996/Secured-Constraints-Unit-Commitment-SCUC-model-of-Power-system] AC-SCUC论文 (Issue #7)

砚平学长你好,请问这个编写的AC-SCUC的模型具体用于哪篇论文中

— Reply to this email directly, view it on GitHub, or unsubscribe. You are receiving this because you are subscribed to this thread.Message ID: @.***>

wnghaoyi commented 1 year ago

感谢学长能给我回复,这几篇论文我会看一下的。不过,我还有三个问题希望学长能够回答一下:(1)initial文件中对目标函数的二次项进行了分段线性化,但是对模型最后的运行结果似乎没什么影响,在运行提供的case14算例时,我对线性化的分段数反复进行了调整,但调整前后的结果没有什么变化。(2)我将rts 79的数据代入到SCUC_AC模型中进行计算,发现运行速度十分缓慢,有什么办法能够提升运行速度。(3)《The Unit Commitment Problem With AC Optimal Power Flow Constraints》这篇论文也是在机组组合模型的基础上考虑交流最优潮流约束,但是同样运行6节点算例,这个模型的运行结果与文章中提供的结果存在不小的差距。

Wang-Yanping1996 commented 1 year ago

1)分段线性化的目的是尽可能地拟合二次函数,理论上分段越多,越贴近二次函数,精确度越高,理论上分段多少不会对结果产生很大影响 2)大规模系统生成的是大规模的SOCP问题,求解一定会更耗时。运行速度缓慢,指的是添加约束部分,还是求解部分,分界线为318行的toc。如果是添加约束部分,建议修改约束形式,看能否以矩阵形式批量添加,而非一行一行的添加,yalmip在前者的形式下表现会更好;如果是求解部分,建议检查求解器,代码里指定的是cplex,据我自己的使用经验,cplex12.6.3版本并不慢,理论上以后的12.8 12.9版本效率也会很高,不过也可能是在特定的某个问题上策略有问题导致的,你可以更换版本,或者更换其它的求解器,比如gurobi 3)这篇论文采用的模型和我上传的有些不一样,主要在于潮流约束,它采用的是实际的潮流方程,而我对其进行了松弛,以使得原问题(非凸问题,一般求解器无法求解,而且求解效率很低)化为一个容易被求解器求解的凸松弛SOCP问题,这样的代价是结果不精确,另外如爬坡约束、启停约束等形式也有区别,也可能对可行域造成影响,进而导致结果不同。如果想排除松弛的影响,可以引入额外的约束或者迭代,复原最优解附近的可行域,相关内容可以参考Convex relaxation of optimal power flow—Part II:exactness以及其他相关论文

------------------ 原始邮件 ------------------ 发件人: "Wang-Yanping1996/Secured-Constraints-Unit-Commitment-SCUC-model-of-Power-system" @.>; 发送时间: 2023年5月6日(星期六) 上午9:37 @.>; @.**@.>; 主题: Re: [Wang-Yanping1996/Secured-Constraints-Unit-Commitment-SCUC-model-of-Power-system] AC-SCUC论文 (Issue #7)

感谢学长能给我回复,这几篇论文我会看一下的。不过,我还有三个问题希望学长能够回答一下:(1)initial文件中对目标函数的二次项进行了分段线性化,但是对模型最后的运行结果似乎没什么影响,在运行提供的case14算例时,我对线性化的分段数反复进行了调整,但调整前后的结果没有什么变化。(2)我将rts 79的数据代入到SCUC_AC模型中进行计算,发现运行速度十分缓慢,有什么办法能够提升运行速度。(3)《The Unit Commitment Problem With AC Optimal Power Flow Constraints》这篇论文也是在机组组合模型的基础上考虑交流最优潮流约束,但是同样运行6节点算例,这个模型的运行结果与文章中提供的结果存在不小的差距。

— Reply to this email directly, view it on GitHub, or unsubscribe. You are receiving this because you commented.Message ID: @.***>

wnghaoyi commented 1 year ago

非常非常感谢学长能够解答我的问题,对我的帮助非常大

wnghaoyi commented 1 year ago

尝试了将求解器换成cplex12.9,但是在同样在case14的运算速度还不及gurobi🤣,除了以矩阵形式添加约束之外降低精度来加速迭代是否是个合理的方案

Wang-Yanping1996 commented 1 year ago

cplex不及gurobi是有可能的,降低精度来加速迭代当然可以,别太离谱就行

------------------ 原始邮件 ------------------ 发件人: "Wang-Yanping1996/Secured-Constraints-Unit-Commitment-SCUC-model-of-Power-system" @.>; 发送时间: 2023年5月8日(星期一) 下午2:52 @.>; @.**@.>; 主题: Re: [Wang-Yanping1996/Secured-Constraints-Unit-Commitment-SCUC-model-of-Power-system] AC-SCUC论文 (Issue #7)

尝试了将求解器换成cplex12.9,但是在同样在case14的运算速度还不及gurobi🤣,除了以矩阵形式添加约束之外降低精度来加速迭代是否是个合理的方案

— Reply to this email directly, view it on GitHub, or unsubscribe. You are receiving this because you commented.Message ID: @.***>

wnghaoyi commented 1 year ago

把求解器换成Mosek是不是合理一些,求解二阶锥Mosek应该比gurobi和cplex更有优势

Wang-Yanping1996 commented 1 year ago

我应该试过,貌似没有好多少

------------------ 原始邮件 ------------------ 发件人: "Wang-Yanping1996/Secured-Constraints-Unit-Commitment-SCUC-model-of-Power-system" @.>; 发送时间: 2023年5月9日(星期二) 下午4:55 @.>; @.**@.>; 主题: Re:[Wang-Yanping1996/Secured-Constraints-Unit-Commitment-SCUC-model-of-Power-system] AC-SCUC论文 (Issue #7)

把求解器换成Mosek是不是合理一些,求解二阶锥Mosek应该比gurobi和cplex更有优势

— Reply to this email directly, view it on GitHub, or unsubscribe. You are receiving this because you commented.Message ID: @.***>

wnghaoyi commented 1 year ago

整个ACSCUC模型是不是算是一个MISOCP(混合整数二阶锥规划)模型

Wang-Yanping1996 commented 1 year ago

是的

------------------ 原始邮件 ------------------ 发件人: "Wang-Yanping1996/Secured-Constraints-Unit-Commitment-SCUC-model-of-Power-system" @.>; 发送时间: 2023年5月17日(星期三) 下午4:42 @.>; @.**@.>; 主题: Re: [Wang-Yanping1996/Secured-Constraints-Unit-Commitment-SCUC-model-of-Power-system] AC-SCUC论文 (Issue #7)

整个ACSCUC模型是不是算是一个MISOCP(混合整数二阶锥规划)模型

— Reply to this email directly, view it on GitHub, or unsubscribe. You are receiving this because you commented.Message ID: @.***>