Post Reply 
RREF with complex numbers not working properly
11-15-2022, 03:20 PM (This post was last modified: 11-15-2022 03:21 PM by AnalogJoe.)
Post: #1
RREF with complex numbers not working properly
I have a singular matrix with complex numbers:

first row: [-0.3-0.6i, -0.6]
second row: [0.75, 0.3-0.6i]

if I use RREF with my Prime I get the identity matrix, which is not correct, making the same input in Matlab gives me the correct result which is [1, 0.4-0.8j; 0, 0].

Any ideas?
Find all posts by this user
Quote this message in a reply
11-15-2022, 11:27 PM
Post: #2
RE: RREF with complex numbers not working properly
Try:

rref([[−0.3-0.6*i,−0.6],[0.75,0.3-0.6*i]],1)

-road
Find all posts by this user
Quote this message in a reply
11-16-2022, 05:03 AM
Post: #3
RE: RREF with complex numbers not working properly
(11-15-2022 11:27 PM)roadrunner Wrote:  Try:

rref([[−0.3-0.6*i,−0.6],[0.75,0.3-0.6*i]],1)

-road

It worked! may I ask what is the ,1 for?
Find all posts by this user
Quote this message in a reply
11-16-2022, 12:48 PM
Post: #4
RE: RREF with complex numbers not working properly
It's the number of columns that the reduction is done on. I attached the relevent info from the xcas manual.

-road

   
Find all posts by this user
Quote this message in a reply
11-16-2022, 12:52 PM
Post: #5
RE: RREF with complex numbers not working properly
Hmmm, it appears tha in exact mode you don't need the 1:

rref([[(-3-6*i)/10,-6/10],[75/100,(3-6*i)/10]])

also works.

-road
Find all posts by this user
Quote this message in a reply
11-17-2022, 11:11 PM
Post: #6
RE: RREF with complex numbers not working properly
Thank you! I will take a look.
Find all posts by this user
Quote this message in a reply
Post Reply 




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