I want to find the determinant for 5.5 matrix

I need to find the determinant in symbol s1 to s10 (without values). Here the matrix M:
M=[0 -s1 -s2 -s3 -s4; s1 0 -s5 -s6 -s4; s2 s5 0 -s8 -s9; s3 s6 s8 0 -s10; s4 s7 s9 s10 0];
Many thanks.

 Accepted Answer

>> syms s1 s2 s3 s4 s5 s6 s7 s8 s9 s10
>> M = [0 -s1 -s2 -s3 -s4; s1 0 -s5 -s6 -s4; s2 s5 0 -s8 -s9; s3 s6 s8 0 -s10; s4 s7 s9 s10 0];
>> det(M)
ans =
s1*s4^2*s8^2 - s1*s4*s7*s8^2 - s2*s4^2*s6*s8 + s3*s4^2*s5*s8 - s3^2*s4*s5*s9 - s2^2*s4*s6*s10 + s3^2*s5*s7*s9 + s2^2*s6*s7*s10 + s2*s3*s4*s5*s10 + s2*s3*s4*s6*s9 + s1*s2*s4*s8*s10 - s1*s3*s4*s8*s9 - s2*s3*s5*s7*s10 - s2*s3*s6*s7*s9 + s2*s4*s6*s7*s8 - s3*s4*s5*s7*s8 - s1*s2*s7*s8*s10 + s1*s3*s7*s8*s9
>> simplify(ans)
ans =
(s4 - s7)*(s3*s5 - s2*s6 + s1*s8)*(s2*s10 - s3*s9 + s4*s8)

More Answers (1)

KSSV
KSSV on 15 Dec 2016
Edited: KSSV on 15 Dec 2016
clc; clear all ;
syms s1 s2 s3 s4
A = [s1 s2 ; s3 s4] ;
det(A)
The above shows determinant for 2x2 matrix. you may extend it for your matrix.

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!