I have a problem and I am not able, so far, to find the solution.
I am trying to understand if there is a way, given a symmetric matrix $B$ (which is computed as $B=A^TA$ where I know the matrix $A$) to compute one of its basis in a closed form (analytical way).
I can easily solve my problem by the matlab command:
basis = orth(B)
Which gives me a basis of the matrix $B$.
The problem is that matlab, of course, uses a numerical way to find this basis while I was wondering if there is a closed form to express this basis.
thanks in advance for your help.
returns orthonormal basis for range of matrix. They doing it using Singular Value Decomposition. However what you are looking for is a Gram Schmidt process.
The orthonormal basis for range of matrix of a non singular matrix is all its columns. The Gram Schmidt process convert them into an orthogonal (or orthonormal if you do normalize them) basis. Furthermore, if the matrix is singular, you will get some of the vectors become zeros, i.e. you have to drop them.
ps: if you need it to be programmed - make sure you choose the numerically stable version of the algorithm. If you do a paper work both of them will give exactly the same result, but the regular one (the "non numerically stable") one is more convenient, i.e. easy to understand and less work.