create sparse matrix from diagonal arrays
이전 댓글 표시
I have the 7 diagonal that come from a 3D finite volume discretization in separate arrays. These 7 arrays have 3D shape and correspond to each elements of the stencil for all points: top, bottom, east, west, north south and central point. I would like to create a sparse matrix object from these arrays, but I feel a little lost with the spdiag documentation. Help would be gratly apreaciated.
채택된 답변
추가 답변 (2개)
Andrew Newell
2014년 4월 10일
0 개 추천
MATLAB supports sparse matrices, but for 3D arrays you'll need to visit the File Exchange and get N-dimensional sparse arrays by Matt J.
댓글 수: 2
Jack Silver
2014년 4월 11일
Andrew Newell
2014년 4월 11일
I'm still having trouble understanding what you mean. Could you attach a file with some data?
카테고리
도움말 센터 및 File Exchange에서 Resizing and Reshaping Matrices에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!