Filter löschen
Filter löschen

How to add unmodeled delay dynamics at some input - append function problem

1 Ansicht (letzte 30 Tage)
Hello world,
I came across the "Control of a Spring-Mass-Damper System Using Mixed mu-Synthesis" I found here.
First of all I don't quite understand what the "append" function does in that context - I already checked the Matlab documentation but I still don't understand what it does here - and then I don't understand why I get an error with my code.
Again, I have a MSD system - 6 inputs and 4 outputs - and I wuold like to add the unmodeled delay dynamics to the 5th and 6th input but I got the error that "Model I/O dimensions must agree (Line 80)" (Line 80 refers to append function).
Basically, I'm performing an analysis which is really close to that of the link.
plant=ss(A,B,C,D);
plant.StateName={'x1';'x2';'x3';'x1dot';'x2dot';'x3dot'};
plant.OutputName={'zpx';'zpu';'y1';'y2'};
Delta=ultidyn('Delta',[1 1]);
Wtau=2.1*tf([1 0],[1 40]);
plant=plant * append(1+Delta*Wtau,5);
plant.InputName={'d1';'d2';'theta1';'theta2';'u1';'u2'};
  6 Kommentare
Walter Roberson
Walter Roberson am 8 Aug. 2019
Question: do you want to delay inputs 5 and 6 for all computations with plant, or do you want to "tap" those inputs and use them delayed for something and also use them undelayed with plant ?
You cannot get at inputs 5 and 6 of plant by right multiplying plant by anything -- not unless those inputs are already flowing as outputs to plant. Right multiplying has the effect of taking the outputs of plant and doing something with them, so if the outputs of plant do not include the signals you want, then you cannot get at them by doing a right-multiply.
You might think for a moment that you could left-multiply to have the effect of cloning signals 5 and 6 of inputs,
1 0 0 0 0 0
0 1 0 0 0 0
0 0 1 0 0 0
0 0 0 1 0 0
0 0 0 0 1 0
0 0 0 0 0 1
0 0 0 0 1 0 %clone input 5
0 0 0 0 0 1 %clone input 6
but if you do that then you end up with a 1 x 8 signal block and that is not suitable for right-multiplying with something that expects 6 inputs.
You might possibly end up needing to use vertcat() or horzcat(). (I do not have much experience with ss models -- not that I have all that much experience with tf, but I have more experience with tf than ss)

Melden Sie sich an, um zu kommentieren.

Antworten (0)

Community Treasure Hunt

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

Start Hunting!

Translated by