How can I solve dimension problem? Simulink
이전 댓글 표시
Hello everyone,
I am getting this error
" Error in port widths or dimensions. 'Output Port 1' of 'untitled/From29' is a one dimensional vector with 1369 elements."
saveV.mat size 1370x2 [time,Velocity]
saveACC.mat size 1370x2 [time,Acceleration]
both like,
0 3
1 5.9
2 4
. .
. .
. .
Also I do not know why size decreased from 1370 to 1369.



Thank you...
댓글 수: 2
Walter Roberson
2022년 5월 26일
Sample Time is not number of samples! It is related to the rate at which the block is considered to output samples.
Hasan Atacan Tosun
2022년 5월 26일
채택된 답변
추가 답변 (1개)
Walter Roberson
2022년 5월 27일
0 개 추천
You need to transpose the data in the file. The first row is the time stamps and rows after that are samples for that time. You have two times and 1369 values.
This is unlike From Spreadsheet, which treats the first column as time if I recall correctly.
카테고리
도움말 센터 및 File Exchange에서 Sources에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!