How can you set the initital condition 'displacement' of the mass in a simple spring-damper-mass system in Simscape?
조회 수: 11 (최근 30일)
이전 댓글 표시
In Simscape I want a Mass in a simple mass spring damper system to have initial displacement and velocity. When I doubleclick on the mass symbol, I can only set the initital velocity. I already tried to solve this problem by applying initial deformation on the spring, but this ended up as a constant offset. Is there a certain block I have to use?
댓글 수: 0
답변 (2개)
Zhao Wang
2016년 9월 29일
I understand that you want to set the initial displacement of the "Mass" block in a Mass-Spring-Damper model in Simscape. I assume that you want to change this initial value without double-clicking blocks in the model.
The initial displacement of the "Mass" block is determined by the initial deformation value in the "Spring" Block. For more details of how to initialize variables of a Mass-Spring-Damper system, refer to the following link:
If you want to change this initial value, you can use a variable (for example 'x') in the field of 'Beginning Value' of the 'Deformation' variable. You can define this variable in the base workspace. Every time you change the value of 'x' and click the 'Run' button, the changed initial displacement will be applied to the simulation of the Mass-Spring-Damper system.
Tomorrow
2018년 11월 26일
편집: Tomorrow
2018년 12월 11일
I have read the link you give and followed the same process.
However, I have set the initial position for spring and sensor, and they are the same as -3mm, after the updating the variable, the data are all strange.
attached please find my model. thanks for your help.
can anyone help?
댓글 수: 0
참고 항목
카테고리
Help Center 및 File Exchange에서 Couplings and Drives에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!