Let be [D] a (nxn) ill-conditioned matrix and [G] its inverse. If the inverse exists then it can be efficiently implemented by the linear solving of [D]{gj}={bj} with the LU method using partial pivoting where {gj}: is a column vector of [G] and {bj}: is a column of the identity matrix [I] for j=1 to n and (bj(i)=0 for i=1 to n such that bj(j)=1). The resulting matrix can be checked with the satisfying condition [D][G]=[I].