How to simulate a model with a different timestep using a model block

2 次查看(过去 30 天)
I'm using a model block in my model. This submodel block should run several times during the execution of the model.
Both models have a different stop time in their solver and both are discrete with a fixed timestep.
When I run the model, it starts to execute both models together while the MODEL block should run totally every timestep in the main model.
Can I imply it using some option of the model block or is it impossible in simuling??

采纳的回答

Ryan G
Ryan G 2012-11-20
Based on the description it sounds like you want a MODEL BLOCK to run faster than the main model using a fixed time step. This is not possible directly.
However, you can use a for each subsystem that will run the contents of the subsystem multiple times per time step. You may be able to wrap the entire contents of the model block in this type of subsystem to run at a faster rate.
Furthermore, you imply you want the model to run independently (different start/stop times), which is also not possible directly. You could create 2 seperate models and use UDP Send and receive blocks to communicate between the two. This would allow each model to function completely independent of eachother.

更多回答(0 个)

类别

Help CenterFile Exchange 中查找有关 Multicore Processor Targets 的更多信息

产品

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by