1

I have been wondering this for some time now and was curious about the most logical implementation for simulating block diagram based time-domain models.

I don't know if that term is correct, but if you know Simulink you know what I mean.

There reason I am wondering is is that I have made some simulation models myself now, but I always get stuck when I am creating feedback loops. Most of the time this is not a problem when I am working with blocks that I can translate to the state-space domain, but when I get more complex elements this becomes a problem.

Practically I can not seem to get my head around how Simulink solves this.

I had thought that practically for every timesample every block calculates it current state and passes that to the connected blocks for the next timesample, however when you have:

->A->B->C->D
  ^-----|

4 blocks with a feedback to A and an input to A, it takes 3 timesamples to reach C, after which C will start emitting to A again. Before that C would have been emitting it's initial value. It takes 4 timesamples to reach D.

When A,B,C,D are simple laplace-like elements this is easily combined in a state-space or transfer function from A to D, however the results will be monumentally different. Because it will take 1 timesample from A to D and from C to A. I know that when the transfer function requires you, in general, to specify the initial conditions, but these conditions are not translateable (or I can not see it) to the block diagram solution. How do you tackle this problem in a generic way?

avanwieringen
  • 2,404
  • 3
  • 21
  • 28

0 Answers0