Info
Diese Frage ist geschlossen. Öffnen Sie sie erneut, um sie zu bearbeiten oder zu beantworten.
Working on truss, but outputs are a bit off.
1 Ansicht (letzte 30 Tage)
Ältere Kommentare anzeigen
format shortG
d = sind(45);
A=[-d 0 0 0 0 0 0 0 0 0; %ab
-d -1 0 0 0 0 0 0 0 0; %ac
0 0 0 0 -d 0 0 -1 0 0; %bc
0 0 0 0 -d 0 1 0 1 0; %bd
d 0 1 -d d 0 0 0 0 0; %be
d 0 0 -d -d 0 0 0 0 0; %dx
0 0 -1 0 0 0 0 0 0 0; % ce
0 1 0 0 0 0 -1 0 0 0; % de
0 0 0 d 0 1 0 1 0 0; %Rey
0 0 0 d 0 0 0 0 0 1;]; % Rdy
b=[1000;0;0;0;0;0;1000;0;0;0];
X = linsolve(A,b)
Someone please help me to get Fab = 1414.21; Fac = -1000; Fbc = 1000; Fbe = -707.107; Fbd = 2121.32; Fce = -1000; Fde = 500; Rdx = -2000; Rdy = -1500; Rey = 1500
0 Kommentare
Antworten (1)
Steven Lord
am 6 Mai 2019
When I define a vector to contain your expected results and compute A*x-b, the residuals are quite large.
expected = [1414.21; -1000; 1000; 2121.32; -707.107; -2000; -1000; 500; 1500; -1500]
residuals = A*expected-b
residuals =
-2000
0.002519
0.00015472
1000
-0.0024308
-0.0021213
-2000
0
-0.00024293
-0.00024293
When I compute the residuals using the solution provided by linsolve they are quite small.
residualsLinsolve = A*X-b
residualsLinsolve =
0
0
0
0
3.0996e-14
8.2691e-14
1.1369e-13
0
0
0
If I use linsolve with -b instead of b, the solution matches your expected solution except for the next-to-last element, making me suspect 1) you made a typo in that next-to-last element and 2) you need to be careful about coordinate systems.
4 Kommentare
Diese Frage ist geschlossen.
Siehe auch
Produkte
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!