function wrapper_calcK
input Real A[:, size(A, 1)] "Real square system matrix";
input Real U0[size(A, 1), :] "U0 and Z are the decompositions of B";
input Real Z[size(U0, 2), size(U0, 2)] "Z and U0 are the decompositions of B";
input Real gamma_real[size(A, 1)] "Eigenvalue vector, real part";
input Real gamma_imag[size(A, 1)] "Eigenvalue vector, imaginary part";
input Real X_real[n, n] "Eigenvectors, real part";
input Real X_imag[n, n] "Eigenvectors, imaginary part";
input Integer nre "Number of real eigenvalues";
output Real K[size(U0, 2), size(A, 1)] "Feedback matrix";
end wrapper_calcK;