how to save the values of DelL(T)
2 Ansichten (letzte 30 Tage)
Ältere Kommentare anzeigen
Lo = 44.46
Do = 18.76
alpha = 0.0002178
for T = 36:1:180
DeltaL = Lo*alpha*(T-35)
DelL(T) = DeltaL
end
I need the T value going from 36 through 180 and store the values in array
0 Kommentare
Antworten (2)
Chunru
am 25 Okt. 2022
Lo = 44.46;
Do = 18.76;
alpha = 0.0002178 ;
T = 36:1:180;
DelL = Lo*alpha*(T-35);
whos
0 Kommentare
VBBV
am 25 Okt. 2022
Lo = 44.46
Do = 18.76
alpha = 0.0002178
for T = 36:1:180
DeltaL = Lo*alpha*(T-35);
DelL(T) = DeltaL;
end
DelL(DelL == 0) = [] % use this to delete zeros in DelL matrix
2 Kommentare
VBBV
am 25 Okt. 2022
Matlab creates vector of zeros preceding the array formed using for loop. In your case, it is DelL array
Siehe auch
Kategorien
Mehr zu Logical finden Sie in Help Center und File Exchange
Produkte
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!