H1 H2 Hv estimators all the same
Ältere Kommentare anzeigen
Hi, I'm trying to analyse a response to impact of a fixed structure. I have a force signal recorded by a load cell on the hammer and an acceleration measured by the accelerometer on my structure.
I would like to compute the FRF using all the estimators H1 H2 Hv and compare them, but i get the exact same result in all cases, this seem impossible since it means that no noise has been recorded. Also i find quite strange that the coherence is always 1.
This is what I have written so far, unfortunately I can't see my mistakes. If anybody has any idea on why this is happenig it would be of great help.
Thanks in advance
clc
clear
close all
load data.mat
force = force - mean(force);
acc = (acc - mean (acc))*9.81;
% sampling frequency
fs = 6600;
N = 30000;
freq = (0:N/2)'*fs/N;
% time domain
figure;
subplot(2,1,1)
plot(t,force)
title('Force - time domain')
ylabel('F [N]')
xlabel('Time [s]')
grid minor
subplot(2,1,2)
plot(t,acc)
title('Acceleration - time domain')
ylabel('Acc. [ms^{-2}]')
xlabel('Time [s]')
grid minor
ACC = fft(acc);
FORCE = fft(force);
phase = angle(ACC./FORCE);
ACC = ACC/length(ACC);
FORCE = FORCE/length(FORCE);
Sxx = conj(FORCE).*FORCE;
Syy = conj(ACC).*ACC;
Sxy = conj(FORCE).*ACC;
Syx = conj(ACC).*FORCE;
% only the positivie part
Gxx=2*Sxx(1:length(ACC)/2+1);
Gyy=2*Syy(1:length(ACC)/2+1);
Gxy=2*Sxy(1:length(ACC)/2+1);
Gyx=2*Syx(1:length(ACC)/2+1);
ACC=2*ACC(1:length(ACC)/2+1);
FORCE=2*FORCE(1:length(FORCE)/2+1);
% estimators FRF
H1 = Gxy./Gxx;
H2 = Gyy./Gyx;
Hv =(Gyy-Gxx + sqrt((Gxx-Gyy).^2 + 4*abs(Gxy).^2))./(2*Gyx); % SHIN-HAMMOND
Coe =(abs(Gxy).^2)./(Gxx.*Gyy);
H = ACC./FORCE;
figure;
subplot(2,1,1);
plot(freq,20*log10(abs(Hv)),'linewidth',1);
xlabel('Frequency [Hz]')
ylabel('|H| (dB)')
grid on;
subplot(2,1,2);
plot(freq,phase(1:N/2+1)./pi)
% semilogy(freq,Coe,'linewidth',1); grid on;
xlabel('Frequency [Hz]')
ylabel('Phase');
grid on;
figure;
plot(freq,20*log10(abs(H1)))
hold on
plot(freq,20*log10(abs(H2)))
plot(freq,20*log10(abs(Hv)))
plot(freq,20*log10(abs(H)))
hold off
grid minor
xlabel('Frequency [Hz]')
ylabel('Amplitude [dB]')
legend('H1','H2','Hv','H')
Akzeptierte Antwort
Weitere Antworten (1)
Hi Riccardo,
I'm only marginally familiar with the H1/H2 methods of estimation. Keeping that in mind ...
load data.mat
force = force - mean(force);
acc = (acc - mean (acc))*9.81;
% sampling frequency
fs = 6600;
N = 30000;
freq = (0:N/2)'*fs/N;
ACC = fft(acc);
FORCE = fft(force);
phase = angle(ACC./FORCE);
ACC = ACC/length(ACC);
FORCE = FORCE/length(FORCE);
Sxx = conj(FORCE).*FORCE;
Syy = conj(ACC).*ACC;
Sxy = conj(FORCE).*ACC;
Syx = conj(ACC).*FORCE;
% only the positivie part
Gxx=2*Sxx(1:length(ACC)/2+1);
Gyy=2*Syy(1:length(ACC)/2+1);
Gxy=2*Sxy(1:length(ACC)/2+1);
Gyx=2*Syx(1:length(ACC)/2+1);
ACC=2*ACC(1:length(ACC)/2+1);
FORCE=2*FORCE(1:length(FORCE)/2+1);
Shouldn't the way that H1 and H2 are computed (I didn't go through the Hv calculation) result in both of them being the same as H?
% estimators FRF
H1 = Gxy./Gxx; % = Sxy/Sxx = conj(FORCE).*ACC./(conj(FORCE).*FORCE) = ACC./FORCE
H2 = Gyy./Gyx; % = Syy/Syx = conj(ACC).*ACC./(conj(ACC).*FORCE) = ACC./FORCE
Hv =(Gyy-Gxx + sqrt((Gxx-Gyy).^2 + 4*abs(Gxy).^2))./(2*Gyx); % SHIN-HAMMOND
Coe =(abs(Gxy).^2)./(Gxx.*Gyy);
H = ACC./FORCE;
[txy1,f] = tfestimate(force,acc,ones(N,1),N-1,[],fs,'Estimator','H1');
[txy2,f] = tfestimate(force,acc,ones(N,1),N-1,[],fs,'Estimator','H2');
then txy1 and txy2 are essentially the same
figure
plot(f,abs(txy1-txy2))
If we use the default window and overlap we do see a bit of difference between 1500-2000 Hz
[txy1,f] = tfestimate(force,acc,[],[],[],fs,'Estimator','H1');
[txy2,f] = tfestimate(force,acc,[],[],[],fs,'Estimator','H2');
figure
plot(f,abs(txy1-txy2))
figure
plot(f,db(abs(txy1)),f,db(abs(txy2))),grid
@William Rose has some Answers on this topic, I believe. Maybe they will help if you can find them.
Kategorien
Mehr zu Time Series Events finden Sie in Hilfe-Center und File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!




