David's Octave Assignment: Difference between revisions
Jump to navigation
Jump to search
David.bryson (talk | contribs) No edit summary |
David.bryson (talk | contribs) No edit summary |
||
(One intermediate revision by the same user not shown) | |||
Line 4: | Line 4: | ||
it looks like this. |
it looks like this. |
||
diag([1 2 3]) |
diag([1 2 3]) |
||
ans = |
ans = |
||
1 0 0 |
|||
0 2 0 |
|||
0 0 3 |
Latest revision as of 09:10, 4 October 2010
You can abort any command in octave by pressing Ctrl C.
and you can create a diagonal matrix by entering diag([1 2 3]) it looks like this.
diag([1 2 3])
ans =
1 0 0 0 2 0 0 0 3