Switching cases in simulink

조회 수: 13 (최근 30일)
Tommy
Tommy 2014년 11월 6일
댓글: Tommy 2014년 11월 9일
Hi Everyone
I have a question regarding to Simulink.
Is there a way to switch between two transfer function block based on the simulation time.
For example, when t <= 100, input signal will flow into the first transfer function, when t > 100, input signal will flow into the other transfer function block.
Please advise me.
Thank you for your help.
Tommy

채택된 답변

Orion
Orion 2014년 11월 9일
Not exactly,
the clock block outputs the current running time when you simulate a model. (0, 0.01, 0.02,... if you simulate in fixed-step with a sample time of 0.01 s.)
the '10' in the editor is the final time of the simulation.
if you want to change the time parameters of the simulation, make some changes in the configuration of the model.
Simulation->Configuration parameters (or ctrl+E).
  댓글 수: 1
Tommy
Tommy 2014년 11월 9일
Thank you very much for your help, Orion.

댓글을 달려면 로그인하십시오.

추가 답변 (1개)

Orion
Orion 2014년 11월 6일
just use a switch and 2 transfer functions
  댓글 수: 1
Tommy
Tommy 2014년 11월 9일
May I ask does the 'Clock' block represents the simulation time that is set at the top of the diagram (The '10' next to the record button) ?

댓글을 달려면 로그인하십시오.

카테고리

Help CenterFile Exchange에서 Sources에 대해 자세히 알아보기

제품

Community Treasure Hunt

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

Start Hunting!

Translated by