Differences
This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revisionNext revision | Previous revision | ||
documentation:language_reference:objects:matrix:functions:rotate [2024/12/12 17:59] – Maurits W. Haverkort | documentation:language_reference:objects:matrix:functions:rotate [2024/12/12 18:03] (current) – Maurits W. Haverkort | ||
---|---|---|---|
Line 8: | Line 8: | ||
===== Example ===== | ===== Example ===== | ||
- | ### | ||
- | description text | ||
- | ### | ||
==== Input ==== | ==== Input ==== | ||
<code Quanty Example.Quanty> | <code Quanty Example.Quanty> | ||
- | -- some example code | + | M = Matrix.New({{ 1, I, 2, I}, |
+ | {-I, 1, I, 2}, | ||
+ | { 2,-I, 4, I}, | ||
+ | {-I, 2,-I, 4}}) | ||
+ | val, fun = Matrix.Eigensystem(M) | ||
+ | |||
+ | Mdiag = Chop(Rotate(M, | ||
+ | print(Mdiag) | ||
</ | </ | ||
==== Result ==== | ==== Result ==== | ||
<file Quanty_Output> | <file Quanty_Output> | ||
- | text produced as output | + | { { -1.1401 , 0 , 0 , 0 } , |
+ | { 0 , 0.6972 , 0 , 0 } , | ||
+ | { 0 , 0 , 4.3028 , 0 } , | ||
+ | { 0 , 0 , 0 , 6.1401 } } | ||
</ | </ | ||