- 1.
-->A=v'*v
A =
! 1. 2. 3. 4. 5. !
! 2. 4. 6. 8. 10. !
! 3. 6. 9. 12. 15. !
! 4. 8. 12. 16. 20. !
! 5. 10. 15. 20. 25. !
-->trace(A)
ans =
55.
-->rank(A)
ans =
1.
-->inv(A)
!--error 19 // il ne peut calculer l'inverse
de a car son déterminant est
nul.
singular matrix
-->det(A)
ans =
0.
-->spec(A)
ans =
! 0. !
! 0. !
! 0. ! //Valeurs propres
! 0. !
! 55. !
-->bdiag(A)
ans =
! 55. 0. 0. 0. 0. !
! 0. 0. 0. 0. 0. !
! 0. 0. 0. 0. 0. ! // Vecteurs propres
mis en colonne
! 0. 0. 0. 0. 0. !
! 0. 0. 0. 0. 0. !
- 2.
-->x=poly(0,'x') // définition de la variable x
x =
x
-->B=x*eye(A)-A // polynome caractéristique
B =
! - 1 + x - 2 - 3 - 4 - 5 !
! !
! - 2 - 4 + x - 6 - 8 - 10 !
! !
! - 3 - 6 - 9 + x - 12 - 15 !
! !
! - 4 - 8 - 12 - 16 + x - 20 !
! !
! - 5 - 10 - 15 - 20 - 25 + x !
-->C=det(B)
C =
4 5
- 55x + x
- 3.
-->roots(C) // Valeurs propres de A
ans =
! 0 !
! 0 !
! 0 !
! 0 !
! 55. !
- 4.
-->deff('[f]=f(x)','f=sin(x)+x')
-->integrate('f(x)','x',0,1)
ans =
0.9596977