How to differentiate a noise signal.
조회 수: 2 (최근 30일)
이전 댓글 표시
I am doing a project of analyzing influence of tire damping using a full car state-space model with random road input. To analyze the acceleration of body, I want the data regarding acceleration of random input. Random road profile is generated as follows for my project:
Here, Zr is road excitation displacement with respect to time.
But derivative block is not giving the expected answer. Please help me to solve the problem.
댓글 수: 8
채택된 답변
Mathieu NOE
2022년 1월 6일
hello again
I think your model was correct only the solver parameters could be more adapted - now I forced the solver to use fixed steps (and equal to Ts = 1/Fs); your original settings was "variable step size" which for me seemed incorrect to me
also you can avoid filling your workspace with all the default data that simulink generates (section "Save to Workspace" below) so I unticked all of them (you have a dedicted block for the output in your model so that suffices)
at the end the curve looks better as you had expected
this is you script with minor modification (Ts and stepsize are defined from Fs and not independently)
m1= 40; % unsprung mass
c1= 600; % unsprung damping coefficient
k1= 200000; % Tire stiffness
m2=332; % sprung mass
C2=100:50:3500; % suspension damping
k2= 25000; % suspension stiffness
%velocity of vehicle in m/s
V=20;
T_s= 10;
% Sampling frequency
Fs= 1000;
stepsize= 1/Fs; % could be replaced by Ts below...
Ts= 1/Fs; % sampling period Ts=1/Fs
seed= 23341;
Gq= 256*10^-6; % road roughness in m^3
M= [m1 0; 0 m2]; % mass matrix
K= [k1+k2 -k2; -k2 k2]; %stiffness matrix
n=size(C2,2);
Acc_rms= zeros(n,1); % rms of acceleration vetor
for ci=1:n
c2= C2(ci);
C= [c1+c2 -c2; -c2 c2];
A= [ zeros(2) eye(2);
-M\K -M\C];
B= [ zeros(2);
1/m1 0;
0 0];
C= eye(4);
D= zeros(4,2);
sim('QuarterCarStateSpacePreviousVersion.slx');
x1= Output.data;
Acceleration= x1(:,4);
Acc_rms(ci)= rms(Acceleration);
end
plot(C2, Acc_rms ,'r', 'LineWidth', 2);
xlabel('Damping Coefficients, Ns/m');
ylabel('Acceleration, m/s^2');
grid on
attached is your model with the new solver parameters
all the best
추가 답변 (0개)
참고 항목
카테고리
Help Center 및 File Exchange에서 Sources에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!