Implementing Level-1 MATLAB S-function

I'm using a Level-1 MATLAB S-function in simulink. Its
[sys,x0,str,ts] = fcn1(t,x,u,flag)
  • u's size is 2
  • x's size is 3
  1. How should I use this in Simulink/MATLAB?
  2. Should I enetr t and flag? How?
  3. How should I deal with inputs and outputs? Using DEMUX and MUX? How?
  4. What's the priority of u,x.t?
  5. What're the outputs that I receive?
I'll appreciate if you give me an full example.

Answers (0)

Categories

Find more on Simulink in Help Center and File Exchange

Products

Asked:

on 27 Oct 2016

Community Treasure Hunt

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

Start Hunting!