在Simulink裏面對速度曲線積分,直接在速度模塊後面接積分器
有一個報錯信息:
因爲在Simulink裏面用到了全局變量,MATLAB answer裏面給了一個解釋
You can switch the entire model to discrete time or you can use rate transition blocks to move back and forth between continuous and discrete .
也就是說要把連續變量轉化成離散量才能正常使用。把積分器改成Rate Transition和Discrete-Time Integrator就解決了