简体   繁体   English

在matlab中找到波特图中的传递函数

[英]Find transfer function from bode plot in matlab

I have obtained the bode plot for a system. 我已经获得了系统的波特图。 The system seems to have a very complex magnitude and phase plot. 该系统似乎具有非常复杂的幅度和相位图。 It's not possible to find the transfer function manually. 手动找不到传递函数是不可能的。 Is there a way of finding the transfer function from the magnitude and phase data, in Matlab? 有没有办法从大小和相位数据中找到传递函数,在Matlab中?

Here's my code: 这是我的代码:

%%FFT method for finding Transfer Function 
load testdata2.mat;
input = fft(signal(:,1));
% FFT of input data 
output = fft(signal(:,2));
% FFT of output data 
fft_ratio = output ./ input;

subplot(2,1,1) 

%Magnitude 
semilogx(20*log10(abs(fft_ratio))) 

subplot(2,1,2) 

%Phase 
semilogx((180/pi)*angle(fft_ratio)) 
mag = 20*log10(abs(fft_ratio)); 
phase = (180/pi)*angle(fft_ratio); 

Here's my data. 这是我的数据。

I don't believe so, and that's not Matlab's fault. 我不相信,这不是Matlab的错。 The problem is mathematically nontrivial because there can be poles and zeros of the transfer function that lie at large imaginary frequency. 这个问题在数学上是不平凡的,因为传递函数的极点和零点可能处于大的虚频率。 These might not significantly affect the Bode plot, but how would you rule out their existence? 这些可能不会显着影响波德情节,但你会如何排除它们的存在?

I think your best bet is to fit the Bode plot to a rational transfer function, and just keep increasing the number of poles and zeros in the transfer function until you get acceptable agreement. 我认为你最好的选择是将波德图调整到合理的传递函数,并且只是在传递函数中增加极点和零点数,直到你得到可接受的协议。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM