"Frank " <allinone_2003@yahoo.com.hk> wrote in message <icg3d0$41j$1@fred.mathworks.com>...
> Hi all,
>
> I have a question about the common subspaces of two complex matrices and hope that you can help.
>
> I have two complex matrices, A and B both with size K by (K1).
> How can I obtain the intersection subspace of them?
> In other words, I want to obtain a complex matrix R with size K by C satisfying the following:
> For all x, there is a y, such that Rx=Ay and similarly, for all z, there is a w such that Rz = Bw.
> Furthermore, if both A and B have full rank, can we say that C is at least (K2) or somethings like that?
Take QA/QB respectively orthonormal basis of A and B (using orth()), then use
null on
Q = [QA QB]
The nullspace of N=null([QA QB]) has k columns, it's the dimension of span<A> intersect span B
has two parts
NA=N(size(QA,2),:)
NB=N(size(QA,2)+1:end,:)
and
QA*NA+QB*NB = 0
i.e. span<QA*NA> is the span <QB*B>
QA*NA = A*(A\QA)*NA
QB*NB = B*(A\QB)*NB
If {y} = (A\QA)*NA and {w} = (A\QB)*NB is what you are looking for.
Bruno
