summaryrefslogtreecommitdiff
path: root/122/CH2/EX2.a.12/exaA_2_12.sce
blob: 8000082a9f6078be59388448528a046df104db43 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
// Example A-2-12
// Conversion from state space model to transfer function model
//            for a multiple input multiple output system 

clear; clc; close;

// Please edit the path below
// cd "/your code directory/";
// exec("transferf.sci");

A = [0 1; -25 -4];
B = [1 1; 0 1];
C = [1 0; 0 1];
D = [0 0; 0 0];

Htf = transferf(A,B,C,D)     // Htf is the tranfer function matrix,
disp(Htf,'Htf =');           // with four transfer functions  - 
                             // Htf(1,1),Htf(1,2),Htf(2,1),Htf(2,2);