Computation of minimal-order realizations of generalized state-space systems