フィルターのクリア

How to control no. of simulations/iterations of embedded MATLAB program in Simulink model

1 回表示 (過去 30 日間)
I have a an embedded MATLAB program(PSO algorithm) to sense the power from solar panel and send dutycycle to a buck boost converter to track the Maximum Power Point(MPP). Its not sensing properly as it should..
I set a Simulation time of 0.01. To see how many times the model is simulated i removed the semicolons of output statements in the program. it is simulating very larger no of times.
but by default, the total simulation time should be divided by 50, and it should simulate 50 times i thought.
If i need to simulate limited no of times, how to do..
  2 件のコメント
Kaustubha Govind
Kaustubha Govind 2013 年 1 月 17 日
What is the Solver that you've selected in the Configuration Parameters window of the model? The default 50 steps only applies to fixed-step solvers whose step-size has been set to auto.
V Vaishnavi Kumar
V Vaishnavi Kumar 2013 年 1 月 17 日
Variable Step, ode23tb only..... In this type can no. of simulations be controlled....or have to use fixed step

サインインしてコメントする。

回答 (1 件)

Kaustubha Govind
Kaustubha Govind 2013 年 1 月 17 日
Please read the section Choose a Solver to understand the difference between Fixed-step and Variable-step solvers. By definition, variable-step solvers automatically figure out the next time-step to take in the simulation to achieve the most accurate results possible for your system - therefore, AFAIK, it is not possible to specify the number of steps. However, I think you can specify the smallest step-size that it should take.

カテゴリ

Help Center および File ExchangeGeneral Applications についてさらに検索

Community Treasure Hunt

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

Start Hunting!

Translated by