Open ZedongPeng opened 9 months ago
If we reconstruct the constraint, the result will be correct as follows.
x2dotcon : Size=30, Index=t, Active=True
Key : Lower : Body : Upper : Active
0.007962 : 0.0 : x2dot[0.007962] - (x1[0.007962] + u[0.007962]**2) : 0.0 : True
0.039603 : 0.0 : x2dot[0.039603] - (x1[0.039603] + u[0.039603]**2) : 0.0 : True
0.087595 : 0.0 : x2dot[0.087595] - (x1[0.087595] + u[0.087595]**2) : 0.0 : True
0.139093 : 0.0 : x2dot[0.139093] - (x1[0.139093] + u[0.139093]**2) : 0.0 : True
0.180293 : 0.0 : x2dot[0.180293] - (x1[0.180293] + u[0.180293]**2) : 0.0 : True
0.2 : 0.0 : x2dot[0.2] - (x1[0.2] + u[0.2]**2) : 0.0 : True
0.207962 : 0.0 : x2dot[0.207962] - (x1[0.207962] + u[0.207962]**2) : 0.0 : True
0.239603 : 0.0 : x2dot[0.239603] - (x1[0.239603] + u[0.239603]**2) : 0.0 : True
0.287595 : 0.0 : x2dot[0.287595] - (x1[0.287595] + u[0.287595]**2) : 0.0 : True
0.339093 : 0.0 : x2dot[0.339093] - (x1[0.339093] + u[0.339093]**2) : 0.0 : True
0.380293 : 0.0 : x2dot[0.380293] - (x1[0.380293] + u[0.380293]**2) : 0.0 : True
0.4 : 0.0 : x2dot[0.4] - (x1[0.4] + u[0.4]**2) : 0.0 : True
0.407962 : 0.0 : x2dot[0.407962] - (x1[0.407962] + u[0.407962]**2) : 0.0 : True
0.439603 : 0.0 : x2dot[0.439603] - (x1[0.439603] + u[0.439603]**2) : 0.0 : True
0.487595 : 0.0 : x2dot[0.487595] - (x1[0.487595] + u[0.487595]**2) : 0.0 : True
0.539093 : 0.0 : x2dot[0.539093] - (x1[0.539093] + u[0.539093]**2) : 0.0 : True
0.580293 : 0.0 : x2dot[0.580293] - (x1[0.580293] + u[0.580293]**2) : 0.0 : True
0.6 : 0.0 : x2dot[0.6] - (x1[0.6] + u[0.6]**2) : 0.0 : True
0.607962 : 0.0 : x2dot[0.607962] - (x1[0.607962] + u[0.607962]**2) : 0.0 : True
0.639603 : 0.0 : x2dot[0.639603] - (x1[0.639603] + u[0.639603]**2) : 0.0 : True
0.687595 : 0.0 : x2dot[0.687595] - (x1[0.687595] + u[0.687595]**2) : 0.0 : True
0.739093 : 0.0 : x2dot[0.739093] - (x1[0.739093] + u[0.739093]**2) : 0.0 : True
0.780293 : 0.0 : x2dot[0.780293] - (x1[0.780293] + u[0.780293]**2) : 0.0 : True
0.8 : 0.0 : x2dot[0.8] - (x1[0.8] + u[0.8]**2) : 0.0 : True
0.807962 : 0.0 : x2dot[0.807962] - (x1[0.807962] + u[0.807962]**2) : 0.0 : True
0.839603 : 0.0 : x2dot[0.839603] - (x1[0.839603] + u[0.839603]**2) : 0.0 : True
0.887595 : 0.0 : x2dot[0.887595] - (x1[0.887595] + u[0.887595]**2) : 0.0 : True
0.939093 : 0.0 : x2dot[0.939093] - (x1[0.939093] + u[0.939093]**2) : 0.0 : True
0.980293 : 0.0 : x2dot[0.980293] - (x1[0.980293] + u[0.980293]**2) : 0.0 : True
1 : 0.0 : x2dot[1] - (x1[1] + u[1]**2) : 0.0 : True
Hi @blnicho . Any idea about this?
Summary
Currently, the DAE transformation ignores the derivative equations in
Disjunct
. It would be highly beneficial if we can support it.Rationale
If we try the following code, the derivative equation inside
Disjunct
will not be transformed.Output
Description
Maybe we just need to change some
component_objects(Block, descend_into=True)
intocomponent_objects([Block, Disjunct], descend_into=True)
. Any ideas? @blnicho