MATLAB Answers

Why doesn't my Simscape displacement doesn't match input

조회 수: 6(최근 30일)
James Browne
James Browne 1 Sep 2019
답변: James Browne 6 Sep 2019
Hi,
I am trying to use simscape to make a spring damper model with a input displacement, representing a road input (ie. a bump).
My input is a step input of 1m (as shown below). I have differentiated this to get a vertical upward velocity (simscape doesn't seem to allow a displacement input?).
The resulting dispacement on the other side of my 'ideal translational velocity input' doesn't is only just under 60mm (see scope below), not the 1m that I expected.
Is someone able to give me some help to explain what is occuring?
Model.JPG step input.JPG
road displacement.JPG

  댓글 수: 0

댓글을 달려면 로그인하십시오.

답변(2개)

Todd
Todd 3 Sep 2019
One factor is that a step has an infinite derivative, so would be highly sensitive to numerical error. You could try replacing the step with a ramp over a short time, which would result in a finite velocity.
Simscape considers position a local state--it doesn't have the concept of a 'position' in the sense of the 'position' of the south end of your spring, and this can make modeling some mechanisms trickier. So, another possibility is to look at the source code for the spring and write your own spring that takes end positions as inputs.

  댓글 수: 0

댓글을 달려면 로그인하십시오.


James Browne
James Browne 6 Sep 2019
Thanks,
It makes sense that the step input could cause problems due to the infinite derivative.
It would make sense for simscape to have position based spring inputs though, after all, that is the dependant variables for a spring.
When I have previously made a quarter car model, I used a gain block to multiply a displacement to result in a spring force. I am new to simscape (rather than just simulink), if anyone has an example/code of how they do springs in simscape that would be of interest.

  댓글 수: 0

댓글을 달려면 로그인하십시오.

태그

제품

Community Treasure Hunt

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

Start Hunting!

Translated by