How to arrange local stiffness matrix to global stiffness matrix
31 次查看(过去 30 天)
显示 更早的评论
I have 3 local stiffness matrix 4 by 4;
local stiffness matrix-1 (4x4) = row and column address for global stiffness are 1 2 3 4 and 1 2 3 4 resp.;
local stiffness matrix-2 (4x4) = row and column address for global stiffness are 1 2 5 6 and 1 2 5 6 resp.;
local stiffness matrix-3 (4x4) = row and column address for global stiffness are 1 2 7 8 and 1 2 7 8 resp.;
I want these local stiffness matrices to be arranged in global stiffness matrix of (8x8) size according to above local stiffness address with overlapping cells added.
IMAGE HAS BEEN ATTACHED TO UNDERSTAND IT CLEARLY
0 个评论
回答(1 个)
Giovanni Mottola
2016-10-5
I strongly suspect there is something wrong with your scheme in the image attached. The stiffness matrix #2 (marked in red), for instance, has 4x4=16 elements, but you've marked only 8 of them in the global matrix. If I understand correctly the problem you are facing (2D beam stiffness matrices?) then perhaps this should help:
mat_stiff_global=zeros(8, 8);
mat_stiff_global(1:4, 1:4)=mat_stiff_global(1:4, 1:4)+mat_stiff_local1;
mat_stiff_global([1:2, 5:6], [1:2, 5:6])=mat_stiff_global([1:2, 5:6], [1:2, 5:6])+mat_stiff_local2;
mat_stiff_global([1:2, 7:8], [1:2, 7:8])=mat_stiff_global([1:2, 7:8], [1:2, 7:8])+mat_stiff_local3;
1 个评论
Jose Carmona
2018-2-13
Thank you so much for answering this guys question. I am currently in advanced machine analysis and I didn't want to have to type out each matrix, or variables to actually form the matrix.
另请参阅
类别
在 Help Center 和 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!