Used dgemm to replace(A.T,A) matrix... Also compute matrix inverse because it's used a bunch in the solving algorithm... about 20% faster for medium size problems