sunjin09 said:
maximize \frac{<x,y>}{||x||_2||y||_2},
I don't know an easy way to do this. You may as well consider only unit vectors, so the problem becomes to maximize <\hat{x},\hat{y}>. As far as I can see this problem falls under the heading of a "bilinear optimization problem" or, more generally, a "multilinear optimization problem".
My intuition is that if you have two vector subspaces that only intersect at the zero vector, then you should be able to find a set of vectors {e_1,e_2,..,e_n, f_1,f_2,...,f_m} such that this set is a (non-orthogonal) basis for the parent n+m dimensional space, the e_i are an orthonormal basis for the first subspace and the f_i are an orthonormal basis for the second subspace.
If that inutition is correct then let \hat{x} = \sum_1^n \alpha_i e_i and \hat{y} = \sum_1^m \beta_j f_j. Let c_{i,j} = <e_i, f_j>.
The problem is to maximize the function \sum_{i=1}^n \sum_{j=1}^m c_{i,j} \alpha_i \beta_j subject to the constraints \sum_1^n \alpha_i^2 = 1 and \sum_1^n \beta_j^2 = 1.
I wonder if there is a simpler formulation.