内置 Python Gekko 流程对象(例如反应器模型)的方程式和其他细节是什么?Gekko 拥有我在将非线性模型预测控制 (MPC) 应用于气相流化床聚合物(聚乙烯)反应器的工业应用中所需的化合物。
from gekko import GEKKO, chemical
m = GEKKO(remote=False)
c = chemical.Properties(m)
c.compound('ethylene') # primary monomer reactant
c.compound('propylene') # co-polymer monomer reactant
c.compound('hydrogen') # melt-index modifier
c.compound('ethane') # inert
c.compound('propane') # inert
c.compound('cyclohexene') # density modifier
c.compound('isopentane') # condensing agent
c.compound('nitrogen') # pressure control
f = chemical.Flowsheet(m)
r = f.reactor(ni=2)
m.options.SOLVER = 1
m.solve()
这个简单的反应器模型产生以下输出:
--------- APM Model Size ------------
Each time step contains
Objects : 1
Constants : 0
Variables : 12
Intermediates: 0
Connections : 12
Equations : 0
Residuals : 0
Number of state variables: 29
Number of total equations: - 10
Number of slack variables: - 0
---------------------------------------
Degrees of freedom : 19
----------------------------------------------
Steady State Optimization with APOPT Solver
----------------------------------------------
Iter Objective Convergence
0 2.55529E-16 1.38889E+00
1 2.38753E-25 1.23358E-16
2 2.38753E-25 1.23358E-16
Successful solution
---------------------------------------------------
Solver : APOPT (v1.0)
Solution time : 0.026300000000000004 sec
Objective : 0.
Successful solution
---------------------------------------------------
如何找到有关 10 个方程和 29 个变量的更多详细信息?我对性能控制(熔体指数和密度)感兴趣,并通过调整催化剂、氢气和共聚单体(丙烯、异丁烯等)来最大限度地提高生产率。