Hi!

I have the following problem: I have done some computations in order to obtain three 4x4-matrices represented as a 12x4-array, aka a span V of 4 linear independet vectors comming from C^12; these 4 vectors build a basis of my linear space V. From theory I know there should be a very particular basis of this vector space V, such that if I split this 12x4 matrix back into the three 4x4-matrices, these should be Hermitian. What I’m trying to do is the following: I want to force the small matrices to be Hermitian and then by assembling then back together to 12x4 array, check if they still build V and then if yes I’m hopefully done. So I’m wondering if I can “force” somehow my small 4x4 matrices to be Hermitian. What I mean by that: my original 4x4 matrix A is similar to some Hermitian matrix 4x4 B: A = P^{-1}*B*P with P is a matrix of basis change; is there a way to compute B in Julia, if I know that it exists?

TL;DR: is there a way to compute a Hermitian representation of A if I have A~B, where A is my original nxn matrix, B is a nxn Hermitian matrix and ~ is similarity relation?