Simscape Integration leads to an error
2 visualizaciones (últimos 30 días)
Mostrar comentarios más antiguos
muhammed said parlak
el 12 de Sept. de 2021
Respondida: Dallas Perkins
el 13 de Oct. de 2023
Hello guys,
I have modelled a mechanical system on SimScape to run an analyze in time domain and obtain the frequency response of it. I'd like to represent ground acceleration and since there is only ideal source for velocity I integrate the acceleration series. But unfortunately it results in wrong velocity series which starts from "0". When I change the initial condition, velocity series result in correct form but this time displacements of the mass get wrong. How can solve this problem?
g=0.5:0.001:1.5;
mdmax=nan(size(g));ddmax=nan(size(g));
for i=1:size(g,2)
freq =g (i);
amp = 1/-freq; b%initial condition parameter for the velocity time series.
data = sim('tmdmodel.slx');
data1 = flip(data.massdisp.Data);
data2 = flip(data.dampdisp.Data);
data3 = flip(data.gdisp.Data);
mdmax(i)= max(abs(data1(2:round(end/2))));
ddmax(i)= max(abs(data2(2:round(end/2))));
end
0 comentarios
Respuestas (1)
Dallas Perkins
el 13 de Oct. de 2023
Hi Muhammed,
Correct, if you are integrating an acceleration input to get velocity you can set the "initial condition" parameter on the integrator block to control initial velocity.
Can you clarify how the resulting displacement is wrong? Generally this will be a function of the mass/spring/damper coefficients so you might need to vary those to get your expected displacement result.
0 comentarios
Ver también
Categorías
Más información sobre Troubleshooting en Help Center y File Exchange.
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!