diff options
author | Michael Abed <michaelabed@gmail.com> | 2012-04-01 15:58:32 -0400 |
---|---|---|
committer | Michael Abed <michaelabed@gmail.com> | 2012-04-01 15:58:32 -0400 |
commit | 4d6abebe7d7ee44053c3cbacf779d664a704f4c6 (patch) | |
tree | ab4b828270daa62691830e584460d3dd419c85a6 /truss_solve.m | |
parent | 22f06a7779d89461a090bf42ba2ff26e5fc4fca1 (diff) | |
download | ek301-prelim-4d6abebe7d7ee44053c3cbacf779d664a704f4c6.tar.gz ek301-prelim-4d6abebe7d7ee44053c3cbacf779d664a704f4c6.tar.bz2 ek301-prelim-4d6abebe7d7ee44053c3cbacf779d664a704f4c6.zip |
working
Diffstat (limited to 'truss_solve.m')
-rwxr-xr-x | truss_solve.m | 26 |
1 files changed, 26 insertions, 0 deletions
diff --git a/truss_solve.m b/truss_solve.m new file mode 100755 index 0000000..50150bb --- /dev/null +++ b/truss_solve.m @@ -0,0 +1,26 @@ +% Truss Compute + +C = [ + 1 1 0 0 0 0 0 0 0 0 0 0 0 + 1 0 1 1 0 0 0 0 0 0 0 0 0 + 0 0 0 1 1 1 0 0 0 0 0 0 0 + 0 1 1 0 1 0 1 1 0 0 0 0 0 + 0 0 0 0 0 1 1 0 1 1 0 0 0 + 0 0 0 0 0 0 0 1 1 0 1 1 0 + 0 0 0 0 0 0 0 0 0 1 1 0 1 + 0 0 0 0 0 0 0 0 0 0 0 1 1 +]; + +Sy = zeros(8,3); Sy(1,2)=1; Sy(8,3)=1; +Sx = zeros(8,3); Sx(1,1)=1; + +X = [0 0 4 4 8 8 12 12]; +Y = [0 4 8 4 8 4 4 0]; + +L = zeros(16,1); L(8+4)=-25; + +A = computeA(C,X,Y,Sx,Sy); + +result = A\(-L) + + |