Why does my matrix not change with each iteration?
Afficher commentaires plus anciens
In my code:
B = Bmat_4n(x,y,xi,eta);
for point = 1:length(xiList)
xi = xiList(point);
eta = etaList(point);
strain = B*U;
strainList(:, point) = strain;
disp(B);
end
I run 4 iterations (length of xilist) and I get 4 different xi and eta values as intended. B here refers to a seperate function file which when tested by itself naturally gives different results for B for different xi and eta values but when I run the loop here I get 4 times the same B matrix? what am I missing?
The B is meant to draw the matrix B at the end of the function file
Réponse acceptée
Plus de réponses (0)
Catégories
En savoir plus sur Programming dans Centre d'aide et File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!