Intel® oneAPI Math Kernel Library
Ask questions and share information with other developers who use Intel® Math Kernel Library.
Announcements
This community is designed for sharing of public information. Please do not share Intel or third-party confidential information here.
6590 Discussions

## error #6285: There is no matching specific subroutine for this generic subroutine call. [LIN_SOL_GEN]

Beginner
263 Views
Hello,
I have a problem concerning the use of the subroutine LIN_SOL_GEN to compute a matrix inversion.
The following error appears:error #6285: There is no matching specific subroutine for this generic subroutine call.
I show my code below.
PROGRAM INVM
!==============================================================================!
! PROGRAM INVM VS. 1.0 19-OCT-2010 !
!==============================================================================!
! MATRIX INVERSION
!==============================================================================
! LIBRERIA IMSL
!DEC\$ OBJCOMMENT LIB:'libiomp5md.lib'
!==============================================================================
USE LIN_SOL_GEN_INT
IMPLICIT REAL(8) (A-H,O-Z)
REAL(8),ALLOCATABLE :: A(:,:),B(:,:),INV(:,:),X(:,:),RES(:,:)
REAL(8),DIMENSION(2) :: DETR,DETR_INV
WRITE(*,*) 'Matrix dimension:'
ALLOCATE(A(N,N),B(N,0),INV(N,N),X(N,0),RES(N,N),STAT=IK)
IF(IK/=0) THEN
WRITE(*,*) 'Error: no allocation!'
STOP
ENDIF
! Compute the matrix inverse and its determinant.
DO I=1,N
B(I,0)=1.D0
ENDDO
CALL LIN_SOL_GEN(A,B,X,NHRS=0,AINV=INV,DET=DETR)
! Compute the determinant for the inverse matrix.
CALL LIN_SOL_GEN(INV,B,X,NHRS=0,DET=DETR_INV)
! Check residuals, A times inverse = Identity.
RES=MATMUL(A,INV)
DO I=1,N
RES(I,I)=RES(I,I)-1.D0
ENDDO
WRITE(*,*) INV
STOP
END
Thank you very much,
AM
Black Belt
263 Views
You misspelled the keyword argument NRHS.

You will encounter run-time errors since you are not properly allocating and initializing the input arrays to the IMSL routine. It would be useful to compile with checks turned on until you correct these errors.