# Matlab Transfer function multiple single s terms

2 Ansichten (letzte 30 Tage)
Aaron Frost am 20 Feb. 2023
Kommentiert: Paul am 22 Feb. 2023
How can modify this script in order to get the transfer function shown in the picutre. Thanks.
C1 = 0.000000000150;
C2 = 0.000000000470;
R1 = 10000;
R2 = 180000;
R3 = 2700;
R4 = 56000;
A = 1/(C1*R2);
B = 1/(C2*R2);
C = (1/(C1*R1))*(1-G);
D = 1/(C1*C2*R1*R2);
G = (R3+R4)/R3;
%{
Numerator = {[G 0 0] };
Denominator = {[1 0] [A] [B] [C] [0 D]};
T = tf(Numerator, Denominator)
%}
T = tf([G 0 0], {[1] [A] [B] [C] [0 D]})
##### 0 Kommentare-1 ältere Kommentare anzeigen-1 ältere Kommentare ausblenden

Melden Sie sich an, um zu kommentieren.

### Akzeptierte Antwort

Sulaymon Eshkabilov am 20 Feb. 2023
Here it is:
C1 = 0.000000000150;
C2 = 0.000000000470;
R1 = 10000;
R2 = 180000;
R3 = 2700;
R4 = 56000;
G = (R3+R4)/R3;
A = 1/(C1*R2);
B = 1/(C2*R2);
C = (1/(C1*R1))*(1-G);
D = 1/(C1*C2*R1*R2);
%{
Numerator = {[G 0 0] };
Denominator = {[1 0] [A] [B] [C] [0 D]};
T = tf(Numerator, Denominator)
%}
T = tf([G 0 0], [1 (A+B+C) -D])
T = 21.74 s^2 -------------------------- s^2 - 1.378e07 s - 7.88e09 Continuous-time transfer function.
##### 0 Kommentare-1 ältere Kommentare anzeigen-1 ältere Kommentare ausblenden

Melden Sie sich an, um zu kommentieren.

### Weitere Antworten (1)

Walter Roberson am 20 Feb. 2023
syms G C_1 R_2 C_2 R_1 s R_3 R_4
G = (R_3 + R_4)/R_3
G =
vratio = G*s^2/ ( s^2 + s * (1/(C_1*R_2) + 1/(C_2*R_2) + 1/(C_1*R_1)*(1-G)) + 1/(C_1*C_2*R_1*R_2) )
vratio =
vex = expand(vratio);
[N, D] = numden(vex)
N =
D =
Nc = collect(N, s);
Dc = collect(D, s);
vpretty = Nc/Dc
vpretty =
NCs = coeffs(Nc, s, 'all')
NCs =
DCs = coeffs(Dc, s, 'all')
DCs =
C1 = 0.000000000150;
C2 = 0.000000000470;
R1 = 10000;
R2 = 180000;
R3 = 2700;
R4 = 56000;
NC = double(subs(NCs, [C_1, C_2, R_1, R_2, R_3, R_4], [C1, C2, R1, R2, R3, R4]));
DC = double(subs(DCs, [C_1, C_2, R_1, R_2, R_3, R_4], [C1, C2, R1, R2, R3, R4]));
sys = tf(NC, DC)
sys = 21.74 s^2 -------------------------- s^2 - 1.378e07 s + 7.88e09 Continuous-time transfer function.
##### 2 Kommentare1 älteren Kommentar anzeigen1 älteren Kommentar ausblenden
Paul am 22 Feb. 2023
But the CST can handle this directly without too much complication, even if the desire is to have a general expression
s = tf('s');
G = @(R_3,R_4) ((R_3 + R_4)/R_3);
vratio = @(C_1,C_2,R_1,R_2,R_3,R_4) G(R_3,R_4)*s^2/ ( s^2 + s * (1/(C_1*R_2) + 1/(C_2*R_2) + 1/(C_1*R_1)*(1-G(R_3,R_4))) + 1/(C_1*C_2*R_1*R_2) );
C1 = 0.000000000150;
C2 = 0.000000000470;
R1 = 10000;
R2 = 180000;
R3 = 2700;
R4 = 56000;
vratio(C1,C2,R1,R2,R3,R4)
ans = 21.74 s^2 -------------------------- s^2 - 1.378e07 s + 7.88e09 Continuous-time transfer function.
Unrelated comment, but I have my suspicions about the expression for vratio in the question. I thought that circuits composed of just (positive) resistors and (positive) capacitors can't be unstable, whereas vratio clearly is.

Melden Sie sich an, um zu kommentieren.

### Kategorien

Find more on Stability Analysis in Help Center and File Exchange

R2022b

### Community Treasure Hunt

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

Start Hunting!

Translated by