How do you align column in a matrix?
조회 수: 18 (최근 30일)
이전 댓글 표시
I'm trying to create this matrix:
However, I'm gettng this:
This is my code:
I'm sure it has something to do with the format operators but I'm not sure what it is.
Thank you for your help in advance
댓글 수: 4
Stephen23
2021년 6월 18일
"This is my code:"
No, that is an image of some code: we cannot run code in an image, nor can we use that matrix.
Please provide code as text.
채택된 답변
Stephen23
2021년 6월 18일
Node = [1,0,0,0;2,100,0,0;3,200,0,0;4,33.3333321,0,0;5,66.6666641,0,0;6,133.333328,0,0;7,166.666672,0,0]
fmt = '%3d,%13.9g,%13d,%13d\n';
fprintf(fmt,Node.')
추가 답변 (0개)
참고 항목
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!