inv.F90

Go to the documentation of this file.
00001 subroutine invmat(nm,mat)
00002 implicit none 
00003 integer,intent(in)::nm
00004 real(8),intent(inout)::mat(nm,nm)
00005 integer::ipiv(nm)
00006 integer::Lwork 
00007 real(8),allocatable::work(:)
00008 integer::info 
00009 Lwork=10*nm
00010 allocate(work(Lwork))
00011 info=0
00012 call dgetrf(nm,nm,mat,nm,ipiv,info)
00013 call dgetri(nm,mat,nm,ipiv,work,Lwork,info)
00014 if(info/=0) then
00015 write(6,*) 'info (subrouitine inv):',info
00016 stop
00017 endif 
00018 deallocate(work)
00019 return 
00020 end subroutine

Generated on 17 Nov 2020 for respack by  doxygen 1.6.1