Post Reply 
Non-graphing calculator supporting complex matrices?
03-02-2015, 12:25 AM
Post: #29
RE: Non-graphing calculator supporting complex matrices?
(03-01-2015 04:24 AM)supernumero Wrote:  Still, in the context of my original question, a wish for the ability to find complex eigenvalues and eigenvectors is not fulfilled.

Here's the adaption of the program from above that works with complex matrices:
Code:
001 - 42,21,15  LBL E
002 - 42,26,13  RESULT C
003 -    45 25  RCL I
004 -        1  1
005 - 42,23,13  DIM C
006 - 45,16,13  RCL MATRIX C
007 -        0  0
008 -       20  x
009 -        1  1
010 -       40  +
011 - 42,26,15  RESULT E
012 - 45,16,14  RCL MATRIX D
013 -       20  x
014 - 42,16, 4  MATRIX 4
015 -    45 25  RCL I
016 -        2  2
017 -       20  x
018 -    43 36  LSTx
019 -       40  +
020 -    45 25  RCL I
021 - 42,23,15  DIM E
022 - 45,16,15  RCL MATRIX E
023 - 42,16, 4  MATRIX 4
024 -       33  Rv
025 -       34  x<>y
026 -        2  2
027 -       30  -
028 - 42,23,15  DIM E
029 - 45,16,15  RCL MATRIX E
030 -    42 40  Py,x
031 - 42,16, 2  MATRIX 2
032 - 42,26,15  RESULT E
033 - 45,16,12  RCL MATRIX B
034 - 45,16,11  RCL MATRIX A
035 - 45,16,15  RCL MATRIX E
036 -       30  -
037 - 42,26,14  RESULT D
038 -       10  /
039 - 42,26,12  RESULT B
040 -       36  ENTER
041 - 42,16, 8  MATRIX 8
042 -        2  2
043 -       11  SQRT
044 -       10  /
045 -       10  /
046 - 42,26,15  RESULT E
047 - 45,16,11  RCL MATRIX A
048 - 45,16,12  RCL MATRIX B
049 -       20  x
050 - 42,26,14  RESULT D
051 - 42,16, 5  MATRIX 5
052 - 42,16, 3  MATRIX 3
053 -    43 40  Cy,x
054 -    43 32  RTN

The guess for the eigenvalue has to be stored in matrix d 1 2. The guess for the eigenvector is expected in the matrix b which must be in \(\tilde{Z}\) format. The same applies to matrix A. And the dimension (i.e. 2) has to be stored in register I.

The challenge was to figure out a means to calculate \(\lambda I\). For the transformation a mix of multiplication, transpositions and change of dimensions was used. As an example the case of 2 dimensions:
\[
\begin{bmatrix}
1 \\
1 \\
\end{bmatrix}

\begin{bmatrix}
a & b
\end{bmatrix}

= \begin{bmatrix}
a & b \\
a & b \\
\end{bmatrix}

\rightarrow \begin{bmatrix}
a & a \\
b & b \\
\end{bmatrix}

\rightarrow \begin{bmatrix}
a & a \\
b & b \\
0 & 0 \\
0 & 0 \\
0 & 0 \\
0 & 0 \\
\end{bmatrix}

\rightarrow \begin{bmatrix}
a & b & 0 & 0 & 0 & 0 \\
a & b & 0 & 0 & 0 & 0
\end{bmatrix}

\rightarrow \begin{bmatrix}
a & b & 0 & 0 \\
0 & 0 & a & b
\end{bmatrix}
\]

The other thing to consider is that the elements appear twice in the matrix. This has to be corrected when calculating the norm by dividing by \(\sqrt{2}\). Aside from this both programs are very similar.

This example was used as a test-case. After 5 iterations the result is exact to 4 places.

As a guess for the eigenvector I've used \(\begin{bmatrix}
1 + 0i \\
1 + 0i \\
\end{bmatrix}\) and \(1 + i\) as guess for the eigenvalue.

I haven't tried but I doubt that there's enough memory to handle the 3-dimensional case. The calculation should still be okay if somebody wants to test that with a DM-15 with extended memory.

Cheers
Thomas
Find all posts by this user
Quote this message in a reply
Post Reply 


Messages In This Thread
RE: Non-graphing calculator supporting complex matrices? - Thomas Klemm - 03-02-2015 12:25 AM



User(s) browsing this thread: 2 Guest(s)